Added instructions and tests
Change-Id: I18e491c4a0c188866dcad1f9db52c4f781054e62
diff --git a/views/ngXosViews/UITutorial/.eslintrc b/views/ngXosViews/UITutorial/.eslintrc
index c852748..a5bbd02 100644
--- a/views/ngXosViews/UITutorial/.eslintrc
+++ b/views/ngXosViews/UITutorial/.eslintrc
@@ -21,10 +21,10 @@
"eqeqeq": [2, "smart"],
"no-alert": 1,
"key-spacing": [1, { "beforeColon": false, "afterColon": true }],
- "indent": [2, 2],
+ "indent": [2, 2, { "SwitchCase": 1 }],
"no-irregular-whitespace": 1,
"eol-last": 0,
- "max-nested-callbacks": [2, 4],
+ "max-nested-callbacks": [1, 5],
"comma-spacing": [1, {"before": false, "after": true}],
"no-trailing-spaces": [1, { skipBlankLines: true }],
"no-unused-vars": [1, {"vars": "all", "args": "after-used"}],
diff --git a/views/ngXosViews/UITutorial/spec/errorHandler.test.js b/views/ngXosViews/UITutorial/spec/errorHandler.test.js
new file mode 100644
index 0000000..3f46330
--- /dev/null
+++ b/views/ngXosViews/UITutorial/spec/errorHandler.test.js
@@ -0,0 +1,22 @@
+'use strict';
+
+describe('The ErrorHandler service', () => {
+
+ var ErrorHandler, done;
+
+ beforeEach(module('xos.UITutorial'));
+ beforeEach(module('templates'));
+
+ beforeEach(inject(function (_ErrorHandler_) {
+ // The injector unwraps the underscores (_) from around the parameter names when matching
+ ErrorHandler = _ErrorHandler_;
+ done = jasmine.createSpy('done');
+ }));
+
+ describe('the print method', () => {
+ it('should return an html template', () => {
+ ErrorHandler.print('myError', done);
+ expect(done).toHaveBeenCalledWith(`<span class="error">[ERROR] myError</span>`)
+ });
+ });
+});
\ No newline at end of file
diff --git a/views/ngXosViews/UITutorial/spec/exploreCmd.test.js b/views/ngXosViews/UITutorial/spec/exploreCmd.test.js
new file mode 100644
index 0000000..a5d7cfe
--- /dev/null
+++ b/views/ngXosViews/UITutorial/spec/exploreCmd.test.js
@@ -0,0 +1,197 @@
+'use strict';
+
+describe('The ExploreCmd service', () => {
+
+ var ExploreCmd, ErrorHandler, ResponseHandler, done, shell, ResourceMock, rootScope;
+
+ beforeEach(module('xos.UITutorial'));
+ beforeEach(module('templates'));
+
+ beforeEach(() => {
+ module(function ($provide) {
+ $provide.value('Resource', ResourceMock);
+ })
+ });
+
+ beforeEach(inject(function (_ExploreCmd_, _ErrorHandler_, _ResponseHandler_, $rootScope) {
+ // The injector unwraps the underscores (_) from around the parameter names when matching
+ ExploreCmd = _ExploreCmd_;
+ ErrorHandler = _ErrorHandler_;
+ ResponseHandler = _ResponseHandler_;
+ rootScope = $rootScope;
+ done = jasmine.createSpy('done');
+ shell = {
+ setCommandHandler: jasmine.createSpy('setCommandHandler'),
+ bestMatch: jasmine.createSpy('bestMatch')
+ };
+ // binding the mock shell to the service (for easy testing)
+ ExploreCmd.shell = shell;
+ spyOn(console, 'error');
+
+ ResourceMock = {
+ query: jasmine.createSpy('query').and.callFake(() => {
+ var deferred = $q.defer();
+ deferred.resolve('Remote call result');
+ return {$promise: deferred.promise};
+ })
+ };
+ }));
+
+ it('should set the resouce command handler', () => {
+ ExploreCmd.setup(shell);
+ expect(shell.setCommandHandler).toHaveBeenCalledWith('resource', { exec: ExploreCmd.resourceExec, completion: ExploreCmd.resourceCompletion })
+ });
+
+ describe('the resourceCompletion function', () => {
+
+ beforeEach(() => {
+ spyOn(ExploreCmd, 'getAvailableResources').and.returnValue(['Sites', 'Slices']);
+ });
+
+ it('should suggest a resource list', () => {
+ ExploreCmd.resourceCompletion('resource', '', {text: 'resource'}, done)
+ expect(shell.bestMatch).toHaveBeenCalledWith('', [ 'list', 'Sites', 'Slices' ]);
+
+ ExploreCmd.resourceCompletion('resource', 'S', {text: 'resource S'}, done)
+ expect(shell.bestMatch).toHaveBeenCalledWith('S', [ 'list', 'Sites', 'Slices' ]);
+ });
+
+ it('should suggest a method list', () => {
+ ExploreCmd.resourceCompletion('resource', '', {text: 'resource Sites '}, done)
+ expect(shell.bestMatch).toHaveBeenCalledWith('', [ 'query', 'get', 'save', '$save', 'delete' ]);
+
+ ExploreCmd.resourceCompletion('resource', 'q', {text: 'resource Sites q'}, done)
+ expect(shell.bestMatch).toHaveBeenCalledWith('q', [ 'query', 'get', 'save', '$save', 'delete' ]);
+ });
+ });
+
+ describe('the resourceExec function', () => {
+
+ beforeEach(() => {
+ spyOn(ExploreCmd, 'listAvailableResources');
+ spyOn(ExploreCmd, 'consumeResource');
+ });
+
+ it('should list available resources', () => {
+ ExploreCmd.resourceExec('explore', ['list'], done);
+ expect(ExploreCmd.listAvailableResources).toHaveBeenCalledWith(done);
+ });
+
+ it('should use a resource', () => {
+ ExploreCmd.resourceExec('explore', ['Resource', 'query'], done);
+ expect(ExploreCmd.consumeResource).toHaveBeenCalledWith('Resource', 'query', [], done);
+ });
+ });
+
+ describe('the getAvailableResources function', () => {
+
+ beforeEach(() => {
+ spyOn(angular, 'module').and.returnValue({
+ _invokeQueue: [
+ ['$provide', 'service', ['Sites', ['$resource']]],
+ ['$provide', 'service', ['Slices', ['$q', '$resource']]],
+ ['$provide', 'factory', ['_', []]],
+ ['$provide', 'service', ['helper', ['Slices']]]
+ ]
+ });
+ });
+
+ it('should return a list of resources in the angular app', () => {
+ const resources = ExploreCmd.getAvailableResources();
+ expect(resources).toEqual(['Sites', 'Slices']);
+ });
+ });
+
+ describe('the listAvailableResources function', () => {
+ beforeEach(() => {
+ spyOn(ExploreCmd, 'getAvailableResources').and.returnValue(['Sites', 'Slices']);
+ });
+
+ it('should format resource in an html template', () => {
+ ExploreCmd.listAvailableResources(done);
+ expect(ExploreCmd.getAvailableResources).toHaveBeenCalled();
+ expect(done).toHaveBeenCalledWith(`Sites<br/>Slices<br/>`);
+ });
+ });
+
+ describe('the consumeResource function', () => {
+ beforeEach(() => {
+ spyOn(ExploreCmd, 'getAvailableResources').and.returnValue(['Resource', 'Fake']);
+ spyOn(ErrorHandler, 'print');
+ });
+
+ it('should notify that a resource does not exists', () => {
+ ExploreCmd.consumeResource('Test', null, null, done);
+ expect(ErrorHandler.print).toHaveBeenCalledWith(`Resource "Test" does not exists`, done)
+ });
+
+ it('should notify that a method does not exists', () => {
+ ExploreCmd.consumeResource('Resource', 'test', null, done);
+ expect(ErrorHandler.print).toHaveBeenCalledWith(`Method "test" not allowed`, done)
+ });
+
+ const methodsWithParams = ['get', '$save', 'delete'];
+ methodsWithParams.forEach(method => {
+ it(`should notify that the ${method} method require parameters`, () => {
+ ExploreCmd.consumeResource('Resource', method, [], done);
+ expect(ErrorHandler.print).toHaveBeenCalledWith(`Method "${method}" require parameters`, done)
+ });
+ });
+
+ it('should not accept id as parameter for the query method', () => {
+ ExploreCmd.consumeResource('Resource', 'query', ['{id:1}'], done);
+ expect(ErrorHandler.print).toHaveBeenCalledWith(`Is not possible to use "id" as filter in method "query", use "get" instead!`, done)
+ });
+
+ it('should notify the user in case of malformed parameters', () => {
+ ExploreCmd.consumeResource('Resource', 'query', ['{child: 3}'], done);
+ expect(ErrorHandler.print).toHaveBeenCalledWith(`Parameter is not valid, it shoudl be in the form of: <code>{id:1}</code>, with no spaces`, done)
+ pending();
+ });
+
+ describe('when called with the correct parameters', () => {
+
+ let deferred;
+ beforeEach(inject(($q) => {
+ spyOn(ResponseHandler, 'parse');
+
+ deferred = $q.defer();
+ ResourceMock = {
+ query: jasmine.createSpy('query').and.callFake(function(){
+ return {$promise: deferred.promise};
+ })
+ };
+ }));
+
+ it('should notify the user if an error occurred while loading the resource', () => {
+ ExploreCmd.consumeResource('Fake', 'query', [], done);
+ expect(console.error).toHaveBeenCalled();
+ expect(ErrorHandler.print).toHaveBeenCalledWith('Failed to inject resource "Fake"', done);
+ });
+
+ it('should call a resource and return the results', () => {
+ ExploreCmd.consumeResource('Resource', 'query', [], done);
+ deferred.resolve([]);
+ rootScope.$apply();
+ expect(ErrorHandler.print).not.toHaveBeenCalled()
+ expect(ResponseHandler.parse).toHaveBeenCalledWith([], 'Resource.query()', done);
+ });
+
+ it('should call a resource with parameters and return the results', () => {
+ ExploreCmd.consumeResource('Resource', 'query', ['{child:3}'], done);
+ deferred.resolve([]);
+ rootScope.$apply();
+ expect(ErrorHandler.print).not.toHaveBeenCalled()
+ expect(ResponseHandler.parse).toHaveBeenCalledWith([], 'Resource.query({"child":3})', done);
+ });
+
+ it('should call a resource and display a not found message', () => {
+ ExploreCmd.consumeResource('Resource', 'query', [], done);
+ deferred.reject({status: 404, data: {detail: 'Not Found.'}});
+ rootScope.$apply();
+ expect(ErrorHandler.print).toHaveBeenCalledWith('Resource with method "query" and parameters {} Not Found.', done)
+ expect(ResponseHandler.parse).not.toHaveBeenCalled();
+ });
+ });
+ });
+});
\ No newline at end of file
diff --git a/views/ngXosViews/UITutorial/spec/responseHandler.test.js b/views/ngXosViews/UITutorial/spec/responseHandler.test.js
new file mode 100644
index 0000000..4ce26be
--- /dev/null
+++ b/views/ngXosViews/UITutorial/spec/responseHandler.test.js
@@ -0,0 +1,46 @@
+'use strict';
+
+describe('The ResponseHandler service', () => {
+
+ var ResponseHandler, done;
+
+ beforeEach(module('xos.UITutorial'));
+ beforeEach(module('templates'));
+
+ beforeEach(inject(function (_ResponseHandler_) {
+ // The injector unwraps the underscores (_) from around the parameter names when matching
+ ResponseHandler = _ResponseHandler_;
+ done = jasmine.createSpy('done');
+ }));
+
+ describe('the parse method', () => {
+ it('should return an html template for a collection', () => {
+ const collection = [
+ {id: 1, deleted: true, name: 'one'},
+ {id: 2, deleted: true, name: 'two'}
+ ];
+
+ const collectionHtml = `
+ <div>
+ <p>Corresponding js code: <code>jsCode</code></p>
+ <div class="json"><div class="jsonCollection">[<div class="jsonObject">{"id":1,"name":"one"},</code></div><div class="jsonObject">{"id":2,"name":"two"}</code></div>]</div></div>
+ </div>
+ `;
+ ResponseHandler.parse(collection, 'jsCode', done);
+ expect(done).toHaveBeenCalledWith(collectionHtml)
+ });
+
+ it('should return an html template for an object', () => {
+ const object = {id: 1, deleted: true, name: 'one'};
+
+ const objectHtml = `
+ <div>
+ <p>Corresponding js code: <code></code></p>
+ <div class="json"><div class="jsonObject">{"id":1,"name":"one"}</code></div></div>
+ </div>
+ `;
+ ResponseHandler.parse(object, '', done);
+ expect(done).toHaveBeenCalledWith(objectHtml)
+ });
+ });
+});
\ No newline at end of file
diff --git a/views/ngXosViews/UITutorial/spec/sample.test.js b/views/ngXosViews/UITutorial/spec/sample.test.js
deleted file mode 100644
index 9e16127..0000000
--- a/views/ngXosViews/UITutorial/spec/sample.test.js
+++ /dev/null
@@ -1,37 +0,0 @@
-'use strict';
-
-describe('The User List', () => {
-
- var scope, element, isolatedScope, httpBackend;
-
- beforeEach(module('xos.UITutorial'));
- beforeEach(module('templates'));
-
- beforeEach(inject(function($httpBackend, $compile, $rootScope){
-
- httpBackend = $httpBackend;
- // Setting up mock request
- $httpBackend.expectGET('/api/core/users/?no_hyperlinks=1').respond([
- {
- email: 'matteo.scandolo@gmail.com',
- firstname: 'Matteo',
- lastname: 'Scandolo'
- }
- ]);
-
- scope = $rootScope.$new();
- element = angular.element('<users-list></users-list>');
- $compile(element)(scope);
- scope.$digest();
- isolatedScope = element.isolateScope().vm;
- }));
-
- xit('should load 1 users', () => {
- httpBackend.flush();
- expect(isolatedScope.users.length).toBe(1);
- expect(isolatedScope.users[0].email).toEqual('matteo.scandolo@gmail.com');
- expect(isolatedScope.users[0].firstname).toEqual('Matteo');
- expect(isolatedScope.users[0].lastname).toEqual('Scandolo');
- });
-
-});
\ No newline at end of file
diff --git a/views/ngXosViews/UITutorial/spec/shell.test.js b/views/ngXosViews/UITutorial/spec/shell.test.js
new file mode 100644
index 0000000..19ea63e
--- /dev/null
+++ b/views/ngXosViews/UITutorial/spec/shell.test.js
@@ -0,0 +1,29 @@
+'use strict';
+
+describe('The Js Shell directive', () => {
+
+ var scope, element, isolatedScope, shellSpy;
+
+ beforeEach(module('xos.UITutorial'));
+ beforeEach(module('templates'));
+
+ beforeEach(inject(function($compile, $rootScope){
+ scope = $rootScope.$new();
+ element = angular.element('<js-shell></js-shell>');
+ $compile(element)(scope);
+ scope.$digest();
+ isolatedScope = element.isolateScope().vm;
+ spyOn(isolatedScope.shell, 'setCommandHandler');
+ spyOn(isolatedScope.shell, 'activate');
+ }));
+
+ // NOTE see http://stackoverflow.com/questions/38906605/angular-jasmine-testing-immediatly-invoked-functions-inside-a-directive-contr
+
+ xit('should register the explore command', () => {
+ expect(isolatedScope.shell.setCommandHandler).toHaveBeenCalled();
+ });
+
+ xit('should activate the shell', () => {
+ expect(isolatedScope.shell.activate).toHaveBeenCalled();
+ });
+});
\ No newline at end of file
diff --git a/views/ngXosViews/UITutorial/spec/templateHandler.test.js b/views/ngXosViews/UITutorial/spec/templateHandler.test.js
new file mode 100644
index 0000000..0af68b9
--- /dev/null
+++ b/views/ngXosViews/UITutorial/spec/templateHandler.test.js
@@ -0,0 +1,22 @@
+'use strict';
+
+describe('The TemplateHandler service', () => {
+
+ var TemplateHandler;
+
+ beforeEach(module('xos.UITutorial'));
+ beforeEach(module('templates'));
+
+ beforeEach(inject(function (_TemplateHandler_) {
+ TemplateHandler = _TemplateHandler_;
+ }));
+
+ const templates = ['error', 'instructions', 'resourcesResponse'];
+
+ templates.forEach(t => {
+ it(`should have a ${t} template`, () => {
+ expect(TemplateHandler[t]).toBeDefined();
+ expect(angular.isFunction(TemplateHandler[t])).toBeTruthy();
+ });
+ });
+});
\ No newline at end of file
diff --git a/views/ngXosViews/UITutorial/src/css/main.css b/views/ngXosViews/UITutorial/src/css/main.css
index 3684934..d008cb5 100644
--- a/views/ngXosViews/UITutorial/src/css/main.css
+++ b/views/ngXosViews/UITutorial/src/css/main.css
@@ -7,14 +7,19 @@
height: 400px;
background: #002b36;
padding: 10px;
- overflow: scroll; }
+ overflow: scroll;
+ color: #93a1a1; }
#xosUITutorial js-shell #shell-panel .prompt {
color: #d33682; }
+ #xosUITutorial js-shell #shell-panel .input {
+ color: #268bd2; }
#xosUITutorial js-shell #shell-panel .cursor {
color: #2aa198; }
#xosUITutorial js-shell #shell-panel .error {
color: #dc322f; }
- #xosUITutorial js-shell #shell-panel #shell-view {
- color: #93a1a1; }
- #xosUITutorial js-shell #shell-panel #shell-view > div > div {
- color: #268bd2; }
+ #xosUITutorial js-shell #shell-panel #shell-view > div > div {
+ color: #268bd2; }
+ #xosUITutorial js-shell #shell-panel #shell-view .jsonObject {
+ white-space: nowrap; }
+ #xosUITutorial js-shell #shell-panel #shell-view .jsonCollection > .jsonObject {
+ margin-left: 10px; }
diff --git a/views/ngXosViews/UITutorial/src/index.html b/views/ngXosViews/UITutorial/src/index.html
index 6819b46..d325f9c 100644
--- a/views/ngXosViews/UITutorial/src/index.html
+++ b/views/ngXosViews/UITutorial/src/index.html
@@ -39,6 +39,7 @@
<!-- inject:js -->
<script src="/vendor/ng-xos-lib/dist/ngXosHelpers.min.js"></script>
<script src="/.tmp/main.js"></script>
+<script src="/.tmp/templateHandler.js"></script>
<script src="/.tmp/responseHandler.js"></script>
<script src="/.tmp/exploreCmd.js"></script>
<script src="/.tmp/errorHandler.js"></script>
diff --git a/views/ngXosViews/UITutorial/src/js/errorHandler.js b/views/ngXosViews/UITutorial/src/js/errorHandler.js
index dbe41f4..aa75d38 100644
--- a/views/ngXosViews/UITutorial/src/js/errorHandler.js
+++ b/views/ngXosViews/UITutorial/src/js/errorHandler.js
@@ -1,10 +1,9 @@
(function () {
'use strict';
angular.module('xos.UITutorial')
- .service('ErrorHandler', function(){
+ .service('ErrorHandler', function(TemplateHandler){
this.print = (msg, done) => {
- const errorTpl = _.template(`<span class="error">[ERROR] <%= msg %></span>`);
- done(errorTpl({msg: msg}));
+ done(TemplateHandler.error({msg: msg}));
};
});
})();
\ No newline at end of file
diff --git a/views/ngXosViews/UITutorial/src/js/exploreCmd.js b/views/ngXosViews/UITutorial/src/js/exploreCmd.js
index d4bba90..0aba8fa 100644
--- a/views/ngXosViews/UITutorial/src/js/exploreCmd.js
+++ b/views/ngXosViews/UITutorial/src/js/exploreCmd.js
@@ -3,36 +3,41 @@
angular.module('xos.UITutorial')
.service('ExploreCmd', function($injector, ResponseHandler, ErrorHandler){
- this.setup = (shell) => {
- shell.setCommandHandler('resource', {
- exec: (cmd, args, done) => {
- switch(args[0]){
- case 'list':
- return listAvailableResources(done);
- break;
- default:
- // use the resource
- const resourceName = args.shift();
- const method = args.shift();
- return consumeResource(resourceName, method, args, done);
- }
- },
- completion: function(cmd, arg, line, callback) {
- const args = ['list'].concat(getAvailableResources());
- if(line.text.match(/resource\s[A-Z][a-z]+\s/)){
- // if arg is a resource, then return available methods
- if(args.indexOf(arg) !== -1){
- arg = '';
- }
- const methods = ['query', 'get', 'save', '$save', 'delete'];
- return callback(shell.bestMatch(arg, methods));
- }
- return callback(shell.bestMatch(arg, args));
+ this.resourceExec = (cmd, args, done) => {
+ switch(args[0]){
+ case 'list':
+ return this.listAvailableResources(done);
+ break;
+ default:
+ // use the resource
+ const resourceName = args.shift();
+ const method = args.shift();
+ return this.consumeResource(resourceName, method, args, done);
+ }
+ };
+
+ this.resourceCompletion = (cmd, arg, line, done) => {
+ const args = ['list'].concat(this.getAvailableResources());
+ if(line.text.match(/resource\s[A-Z][a-z]+\s/)){
+ // if arg is a resource, then return available methods
+ if(args.indexOf(arg) !== -1){
+ arg = '';
}
+ const methods = ['query', 'get', 'save', '$save', 'delete'];
+ return done(this.shell.bestMatch(arg, methods));
+ }
+ return done(this.shell.bestMatch(arg, args));
+ };
+
+ this.setup = (shell) => {
+ this.shell = shell;
+ shell.setCommandHandler('resource', {
+ exec: this.resourceExec,
+ completion: this.resourceCompletion
});
};
- const getAvailableResources = () => {
+ this.getAvailableResources = () => {
return angular.module('xos.helpers')._invokeQueue
.filter((d) => {
if(d[1] !== 'service'){
@@ -44,17 +49,18 @@
.reduce((list, i) => list.concat([i[2][0]]), []);
}
- const listAvailableResources = (done) => {
- const resources = getAvailableResources()
+ this.listAvailableResources = (done) => {
+ // TODO use a template
+ const resources = this.getAvailableResources()
.reduce((html, i) => `${html}${i}<br/>`, '');
done(resources);
}
- const consumeResource = (resourceName, method, args, done) => {
+ this.consumeResource = (resourceName, method, args, done) => {
// TODO if not resourceName/method print cmd instructions
- if(getAvailableResources().indexOf(resourceName) === -1){
+ if(this.getAvailableResources().indexOf(resourceName) === -1){
return ErrorHandler.print(`Resource "${resourceName}" does not exists`, done);
}
@@ -62,36 +68,43 @@
return ErrorHandler.print(`Method "${method}" not allowed`, done);
}
+ // TODO @Teo if get/delete check for arguments
+ let params = {};
+
+ // if the method require arguments checks for them
+ if(['get', '$save', 'delete'].indexOf(method) !== -1){
+ if(args.length === 0){
+ return ErrorHandler.print(`Method "${method}" require parameters`, done);
+ }
+ }
+
+ // if there are arguments parse them
+ // TODO wrap in a try catch, we have no guarantee that a user insert the correct params
+ if(args.length > 0){
+ params = eval(`(${args[0]})`);
+ }
+
+ // if it is a query is not possible to use id as parameter
+ if(method === 'query' && angular.isDefined(params.id)){
+ return ErrorHandler.print(`Is not possible to use "id" as filter in method "${method}", use "get" instead!`, done);
+ }
+
let Resource;
try{
Resource = $injector.get(resourceName);
-
- // TODO @Teo if get/delete check for arguments
- let params = {};
-
- // if the method require arguments checks for them
- if(['get', '$save', 'delete'].indexOf(method) !== -1){
- if(args.length === 0){
- return ErrorHandler.print(`Method "${method}" require parameters`, done);
- }
- }
-
- // if there are arguments parse them
- if(args.length > 0){
- params = eval(`(${args[0]})`);
- }
-
- // if it is a query is not possible to use id as parameter
- if(method === 'query' && angular.isDefined(params.id)){
- return ErrorHandler.print(`Is not possible to use "id" as filter in method "${method}", use "get" instead!`, done);
- }
-
Resource[method](params).$promise
.then(res => {
- return ResponseHandler.parse(res, done);
+ const jsCode = `${resourceName}.${method}(${Object.keys(params).length > 0 ? JSON.stringify(params): ''})`;
+ return ResponseHandler.parse(res, jsCode, done);
+ })
+ .catch(e => {
+ if(e.status === 404){
+ return ErrorHandler.print(`${resourceName} with method "${method}" and parameters ${JSON.stringify(params)} ${e.data.detail}`, done);
+ }
});
}
catch(e){
+ console.error(e);
return ErrorHandler.print(`Failed to inject resource "${resourceName}"`, done);
}
};
diff --git a/views/ngXosViews/UITutorial/src/js/main.js b/views/ngXosViews/UITutorial/src/js/main.js
index bc5c27e..c89f1da 100644
--- a/views/ngXosViews/UITutorial/src/js/main.js
+++ b/views/ngXosViews/UITutorial/src/js/main.js
@@ -16,7 +16,7 @@
.config(function($httpProvider){
$httpProvider.interceptors.push('NoHyperlinks');
})
-.directive('jsShell', function(){
+.directive('jsShell', function(TemplateHandler){
return {
restrict: 'E',
scope: {},
@@ -24,23 +24,28 @@
controllerAs: 'vm',
templateUrl: 'templates/js-shell.tpl.html',
controller: function(ExploreCmd){
- var history = new Josh.History({ key: 'helloworld.history'});
- var shell = Josh.Shell({history: history});
+ var history = new Josh.History({ key: 'jsshell.history'});
+ this.shell = Josh.Shell({history: history});
- shell.onNewPrompt(function(done) {
+ this.shell.onNewPrompt(done => {
done('[ngXosLib] $ ');
});
- shell.setCommandHandler('explore', {
+ this.shell.setCommandHandler('explore', {
exec: (cmd, args, done) => {
- ExploreCmd.setup(shell);
- done();
+ ExploreCmd.setup(this.shell);
+ done(TemplateHandler.instructions({
+ title: `You can now explore the API use angular $resouces!`,
+ messages: [
+ `Use <code>resource list</code> to list all the available resources and <code>resource {resoureName} {method} {?paramters}</code> to call the API.`,
+ `An example command is <code>resource Slices query</code>`,
+ `You can also provide paramters with <code>resource Slices query {max_instances: 10}</code>`
+ ]
+ }));
}
});
-
-
- shell.activate();
+ this.shell.activate();
}
};
});
\ No newline at end of file
diff --git a/views/ngXosViews/UITutorial/src/js/responseHandler.js b/views/ngXosViews/UITutorial/src/js/responseHandler.js
index 801129e..e343dda 100644
--- a/views/ngXosViews/UITutorial/src/js/responseHandler.js
+++ b/views/ngXosViews/UITutorial/src/js/responseHandler.js
@@ -1,27 +1,47 @@
(function () {
'use strict';
angular.module('xos.UITutorial')
- .service('ResponseHandler', function(){
- this.parse = (res, done) => {
- var compiled = _.template('<div><pre><%- JSON.stringify(val,null,1) %></div></pre>');
- var compiledArray = _.template('<% _.forEach(valueArr, function(item) { %><div><pre><%- JSON.stringify(item) %></pre></div><%}); %>');
- var resFunc = function (res) {
- let retVar;
- let exclude = ['deleted','enabled','enacted','exposed_ports','lazy_blocked','created','validators','controllers','backend_status','backend_register','policed','no_policy','write_protect','no_sync','updated'];
- if(_.isArray(res)) {
- retVar = [];
- retVar = _.map(res, (o)=> {
- return _.omit(o, exclude);
- });
- retVar = compiledArray({'valueArr':retVar});
- }
- else{
- retVar = _.omit(res,exclude);
- retVar = compiled({'val':retVar} );
- }
- return retVar;
+ .service('ResponseHandler', function(TemplateHandler){
+
+ const exclude = [
+ 'deleted',
+ 'enabled',
+ 'enacted',
+ 'exposed_ports',
+ 'lazy_blocked',
+ 'created',
+ 'validators',
+ 'controllers',
+ 'backend_status',
+ 'backend_register',
+ 'policed',
+ 'no_policy',
+ 'write_protect',
+ 'no_sync',
+ 'updated'
+ ];
+
+ this.parseObject = (obj, comma = '') => {
+ obj = _.omit(obj, exclude);
+ return TemplateHandler.jsonObject({'obj': obj, comma: comma});
+ };
+
+ this.parseCollection = (array) => {
+ array = array.map((o, i) => `${this.parseObject(o, i === (array.length - 1) ? '':',')}`);
+ return TemplateHandler.jsonCollection({'collection': array});
+ };
+
+ this.parse = (res, jsCode, done) => {
+ if(_.isArray(res)) {
+ res = this.parseCollection(res);
}
- done( resFunc(res));
+ else{
+ res = this.parseObject(res);
+ }
+ done(TemplateHandler.resourcesResponse({
+ jsCode: jsCode,
+ res: res
+ }));
};
});
})();
\ No newline at end of file
diff --git a/views/ngXosViews/UITutorial/src/js/templateHandler.js b/views/ngXosViews/UITutorial/src/js/templateHandler.js
new file mode 100644
index 0000000..752b214
--- /dev/null
+++ b/views/ngXosViews/UITutorial/src/js/templateHandler.js
@@ -0,0 +1,26 @@
+(function () {
+ 'use strict';
+ angular.module('xos.UITutorial')
+ .service('TemplateHandler', function(_){
+
+ this.error = _.template(`<span class="error">[ERROR] <%= msg %></span>`);
+
+ this.instructions = _.template(`
+ <div>
+ <strong><%= title %></strong>
+ <% _.forEach(messages, function(m) { %><p><%= m %></p><% }); %>
+ </div>
+ `);
+
+ this.resourcesResponse = _.template(`
+ <div>
+ <p>Corresponding js code: <code><%= jsCode %></code></p>
+ <div class="json"><%= res %></div>
+ </div>
+ `);
+
+ this.jsonObject = _.template(`<div class="jsonObject"><%= JSON.stringify(obj) %><%=comma%></code></div>`);
+
+ this.jsonCollection = _.template(`<div class="jsonCollection">[<% _.forEach(collection, function(item) { %><%= item %><%}); %>]</div>`);
+ });
+})();
\ No newline at end of file
diff --git a/views/ngXosViews/UITutorial/src/sass/main.scss b/views/ngXosViews/UITutorial/src/sass/main.scss
index 83ea377..f3b0496 100644
--- a/views/ngXosViews/UITutorial/src/sass/main.scss
+++ b/views/ngXosViews/UITutorial/src/sass/main.scss
@@ -28,11 +28,16 @@
background: $background;
padding: 10px;
overflow: scroll;
+ color: $emph;
.prompt {
color: $magenta;
}
+ .input {
+ color: $blue;
+ }
+
.cursor {
color: $cyan;
}
@@ -42,11 +47,20 @@
}
#shell-view {
- color: $emph;
>div>div{
color: $blue;
}
+
+ .jsonObject {
+ white-space: nowrap;
+ }
+
+ .jsonCollection {
+ >.jsonObject{
+ margin-left: 10px;
+ }
+ }
}
}
}
diff --git a/views/ngXosViews/UITutorial/src/templates/js-shell.tpl.html b/views/ngXosViews/UITutorial/src/templates/js-shell.tpl.html
index 543006d..8799fd4 100644
--- a/views/ngXosViews/UITutorial/src/templates/js-shell.tpl.html
+++ b/views/ngXosViews/UITutorial/src/templates/js-shell.tpl.html
@@ -1,3 +1,6 @@
<div id="shell-panel">
+ <div>
+ Type <code>help</code> or hit <code>TAB</code> for a list of commands.
+ </div>
<div id="shell-view"></div>
</div>
\ No newline at end of file
diff --git a/xos/core/xoslib/dashboards/xosUITutorial.html b/xos/core/xoslib/dashboards/xosUITutorial.html
new file mode 100644
index 0000000..203c3a1
--- /dev/null
+++ b/xos/core/xoslib/dashboards/xosUITutorial.html
@@ -0,0 +1,17 @@
+<!-- browserSync -->
+
+<!-- endcss -->
+<!-- inject:css -->
+<link rel="stylesheet" href="/static/css/xosUITutorial.css">
+<!-- endinject -->
+
+<div ng-app="xos.UITutorial" id="xosUITutorial" class="container-fluid">
+ <div ui-view></div>
+</div>
+
+
+<!-- endjs -->
+<!-- inject:js -->
+<script src="/static/vendor/xosUITutorialVendor.js"></script>
+<script src="/static/js/xosUITutorial.js"></script>
+<!-- endinject -->
\ No newline at end of file
diff --git a/xos/core/xoslib/static/css/xosUITutorial.css b/xos/core/xoslib/static/css/xosUITutorial.css
new file mode 100644
index 0000000..9bd2a34
--- /dev/null
+++ b/xos/core/xoslib/static/css/xosUITutorial.css
@@ -0,0 +1 @@
+#xosUITutorial{width:100%}#xosUITutorial js-shell{display:block}#xosUITutorial js-shell #shell-panel{width:100%;height:400px;background:#002b36;padding:10px;overflow:scroll;color:#93a1a1}#xosUITutorial js-shell #shell-panel .prompt{color:#d33682}#xosUITutorial js-shell #shell-panel .input{color:#268bd2}#xosUITutorial js-shell #shell-panel .cursor{color:#2aa198}#xosUITutorial js-shell #shell-panel .error{color:#dc322f}#xosUITutorial js-shell #shell-panel #shell-view>div>div{color:#268bd2}#xosUITutorial js-shell #shell-panel #shell-view .jsonObject{white-space:nowrap}#xosUITutorial js-shell #shell-panel #shell-view .jsonCollection>.jsonObject{margin-left:10px}
\ No newline at end of file
diff --git a/xos/core/xoslib/static/js/xosUITutorial.js b/xos/core/xoslib/static/js/xosUITutorial.js
new file mode 100644
index 0000000..79a5492
--- /dev/null
+++ b/xos/core/xoslib/static/js/xosUITutorial.js
@@ -0,0 +1 @@
+"use strict";angular.module("xos.UITutorial",["ngResource","ngCookies","ui.router","xos.helpers"]).config(["$stateProvider",function(e){e.state("shell",{url:"/",template:"<js-shell></js-shell>"})}]).config(["$httpProvider",function(e){e.interceptors.push("NoHyperlinks")}]).directive("jsShell",["TemplateHandler",function(e){return{restrict:"E",scope:{},bindToController:!0,controllerAs:"vm",templateUrl:"templates/js-shell.tpl.html",controller:["ExploreCmd",function(r){var t=this,o=new Josh.History({key:"jsshell.history"});this.shell=Josh.Shell({history:o}),this.shell.onNewPrompt(function(e){e("[ngXosLib] $ ")}),this.shell.setCommandHandler("explore",{exec:function(o,s,n){r.setup(t.shell),n(e.instructions({title:"You can now explore the API use angular $resouces!",messages:["Use <code>resource list</code> to list all the available resources and <code>resource {resoureName} {method} {?paramters}</code> to call the API.","An example command is <code>resource Slices query</code>","You can also provide paramters with <code>resource Slices query {max_instances: 10}</code>"]}))}}),this.shell.activate()}]}}]),angular.module("xos.UITutorial").run(["$templateCache",function(e){e.put("templates/js-shell.tpl.html",'<div id="shell-panel">\n <div>\n Type <code>help</code> or hit <code>TAB</code> for a list of commands.\n </div>\n <div id="shell-view"></div>\n</div>')}]),function(){angular.module("xos.UITutorial").service("TemplateHandler",["_",function(e){this.error=e.template('<span class="error">[ERROR] <%= msg %></span>'),this.instructions=e.template("\n <div>\n <strong><%= title %></strong>\n <% _.forEach(messages, function(m) { %><p><%= m %></p><% }); %>\n </div>\n "),this.resourcesResponse=e.template('\n <div>\n <p>Corresponding js code: <code><%= jsCode %></code></p>\n <div class="json"><%= res %></div>\n </div>\n '),this.jsonObject=e.template('<div class="jsonObject"><%= JSON.stringify(obj) %><%=comma%></code></div>'),this.jsonCollection=e.template('<div class="jsonCollection">[<% _.forEach(collection, function(item) { %><%= item %><%}); %>]</div>')}])}(),function(){angular.module("xos.UITutorial").service("ResponseHandler",["TemplateHandler",function(e){var r=this,t=["deleted","enabled","enacted","exposed_ports","lazy_blocked","created","validators","controllers","backend_status","backend_register","policed","no_policy","write_protect","no_sync","updated"];this.parseObject=function(r){var o=arguments.length<=1||void 0===arguments[1]?"":arguments[1];return r=_.omit(r,t),e.jsonObject({obj:r,comma:o})},this.parseCollection=function(t){return t=t.map(function(e,o){return""+r.parseObject(e,o===t.length-1?"":",")}),e.jsonCollection({collection:t})},this.parse=function(t,o,s){t=_.isArray(t)?r.parseCollection(t):r.parseObject(t),s(e.resourcesResponse({jsCode:o,res:t}))}}])}(),function(){angular.module("xos.UITutorial").service("ExploreCmd",["$injector","ResponseHandler","ErrorHandler",function($injector,ResponseHandler,ErrorHandler){var _this=this;this.resourceExec=function(e,r,t){switch(r[0]){case"list":return _this.listAvailableResources(t);default:var o=r.shift(),s=r.shift();return _this.consumeResource(o,s,r,t)}},this.resourceCompletion=function(e,r,t,o){var s=["list"].concat(_this.getAvailableResources());if(t.text.match(/resource\s[A-Z][a-z]+\s/)){s.indexOf(r)!==-1&&(r="");var n=["query","get","save","$save","delete"];return o(_this.shell.bestMatch(r,n))}return o(_this.shell.bestMatch(r,s))},this.setup=function(e){_this.shell=e,e.setCommandHandler("resource",{exec:_this.resourceExec,completion:_this.resourceCompletion})},this.getAvailableResources=function(){return angular.module("xos.helpers")._invokeQueue.filter(function(e){if("service"!==e[1])return!1;var r=e[2][1];return r.indexOf("$resource")!==-1}).reduce(function(e,r){return e.concat([r[2][0]])},[])},this.listAvailableResources=function(e){var r=_this.getAvailableResources().reduce(function(e,r){return""+e+r+"<br/>"},"");e(r)},this.consumeResource=function(resourceName,method,args,done){if(_this.getAvailableResources().indexOf(resourceName)===-1)return ErrorHandler.print('Resource "'+resourceName+'" does not exists',done);if(["query","get","save","$save","delete"].indexOf(method)===-1)return ErrorHandler.print('Method "'+method+'" not allowed',done);var params={};if(["get","$save","delete"].indexOf(method)!==-1&&0===args.length)return ErrorHandler.print('Method "'+method+'" require parameters',done);if(args.length>0&&(params=eval("("+args[0]+")")),"query"===method&&angular.isDefined(params.id))return ErrorHandler.print('Is not possible to use "id" as filter in method "'+method+'", use "get" instead!',done);var Resource=void 0;try{Resource=$injector.get(resourceName),Resource[method](params).$promise.then(function(e){var r=resourceName+"."+method+"("+(Object.keys(params).length>0?JSON.stringify(params):"")+")";return ResponseHandler.parse(e,r,done)})["catch"](function(e){if(404===e.status)return ErrorHandler.print(resourceName+' with method "'+method+'" and parameters '+JSON.stringify(params)+" "+e.data.detail,done)})}catch(e){return console.error(e),ErrorHandler.print('Failed to inject resource "'+resourceName+'"',done)}}}])}(),function(){angular.module("xos.UITutorial").service("ErrorHandler",["TemplateHandler",function(e){this.print=function(r,t){t(e.error({msg:r}))}}])}(),angular.module("xos.UITutorial").run(["$location",function(e){e.path("/")}]);
\ No newline at end of file
diff --git a/xos/core/xoslib/static/vendor/xosUITutorialVendor.js b/xos/core/xoslib/static/vendor/xosUITutorialVendor.js
new file mode 100644
index 0000000..2c7a2be
--- /dev/null
+++ b/xos/core/xoslib/static/vendor/xosUITutorialVendor.js
@@ -0,0 +1,6 @@
+!function(t,e){"object"==typeof module&&"object"==typeof module.exports?module.exports=t.document?e(t,!0):function(t){if(!t.document)throw new Error("jQuery requires a window with a document");return e(t)}:e(t)}("undefined"!=typeof window?window:this,function(t,e){function n(t){var e="length"in t&&t.length,n=Q.type(t);return"function"!==n&&!Q.isWindow(t)&&(!(1!==t.nodeType||!e)||("array"===n||0===e||"number"==typeof e&&e>0&&e-1 in t))}function r(t,e,n){if(Q.isFunction(e))return Q.grep(t,function(t,r){return!!e.call(t,r,t)!==n});if(e.nodeType)return Q.grep(t,function(t){return t===e!==n});if("string"==typeof e){if(at.test(e))return Q.filter(e,t,n);e=Q.filter(e,t)}return Q.grep(t,function(t){return U.call(e,t)>=0!==n})}function i(t,e){for(;(t=t[e])&&1!==t.nodeType;);return t}function o(t){var e=dt[t]={};return Q.each(t.match(ht)||[],function(t,n){e[n]=!0}),e}function u(){G.removeEventListener("DOMContentLoaded",u,!1),t.removeEventListener("load",u,!1),Q.ready()}function a(){Object.defineProperty(this.cache={},0,{get:function(){return{}}}),this.expando=Q.expando+a.uid++}function c(t,e,n){var r;if(void 0===n&&1===t.nodeType)if(r="data-"+e.replace(xt,"-$1").toLowerCase(),n=t.getAttribute(r),"string"==typeof n){try{n="true"===n||"false"!==n&&("null"===n?null:+n+""===n?+n:bt.test(n)?Q.parseJSON(n):n)}catch(i){}yt.set(t,e,n)}else n=void 0;return n}function s(){return!0}function l(){return!1}function f(){try{return G.activeElement}catch(t){}}function p(t,e){return Q.nodeName(t,"table")&&Q.nodeName(11!==e.nodeType?e:e.firstChild,"tr")?t.getElementsByTagName("tbody")[0]||t.appendChild(t.ownerDocument.createElement("tbody")):t}function h(t){return t.type=(null!==t.getAttribute("type"))+"/"+t.type,t}function d(t){var e=Ht.exec(t.type);return e?t.type=e[1]:t.removeAttribute("type"),t}function g(t,e){for(var n=0,r=t.length;n<r;n++)mt.set(t[n],"globalEval",!e||mt.get(e[n],"globalEval"))}function v(t,e){var n,r,i,o,u,a,c,s;if(1===e.nodeType){if(mt.hasData(t)&&(o=mt.access(t),u=mt.set(e,o),s=o.events)){delete u.handle,u.events={};for(i in s)for(n=0,r=s[i].length;n<r;n++)Q.event.add(e,i,s[i][n])}yt.hasData(t)&&(a=yt.access(t),c=Q.extend({},a),yt.set(e,c))}}function m(t,e){var n=t.getElementsByTagName?t.getElementsByTagName(e||"*"):t.querySelectorAll?t.querySelectorAll(e||"*"):[];return void 0===e||e&&Q.nodeName(t,e)?Q.merge([t],n):n}function y(t,e){var n=e.nodeName.toLowerCase();"input"===n&&kt.test(t.type)?e.checked=t.checked:"input"!==n&&"textarea"!==n||(e.defaultValue=t.defaultValue)}function b(e,n){var r,i=Q(n.createElement(e)).appendTo(n.body),o=t.getDefaultComputedStyle&&(r=t.getDefaultComputedStyle(i[0]))?r.display:Q.css(i[0],"display");return i.detach(),o}function x(t){var e=G,n=Ft[t];return n||(n=b(t,e),"none"!==n&&n||(Wt=(Wt||Q("<iframe frameborder='0' width='0' height='0'/>")).appendTo(e.documentElement),e=Wt[0].contentDocument,e.write(),e.close(),n=b(t,e),Wt.detach()),Ft[t]=n),n}function _(t,e,n){var r,i,o,u,a=t.style;return n=n||Bt(t),n&&(u=n.getPropertyValue(e)||n[e]),n&&(""!==u||Q.contains(t.ownerDocument,t)||(u=Q.style(t,e)),$t.test(u)&&Mt.test(e)&&(r=a.width,i=a.minWidth,o=a.maxWidth,a.minWidth=a.maxWidth=a.width=u,u=n.width,a.width=r,a.minWidth=i,a.maxWidth=o)),void 0!==u?u+"":u}function w(t,e){return{get:function(){return t()?void delete this.get:(this.get=e).apply(this,arguments)}}}function C(t,e){if(e in t)return e;for(var n=e[0].toUpperCase()+e.slice(1),r=e,i=Vt.length;i--;)if(e=Vt[i]+n,e in t)return e;return r}function k(t,e,n){var r=Jt.exec(e);return r?Math.max(0,r[1]-(n||0))+(r[2]||"px"):e}function T(t,e,n,r,i){for(var o=n===(r?"border":"content")?4:"width"===e?1:0,u=0;o<4;o+=2)"margin"===n&&(u+=Q.css(t,n+wt[o],!0,i)),r?("content"===n&&(u-=Q.css(t,"padding"+wt[o],!0,i)),"margin"!==n&&(u-=Q.css(t,"border"+wt[o]+"Width",!0,i))):(u+=Q.css(t,"padding"+wt[o],!0,i),"padding"!==n&&(u+=Q.css(t,"border"+wt[o]+"Width",!0,i)));return u}function j(t,e,n){var r=!0,i="width"===e?t.offsetWidth:t.offsetHeight,o=Bt(t),u="border-box"===Q.css(t,"boxSizing",!1,o);if(i<=0||null==i){if(i=_(t,e,o),(i<0||null==i)&&(i=t.style[e]),$t.test(i))return i;r=u&&(Y.boxSizingReliable()||i===t.style[e]),i=parseFloat(i)||0}return i+T(t,e,n||(u?"border":"content"),r,o)+"px"}function A(t,e){for(var n,r,i,o=[],u=0,a=t.length;u<a;u++)r=t[u],r.style&&(o[u]=mt.get(r,"olddisplay"),n=r.style.display,e?(o[u]||"none"!==n||(r.style.display=""),""===r.style.display&&Ct(r)&&(o[u]=mt.access(r,"olddisplay",x(r.nodeName)))):(i=Ct(r),"none"===n&&i||mt.set(r,"olddisplay",i?n:Q.css(r,"display"))));for(u=0;u<a;u++)r=t[u],r.style&&(e&&"none"!==r.style.display&&""!==r.style.display||(r.style.display=e?o[u]||"":"none"));return t}function E(t,e,n,r,i){return new E.prototype.init(t,e,n,r,i)}function S(){return setTimeout(function(){Yt=void 0}),Yt=Q.now()}function N(t,e){var n,r=0,i={height:t};for(e=e?1:0;r<4;r+=2-e)n=wt[r],i["margin"+n]=i["padding"+n]=t;return e&&(i.opacity=i.width=t),i}function D(t,e,n){for(var r,i=(ne[e]||[]).concat(ne["*"]),o=0,u=i.length;o<u;o++)if(r=i[o].call(n,e,t))return r}function O(t,e,n){var r,i,o,u,a,c,s,l,f=this,p={},h=t.style,d=t.nodeType&&Ct(t),g=mt.get(t,"fxshow");n.queue||(a=Q._queueHooks(t,"fx"),null==a.unqueued&&(a.unqueued=0,c=a.empty.fire,a.empty.fire=function(){a.unqueued||c()}),a.unqueued++,f.always(function(){f.always(function(){a.unqueued--,Q.queue(t,"fx").length||a.empty.fire()})})),1===t.nodeType&&("height"in e||"width"in e)&&(n.overflow=[h.overflow,h.overflowX,h.overflowY],s=Q.css(t,"display"),l="none"===s?mt.get(t,"olddisplay")||x(t.nodeName):s,"inline"===l&&"none"===Q.css(t,"float")&&(h.display="inline-block")),n.overflow&&(h.overflow="hidden",f.always(function(){h.overflow=n.overflow[0],h.overflowX=n.overflow[1],h.overflowY=n.overflow[2]}));for(r in e)if(i=e[r],Zt.exec(i)){if(delete e[r],o=o||"toggle"===i,i===(d?"hide":"show")){if("show"!==i||!g||void 0===g[r])continue;d=!0}p[r]=g&&g[r]||Q.style(t,r)}else s=void 0;if(Q.isEmptyObject(p))"inline"===("none"===s?x(t.nodeName):s)&&(h.display=s);else{g?"hidden"in g&&(d=g.hidden):g=mt.access(t,"fxshow",{}),o&&(g.hidden=!d),d?Q(t).show():f.done(function(){Q(t).hide()}),f.done(function(){var e;mt.remove(t,"fxshow");for(e in p)Q.style(t,e,p[e])});for(r in p)u=D(d?g[r]:0,r,f),r in g||(g[r]=u.start,d&&(u.end=u.start,u.start="width"===r||"height"===r?1:0))}}function L(t,e){var n,r,i,o,u;for(n in t)if(r=Q.camelCase(n),i=e[r],o=t[n],Q.isArray(o)&&(i=o[1],o=t[n]=o[0]),n!==r&&(t[r]=o,delete t[n]),u=Q.cssHooks[r],u&&"expand"in u){o=u.expand(o),delete t[r];for(n in o)n in t||(t[n]=o[n],e[n]=i)}else e[r]=i}function R(t,e,n){var r,i,o=0,u=ee.length,a=Q.Deferred().always(function(){delete c.elem}),c=function(){if(i)return!1;for(var e=Yt||S(),n=Math.max(0,s.startTime+s.duration-e),r=n/s.duration||0,o=1-r,u=0,c=s.tweens.length;u<c;u++)s.tweens[u].run(o);return a.notifyWith(t,[s,o,n]),o<1&&c?n:(a.resolveWith(t,[s]),!1)},s=a.promise({elem:t,props:Q.extend({},e),opts:Q.extend(!0,{specialEasing:{}},n),originalProperties:e,originalOptions:n,startTime:Yt||S(),duration:n.duration,tweens:[],createTween:function(e,n){var r=Q.Tween(t,s.opts,e,n,s.opts.specialEasing[e]||s.opts.easing);return s.tweens.push(r),r},stop:function(e){var n=0,r=e?s.tweens.length:0;if(i)return this;for(i=!0;n<r;n++)s.tweens[n].run(1);return e?a.resolveWith(t,[s,e]):a.rejectWith(t,[s,e]),this}}),l=s.props;for(L(l,s.opts.specialEasing);o<u;o++)if(r=ee[o].call(s,t,l,s.opts))return r;return Q.map(l,D,s),Q.isFunction(s.opts.start)&&s.opts.start.call(t,s),Q.fx.timer(Q.extend(c,{elem:t,anim:s,queue:s.opts.queue})),s.progress(s.opts.progress).done(s.opts.done,s.opts.complete).fail(s.opts.fail).always(s.opts.always)}function q(t){return function(e,n){"string"!=typeof e&&(n=e,e="*");var r,i=0,o=e.toLowerCase().match(ht)||[];if(Q.isFunction(n))for(;r=o[i++];)"+"===r[0]?(r=r.slice(1)||"*",(t[r]=t[r]||[]).unshift(n)):(t[r]=t[r]||[]).push(n)}}function H(t,e,n,r){function i(a){var c;return o[a]=!0,Q.each(t[a]||[],function(t,a){var s=a(e,n,r);return"string"!=typeof s||u||o[s]?u?!(c=s):void 0:(e.dataTypes.unshift(s),i(s),!1)}),c}var o={},u=t===be;return i(e.dataTypes[0])||!o["*"]&&i("*")}function P(t,e){var n,r,i=Q.ajaxSettings.flatOptions||{};for(n in e)void 0!==e[n]&&((i[n]?t:r||(r={}))[n]=e[n]);return r&&Q.extend(!0,t,r),t}function I(t,e,n){for(var r,i,o,u,a=t.contents,c=t.dataTypes;"*"===c[0];)c.shift(),void 0===r&&(r=t.mimeType||e.getResponseHeader("Content-Type"));if(r)for(i in a)if(a[i]&&a[i].test(r)){c.unshift(i);break}if(c[0]in n)o=c[0];else{for(i in n){if(!c[0]||t.converters[i+" "+c[0]]){o=i;break}u||(u=i)}o=o||u}if(o)return o!==c[0]&&c.unshift(o),n[o]}function W(t,e,n,r){var i,o,u,a,c,s={},l=t.dataTypes.slice();if(l[1])for(u in t.converters)s[u.toLowerCase()]=t.converters[u];for(o=l.shift();o;)if(t.responseFields[o]&&(n[t.responseFields[o]]=e),!c&&r&&t.dataFilter&&(e=t.dataFilter(e,t.dataType)),c=o,o=l.shift())if("*"===o)o=c;else if("*"!==c&&c!==o){if(u=s[c+" "+o]||s["* "+o],!u)for(i in s)if(a=i.split(" "),a[1]===o&&(u=s[c+" "+a[0]]||s["* "+a[0]])){u===!0?u=s[i]:s[i]!==!0&&(o=a[0],l.unshift(a[1]));break}if(u!==!0)if(u&&t["throws"])e=u(e);else try{e=u(e)}catch(f){return{state:"parsererror",error:u?f:"No conversion from "+c+" to "+o}}}return{state:"success",data:e}}function F(t,e,n,r){var i;if(Q.isArray(e))Q.each(e,function(e,i){n||ke.test(t)?r(t,i):F(t+"["+("object"==typeof i?e:"")+"]",i,n,r)});else if(n||"object"!==Q.type(e))r(t,e);else for(i in e)F(t+"["+i+"]",e[i],n,r)}function M(t){return Q.isWindow(t)?t:9===t.nodeType&&t.defaultView}var $=[],B=$.slice,z=$.concat,J=$.push,U=$.indexOf,K={},X=K.toString,V=K.hasOwnProperty,Y={},G=t.document,Z="2.1.4",Q=function(t,e){return new Q.fn.init(t,e)},tt=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,et=/^-ms-/,nt=/-([\da-z])/gi,rt=function(t,e){return e.toUpperCase()};Q.fn=Q.prototype={jquery:Z,constructor:Q,selector:"",length:0,toArray:function(){return B.call(this)},get:function(t){return null!=t?t<0?this[t+this.length]:this[t]:B.call(this)},pushStack:function(t){var e=Q.merge(this.constructor(),t);return e.prevObject=this,e.context=this.context,e},each:function(t,e){return Q.each(this,t,e)},map:function(t){return this.pushStack(Q.map(this,function(e,n){return t.call(e,n,e)}))},slice:function(){return this.pushStack(B.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},eq:function(t){var e=this.length,n=+t+(t<0?e:0);return this.pushStack(n>=0&&n<e?[this[n]]:[])},end:function(){return this.prevObject||this.constructor(null)},push:J,sort:$.sort,splice:$.splice},Q.extend=Q.fn.extend=function(){var t,e,n,r,i,o,u=arguments[0]||{},a=1,c=arguments.length,s=!1;for("boolean"==typeof u&&(s=u,u=arguments[a]||{},a++),"object"==typeof u||Q.isFunction(u)||(u={}),a===c&&(u=this,a--);a<c;a++)if(null!=(t=arguments[a]))for(e in t)n=u[e],r=t[e],u!==r&&(s&&r&&(Q.isPlainObject(r)||(i=Q.isArray(r)))?(i?(i=!1,o=n&&Q.isArray(n)?n:[]):o=n&&Q.isPlainObject(n)?n:{},u[e]=Q.extend(s,o,r)):void 0!==r&&(u[e]=r));return u},Q.extend({expando:"jQuery"+(Z+Math.random()).replace(/\D/g,""),isReady:!0,error:function(t){throw new Error(t)},noop:function(){},isFunction:function(t){return"function"===Q.type(t)},isArray:Array.isArray,isWindow:function(t){return null!=t&&t===t.window},isNumeric:function(t){return!Q.isArray(t)&&t-parseFloat(t)+1>=0},isPlainObject:function(t){return"object"===Q.type(t)&&!t.nodeType&&!Q.isWindow(t)&&!(t.constructor&&!V.call(t.constructor.prototype,"isPrototypeOf"))},isEmptyObject:function(t){var e;for(e in t)return!1;return!0},type:function(t){return null==t?t+"":"object"==typeof t||"function"==typeof t?K[X.call(t)]||"object":typeof t},globalEval:function(t){var e,n=eval;t=Q.trim(t),t&&(1===t.indexOf("use strict")?(e=G.createElement("script"),e.text=t,G.head.appendChild(e).parentNode.removeChild(e)):n(t))},camelCase:function(t){return t.replace(et,"ms-").replace(nt,rt)},nodeName:function(t,e){return t.nodeName&&t.nodeName.toLowerCase()===e.toLowerCase()},each:function(t,e,r){var i,o=0,u=t.length,a=n(t);if(r){if(a)for(;o<u&&(i=e.apply(t[o],r),i!==!1);o++);else for(o in t)if(i=e.apply(t[o],r),i===!1)break}else if(a)for(;o<u&&(i=e.call(t[o],o,t[o]),i!==!1);o++);else for(o in t)if(i=e.call(t[o],o,t[o]),i===!1)break;return t},trim:function(t){return null==t?"":(t+"").replace(tt,"")},makeArray:function(t,e){var r=e||[];return null!=t&&(n(Object(t))?Q.merge(r,"string"==typeof t?[t]:t):J.call(r,t)),r},inArray:function(t,e,n){return null==e?-1:U.call(e,t,n)},merge:function(t,e){for(var n=+e.length,r=0,i=t.length;r<n;r++)t[i++]=e[r];return t.length=i,t},grep:function(t,e,n){for(var r,i=[],o=0,u=t.length,a=!n;o<u;o++)r=!e(t[o],o),r!==a&&i.push(t[o]);return i},map:function(t,e,r){var i,o=0,u=t.length,a=n(t),c=[];if(a)for(;o<u;o++)i=e(t[o],o,r),null!=i&&c.push(i);else for(o in t)i=e(t[o],o,r),null!=i&&c.push(i);return z.apply([],c)},guid:1,proxy:function(t,e){var n,r,i;if("string"==typeof e&&(n=t[e],e=t,t=n),Q.isFunction(t))return r=B.call(arguments,2),i=function(){return t.apply(e||this,r.concat(B.call(arguments)))},i.guid=t.guid=t.guid||Q.guid++,i},now:Date.now,support:Y}),Q.each("Boolean Number String Function Array Date RegExp Object Error".split(" "),function(t,e){K["[object "+e+"]"]=e.toLowerCase()});var it=function(t){function e(t,e,n,r){var i,o,u,a,c,s,f,h,d,g;if((e?e.ownerDocument||e:F)!==O&&D(e),e=e||O,n=n||[],a=e.nodeType,"string"!=typeof t||!t||1!==a&&9!==a&&11!==a)return n;if(!r&&R){if(11!==a&&(i=yt.exec(t)))if(u=i[1]){if(9===a){if(o=e.getElementById(u),!o||!o.parentNode)return n;if(o.id===u)return n.push(o),n}else if(e.ownerDocument&&(o=e.ownerDocument.getElementById(u))&&I(e,o)&&o.id===u)return n.push(o),n}else{if(i[2])return Z.apply(n,e.getElementsByTagName(t)),n;if((u=i[3])&&_.getElementsByClassName)return Z.apply(n,e.getElementsByClassName(u)),n}if(_.qsa&&(!q||!q.test(t))){if(h=f=W,d=e,g=1!==a&&t,1===a&&"object"!==e.nodeName.toLowerCase()){for(s=T(t),(f=e.getAttribute("id"))?h=f.replace(xt,"\\$&"):e.setAttribute("id",h),h="[id='"+h+"'] ",c=s.length;c--;)s[c]=h+p(s[c]);d=bt.test(t)&&l(e.parentNode)||e,g=s.join(",")}if(g)try{return Z.apply(n,d.querySelectorAll(g)),n}catch(v){}finally{f||e.removeAttribute("id")}}}return A(t.replace(ct,"$1"),e,n,r)}function n(){function t(n,r){return e.push(n+" ")>w.cacheLength&&delete t[e.shift()],t[n+" "]=r}var e=[];return t}function r(t){return t[W]=!0,t}function i(t){var e=O.createElement("div");try{return!!t(e)}catch(n){return!1}finally{e.parentNode&&e.parentNode.removeChild(e),e=null}}function o(t,e){for(var n=t.split("|"),r=t.length;r--;)w.attrHandle[n[r]]=e}function u(t,e){var n=e&&t,r=n&&1===t.nodeType&&1===e.nodeType&&(~e.sourceIndex||K)-(~t.sourceIndex||K);if(r)return r;if(n)for(;n=n.nextSibling;)if(n===e)return-1;return t?1:-1}function a(t){return function(e){var n=e.nodeName.toLowerCase();return"input"===n&&e.type===t}}function c(t){return function(e){var n=e.nodeName.toLowerCase();return("input"===n||"button"===n)&&e.type===t}}function s(t){return r(function(e){return e=+e,r(function(n,r){for(var i,o=t([],n.length,e),u=o.length;u--;)n[i=o[u]]&&(n[i]=!(r[i]=n[i]))})})}function l(t){return t&&"undefined"!=typeof t.getElementsByTagName&&t}function f(){}function p(t){for(var e=0,n=t.length,r="";e<n;e++)r+=t[e].value;return r}function h(t,e,n){var r=e.dir,i=n&&"parentNode"===r,o=$++;return e.first?function(e,n,o){for(;e=e[r];)if(1===e.nodeType||i)return t(e,n,o)}:function(e,n,u){var a,c,s=[M,o];if(u){for(;e=e[r];)if((1===e.nodeType||i)&&t(e,n,u))return!0}else for(;e=e[r];)if(1===e.nodeType||i){if(c=e[W]||(e[W]={}),(a=c[r])&&a[0]===M&&a[1]===o)return s[2]=a[2];if(c[r]=s,s[2]=t(e,n,u))return!0}}}function d(t){return t.length>1?function(e,n,r){for(var i=t.length;i--;)if(!t[i](e,n,r))return!1;return!0}:t[0]}function g(t,n,r){for(var i=0,o=n.length;i<o;i++)e(t,n[i],r);return r}function v(t,e,n,r,i){for(var o,u=[],a=0,c=t.length,s=null!=e;a<c;a++)(o=t[a])&&(n&&!n(o,r,i)||(u.push(o),s&&e.push(a)));return u}function m(t,e,n,i,o,u){return i&&!i[W]&&(i=m(i)),o&&!o[W]&&(o=m(o,u)),r(function(r,u,a,c){var s,l,f,p=[],h=[],d=u.length,m=r||g(e||"*",a.nodeType?[a]:a,[]),y=!t||!r&&e?m:v(m,p,t,a,c),b=n?o||(r?t:d||i)?[]:u:y;if(n&&n(y,b,a,c),i)for(s=v(b,h),i(s,[],a,c),l=s.length;l--;)(f=s[l])&&(b[h[l]]=!(y[h[l]]=f));if(r){if(o||t){if(o){for(s=[],l=b.length;l--;)(f=b[l])&&s.push(y[l]=f);o(null,b=[],s,c)}for(l=b.length;l--;)(f=b[l])&&(s=o?tt(r,f):p[l])>-1&&(r[s]=!(u[s]=f))}}else b=v(b===u?b.splice(d,b.length):b),o?o(null,u,b,c):Z.apply(u,b)})}function y(t){for(var e,n,r,i=t.length,o=w.relative[t[0].type],u=o||w.relative[" "],a=o?1:0,c=h(function(t){return t===e},u,!0),s=h(function(t){return tt(e,t)>-1},u,!0),l=[function(t,n,r){var i=!o&&(r||n!==E)||((e=n).nodeType?c(t,n,r):s(t,n,r));return e=null,i}];a<i;a++)if(n=w.relative[t[a].type])l=[h(d(l),n)];else{if(n=w.filter[t[a].type].apply(null,t[a].matches),n[W]){for(r=++a;r<i&&!w.relative[t[r].type];r++);return m(a>1&&d(l),a>1&&p(t.slice(0,a-1).concat({value:" "===t[a-2].type?"*":""})).replace(ct,"$1"),n,a<r&&y(t.slice(a,r)),r<i&&y(t=t.slice(r)),r<i&&p(t))}l.push(n)}return d(l)}function b(t,n){var i=n.length>0,o=t.length>0,u=function(r,u,a,c,s){var l,f,p,h=0,d="0",g=r&&[],m=[],y=E,b=r||o&&w.find.TAG("*",s),x=M+=null==y?1:Math.random()||.1,_=b.length;for(s&&(E=u!==O&&u);d!==_&&null!=(l=b[d]);d++){if(o&&l){for(f=0;p=t[f++];)if(p(l,u,a)){c.push(l);break}s&&(M=x)}i&&((l=!p&&l)&&h--,r&&g.push(l))}if(h+=d,i&&d!==h){for(f=0;p=n[f++];)p(g,m,u,a);if(r){if(h>0)for(;d--;)g[d]||m[d]||(m[d]=Y.call(c));m=v(m)}Z.apply(c,m),s&&!r&&m.length>0&&h+n.length>1&&e.uniqueSort(c)}return s&&(M=x,E=y),g};return i?r(u):u}var x,_,w,C,k,T,j,A,E,S,N,D,O,L,R,q,H,P,I,W="sizzle"+1*new Date,F=t.document,M=0,$=0,B=n(),z=n(),J=n(),U=function(t,e){return t===e&&(N=!0),0},K=1<<31,X={}.hasOwnProperty,V=[],Y=V.pop,G=V.push,Z=V.push,Q=V.slice,tt=function(t,e){for(var n=0,r=t.length;n<r;n++)if(t[n]===e)return n;return-1},et="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",nt="[\\x20\\t\\r\\n\\f]",rt="(?:\\\\.|[\\w-]|[^\\x00-\\xa0])+",it=rt.replace("w","w#"),ot="\\["+nt+"*("+rt+")(?:"+nt+"*([*^$|!~]?=)"+nt+"*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|("+it+"))|)"+nt+"*\\]",ut=":("+rt+")(?:\\((('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|((?:\\\\.|[^\\\\()[\\]]|"+ot+")*)|.*)\\)|)",at=new RegExp(nt+"+","g"),ct=new RegExp("^"+nt+"+|((?:^|[^\\\\])(?:\\\\.)*)"+nt+"+$","g"),st=new RegExp("^"+nt+"*,"+nt+"*"),lt=new RegExp("^"+nt+"*([>+~]|"+nt+")"+nt+"*"),ft=new RegExp("="+nt+"*([^\\]'\"]*?)"+nt+"*\\]","g"),pt=new RegExp(ut),ht=new RegExp("^"+it+"$"),dt={ID:new RegExp("^#("+rt+")"),CLASS:new RegExp("^\\.("+rt+")"),TAG:new RegExp("^("+rt.replace("w","w*")+")"),ATTR:new RegExp("^"+ot),PSEUDO:new RegExp("^"+ut),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+nt+"*(even|odd|(([+-]|)(\\d*)n|)"+nt+"*(?:([+-]|)"+nt+"*(\\d+)|))"+nt+"*\\)|)","i"),bool:new RegExp("^(?:"+et+")$","i"),needsContext:new RegExp("^"+nt+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+nt+"*((?:-\\d)?\\d*)"+nt+"*\\)|)(?=[^-]|$)","i")},gt=/^(?:input|select|textarea|button)$/i,vt=/^h\d$/i,mt=/^[^{]+\{\s*\[native \w/,yt=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,bt=/[+~]/,xt=/'|\\/g,_t=new RegExp("\\\\([\\da-f]{1,6}"+nt+"?|("+nt+")|.)","ig"),wt=function(t,e,n){var r="0x"+e-65536;return r!==r||n?e:r<0?String.fromCharCode(r+65536):String.fromCharCode(r>>10|55296,1023&r|56320)},Ct=function(){D()};try{Z.apply(V=Q.call(F.childNodes),F.childNodes),V[F.childNodes.length].nodeType}catch(kt){Z={apply:V.length?function(t,e){G.apply(t,Q.call(e))}:function(t,e){for(var n=t.length,r=0;t[n++]=e[r++];);t.length=n-1}}}_=e.support={},k=e.isXML=function(t){var e=t&&(t.ownerDocument||t).documentElement;return!!e&&"HTML"!==e.nodeName},D=e.setDocument=function(t){var e,n,r=t?t.ownerDocument||t:F;return r!==O&&9===r.nodeType&&r.documentElement?(O=r,L=r.documentElement,n=r.defaultView,n&&n!==n.top&&(n.addEventListener?n.addEventListener("unload",Ct,!1):n.attachEvent&&n.attachEvent("onunload",Ct)),R=!k(r),_.attributes=i(function(t){return t.className="i",!t.getAttribute("className")}),_.getElementsByTagName=i(function(t){return t.appendChild(r.createComment("")),!t.getElementsByTagName("*").length}),_.getElementsByClassName=mt.test(r.getElementsByClassName),_.getById=i(function(t){return L.appendChild(t).id=W,!r.getElementsByName||!r.getElementsByName(W).length}),_.getById?(w.find.ID=function(t,e){if("undefined"!=typeof e.getElementById&&R){var n=e.getElementById(t);return n&&n.parentNode?[n]:[]}},w.filter.ID=function(t){var e=t.replace(_t,wt);return function(t){return t.getAttribute("id")===e}}):(delete w.find.ID,w.filter.ID=function(t){var e=t.replace(_t,wt);return function(t){var n="undefined"!=typeof t.getAttributeNode&&t.getAttributeNode("id");return n&&n.value===e}}),w.find.TAG=_.getElementsByTagName?function(t,e){return"undefined"!=typeof e.getElementsByTagName?e.getElementsByTagName(t):_.qsa?e.querySelectorAll(t):void 0}:function(t,e){var n,r=[],i=0,o=e.getElementsByTagName(t);if("*"===t){for(;n=o[i++];)1===n.nodeType&&r.push(n);return r}return o},w.find.CLASS=_.getElementsByClassName&&function(t,e){if(R)return e.getElementsByClassName(t)},H=[],q=[],(_.qsa=mt.test(r.querySelectorAll))&&(i(function(t){L.appendChild(t).innerHTML="<a id='"+W+"'></a><select id='"+W+"-\f]' msallowcapture=''><option selected=''></option></select>",t.querySelectorAll("[msallowcapture^='']").length&&q.push("[*^$]="+nt+"*(?:''|\"\")"),t.querySelectorAll("[selected]").length||q.push("\\["+nt+"*(?:value|"+et+")"),t.querySelectorAll("[id~="+W+"-]").length||q.push("~="),t.querySelectorAll(":checked").length||q.push(":checked"),t.querySelectorAll("a#"+W+"+*").length||q.push(".#.+[+~]")}),i(function(t){var e=r.createElement("input");e.setAttribute("type","hidden"),t.appendChild(e).setAttribute("name","D"),t.querySelectorAll("[name=d]").length&&q.push("name"+nt+"*[*^$|!~]?="),t.querySelectorAll(":enabled").length||q.push(":enabled",":disabled"),t.querySelectorAll("*,:x"),q.push(",.*:")})),(_.matchesSelector=mt.test(P=L.matches||L.webkitMatchesSelector||L.mozMatchesSelector||L.oMatchesSelector||L.msMatchesSelector))&&i(function(t){_.disconnectedMatch=P.call(t,"div"),P.call(t,"[s!='']:x"),H.push("!=",ut)}),q=q.length&&new RegExp(q.join("|")),H=H.length&&new RegExp(H.join("|")),e=mt.test(L.compareDocumentPosition),I=e||mt.test(L.contains)?function(t,e){var n=9===t.nodeType?t.documentElement:t,r=e&&e.parentNode;return t===r||!(!r||1!==r.nodeType||!(n.contains?n.contains(r):t.compareDocumentPosition&&16&t.compareDocumentPosition(r)))}:function(t,e){if(e)for(;e=e.parentNode;)if(e===t)return!0;return!1},U=e?function(t,e){if(t===e)return N=!0,0;var n=!t.compareDocumentPosition-!e.compareDocumentPosition;return n?n:(n=(t.ownerDocument||t)===(e.ownerDocument||e)?t.compareDocumentPosition(e):1,1&n||!_.sortDetached&&e.compareDocumentPosition(t)===n?t===r||t.ownerDocument===F&&I(F,t)?-1:e===r||e.ownerDocument===F&&I(F,e)?1:S?tt(S,t)-tt(S,e):0:4&n?-1:1)}:function(t,e){if(t===e)return N=!0,0;var n,i=0,o=t.parentNode,a=e.parentNode,c=[t],s=[e];if(!o||!a)return t===r?-1:e===r?1:o?-1:a?1:S?tt(S,t)-tt(S,e):0;if(o===a)return u(t,e);for(n=t;n=n.parentNode;)c.unshift(n);for(n=e;n=n.parentNode;)s.unshift(n);for(;c[i]===s[i];)i++;return i?u(c[i],s[i]):c[i]===F?-1:s[i]===F?1:0},r):O},e.matches=function(t,n){return e(t,null,null,n)},e.matchesSelector=function(t,n){if((t.ownerDocument||t)!==O&&D(t),n=n.replace(ft,"='$1']"),_.matchesSelector&&R&&(!H||!H.test(n))&&(!q||!q.test(n)))try{var r=P.call(t,n);if(r||_.disconnectedMatch||t.document&&11!==t.document.nodeType)return r}catch(i){}return e(n,O,null,[t]).length>0},e.contains=function(t,e){return(t.ownerDocument||t)!==O&&D(t),I(t,e)},e.attr=function(t,e){(t.ownerDocument||t)!==O&&D(t);var n=w.attrHandle[e.toLowerCase()],r=n&&X.call(w.attrHandle,e.toLowerCase())?n(t,e,!R):void 0;return void 0!==r?r:_.attributes||!R?t.getAttribute(e):(r=t.getAttributeNode(e))&&r.specified?r.value:null},e.error=function(t){throw new Error("Syntax error, unrecognized expression: "+t)},e.uniqueSort=function(t){var e,n=[],r=0,i=0;if(N=!_.detectDuplicates,S=!_.sortStable&&t.slice(0),t.sort(U),N){for(;e=t[i++];)e===t[i]&&(r=n.push(i));for(;r--;)t.splice(n[r],1)}return S=null,t},C=e.getText=function(t){var e,n="",r=0,i=t.nodeType;if(i){if(1===i||9===i||11===i){if("string"==typeof t.textContent)return t.textContent;for(t=t.firstChild;t;t=t.nextSibling)n+=C(t)}else if(3===i||4===i)return t.nodeValue}else for(;e=t[r++];)n+=C(e);return n},w=e.selectors={cacheLength:50,createPseudo:r,match:dt,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(t){return t[1]=t[1].replace(_t,wt),t[3]=(t[3]||t[4]||t[5]||"").replace(_t,wt),"~="===t[2]&&(t[3]=" "+t[3]+" "),t.slice(0,4)},CHILD:function(t){return t[1]=t[1].toLowerCase(),"nth"===t[1].slice(0,3)?(t[3]||e.error(t[0]),t[4]=+(t[4]?t[5]+(t[6]||1):2*("even"===t[3]||"odd"===t[3])),t[5]=+(t[7]+t[8]||"odd"===t[3])):t[3]&&e.error(t[0]),t},PSEUDO:function(t){var e,n=!t[6]&&t[2];return dt.CHILD.test(t[0])?null:(t[3]?t[2]=t[4]||t[5]||"":n&&pt.test(n)&&(e=T(n,!0))&&(e=n.indexOf(")",n.length-e)-n.length)&&(t[0]=t[0].slice(0,e),t[2]=n.slice(0,e)),t.slice(0,3))}},filter:{TAG:function(t){var e=t.replace(_t,wt).toLowerCase();return"*"===t?function(){return!0}:function(t){return t.nodeName&&t.nodeName.toLowerCase()===e}},CLASS:function(t){var e=B[t+" "];return e||(e=new RegExp("(^|"+nt+")"+t+"("+nt+"|$)"))&&B(t,function(t){return e.test("string"==typeof t.className&&t.className||"undefined"!=typeof t.getAttribute&&t.getAttribute("class")||"")})},ATTR:function(t,n,r){return function(i){var o=e.attr(i,t);return null==o?"!="===n:!n||(o+="","="===n?o===r:"!="===n?o!==r:"^="===n?r&&0===o.indexOf(r):"*="===n?r&&o.indexOf(r)>-1:"$="===n?r&&o.slice(-r.length)===r:"~="===n?(" "+o.replace(at," ")+" ").indexOf(r)>-1:"|="===n&&(o===r||o.slice(0,r.length+1)===r+"-"))}},CHILD:function(t,e,n,r,i){var o="nth"!==t.slice(0,3),u="last"!==t.slice(-4),a="of-type"===e;return 1===r&&0===i?function(t){return!!t.parentNode}:function(e,n,c){var s,l,f,p,h,d,g=o!==u?"nextSibling":"previousSibling",v=e.parentNode,m=a&&e.nodeName.toLowerCase(),y=!c&&!a;if(v){if(o){for(;g;){for(f=e;f=f[g];)if(a?f.nodeName.toLowerCase()===m:1===f.nodeType)return!1;d=g="only"===t&&!d&&"nextSibling"}return!0}if(d=[u?v.firstChild:v.lastChild],u&&y){for(l=v[W]||(v[W]={}),s=l[t]||[],h=s[0]===M&&s[1],p=s[0]===M&&s[2],f=h&&v.childNodes[h];f=++h&&f&&f[g]||(p=h=0)||d.pop();)if(1===f.nodeType&&++p&&f===e){l[t]=[M,h,p];break}}else if(y&&(s=(e[W]||(e[W]={}))[t])&&s[0]===M)p=s[1];else for(;(f=++h&&f&&f[g]||(p=h=0)||d.pop())&&((a?f.nodeName.toLowerCase()!==m:1!==f.nodeType)||!++p||(y&&((f[W]||(f[W]={}))[t]=[M,p]),f!==e)););return p-=i,p===r||p%r===0&&p/r>=0}}},PSEUDO:function(t,n){var i,o=w.pseudos[t]||w.setFilters[t.toLowerCase()]||e.error("unsupported pseudo: "+t);return o[W]?o(n):o.length>1?(i=[t,t,"",n],w.setFilters.hasOwnProperty(t.toLowerCase())?r(function(t,e){for(var r,i=o(t,n),u=i.length;u--;)r=tt(t,i[u]),t[r]=!(e[r]=i[u])}):function(t){return o(t,0,i)}):o}},pseudos:{not:r(function(t){var e=[],n=[],i=j(t.replace(ct,"$1"));return i[W]?r(function(t,e,n,r){for(var o,u=i(t,null,r,[]),a=t.length;a--;)(o=u[a])&&(t[a]=!(e[a]=o))}):function(t,r,o){return e[0]=t,i(e,null,o,n),e[0]=null,!n.pop()}}),has:r(function(t){return function(n){return e(t,n).length>0}}),contains:r(function(t){return t=t.replace(_t,wt),function(e){return(e.textContent||e.innerText||C(e)).indexOf(t)>-1}}),lang:r(function(t){return ht.test(t||"")||e.error("unsupported lang: "+t),t=t.replace(_t,wt).toLowerCase(),function(e){var n;do if(n=R?e.lang:e.getAttribute("xml:lang")||e.getAttribute("lang"))return n=n.toLowerCase(),n===t||0===n.indexOf(t+"-");while((e=e.parentNode)&&1===e.nodeType);return!1}}),target:function(e){var n=t.location&&t.location.hash;return n&&n.slice(1)===e.id},root:function(t){return t===L},focus:function(t){return t===O.activeElement&&(!O.hasFocus||O.hasFocus())&&!!(t.type||t.href||~t.tabIndex)},enabled:function(t){return t.disabled===!1},disabled:function(t){return t.disabled===!0},checked:function(t){var e=t.nodeName.toLowerCase();return"input"===e&&!!t.checked||"option"===e&&!!t.selected},selected:function(t){return t.parentNode&&t.parentNode.selectedIndex,t.selected===!0},empty:function(t){for(t=t.firstChild;t;t=t.nextSibling)if(t.nodeType<6)return!1;return!0},parent:function(t){return!w.pseudos.empty(t)},header:function(t){return vt.test(t.nodeName)},input:function(t){return gt.test(t.nodeName)},button:function(t){var e=t.nodeName.toLowerCase();return"input"===e&&"button"===t.type||"button"===e},text:function(t){var e;return"input"===t.nodeName.toLowerCase()&&"text"===t.type&&(null==(e=t.getAttribute("type"))||"text"===e.toLowerCase())},first:s(function(){return[0]}),last:s(function(t,e){return[e-1]}),eq:s(function(t,e,n){return[n<0?n+e:n]}),even:s(function(t,e){for(var n=0;n<e;n+=2)t.push(n);return t}),odd:s(function(t,e){for(var n=1;n<e;n+=2)t.push(n);return t}),lt:s(function(t,e,n){for(var r=n<0?n+e:n;--r>=0;)t.push(r);return t}),gt:s(function(t,e,n){for(var r=n<0?n+e:n;++r<e;)t.push(r);return t})}},w.pseudos.nth=w.pseudos.eq;for(x in{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})w.pseudos[x]=a(x);for(x in{submit:!0,reset:!0})w.pseudos[x]=c(x);return f.prototype=w.filters=w.pseudos,w.setFilters=new f,T=e.tokenize=function(t,n){var r,i,o,u,a,c,s,l=z[t+" "];if(l)return n?0:l.slice(0);for(a=t,c=[],s=w.preFilter;a;){r&&!(i=st.exec(a))||(i&&(a=a.slice(i[0].length)||a),c.push(o=[])),r=!1,(i=lt.exec(a))&&(r=i.shift(),o.push({value:r,type:i[0].replace(ct," ")}),a=a.slice(r.length));for(u in w.filter)!(i=dt[u].exec(a))||s[u]&&!(i=s[u](i))||(r=i.shift(),o.push({value:r,type:u,matches:i}),a=a.slice(r.length));if(!r)break}return n?a.length:a?e.error(t):z(t,c).slice(0)},j=e.compile=function(t,e){var n,r=[],i=[],o=J[t+" "];if(!o){for(e||(e=T(t)),n=e.length;n--;)o=y(e[n]),o[W]?r.push(o):i.push(o);o=J(t,b(i,r)),o.selector=t}return o},A=e.select=function(t,e,n,r){var i,o,u,a,c,s="function"==typeof t&&t,f=!r&&T(t=s.selector||t);if(n=n||[],1===f.length){if(o=f[0]=f[0].slice(0),o.length>2&&"ID"===(u=o[0]).type&&_.getById&&9===e.nodeType&&R&&w.relative[o[1].type]){if(e=(w.find.ID(u.matches[0].replace(_t,wt),e)||[])[0],!e)return n;s&&(e=e.parentNode),t=t.slice(o.shift().value.length)}for(i=dt.needsContext.test(t)?0:o.length;i--&&(u=o[i],!w.relative[a=u.type]);)if((c=w.find[a])&&(r=c(u.matches[0].replace(_t,wt),bt.test(o[0].type)&&l(e.parentNode)||e))){if(o.splice(i,1),t=r.length&&p(o),!t)return Z.apply(n,r),n;break}}return(s||j(t,f))(r,e,!R,n,bt.test(t)&&l(e.parentNode)||e),n},_.sortStable=W.split("").sort(U).join("")===W,_.detectDuplicates=!!N,D(),_.sortDetached=i(function(t){return 1&t.compareDocumentPosition(O.createElement("div"))}),i(function(t){return t.innerHTML="<a href='#'></a>","#"===t.firstChild.getAttribute("href")})||o("type|href|height|width",function(t,e,n){if(!n)return t.getAttribute(e,"type"===e.toLowerCase()?1:2)}),_.attributes&&i(function(t){return t.innerHTML="<input/>",t.firstChild.setAttribute("value",""),""===t.firstChild.getAttribute("value")})||o("value",function(t,e,n){if(!n&&"input"===t.nodeName.toLowerCase())return t.defaultValue}),i(function(t){return null==t.getAttribute("disabled")})||o(et,function(t,e,n){var r;if(!n)return t[e]===!0?e.toLowerCase():(r=t.getAttributeNode(e))&&r.specified?r.value:null}),e}(t);Q.find=it,Q.expr=it.selectors,Q.expr[":"]=Q.expr.pseudos,Q.unique=it.uniqueSort,Q.text=it.getText,Q.isXMLDoc=it.isXML,Q.contains=it.contains;var ot=Q.expr.match.needsContext,ut=/^<(\w+)\s*\/?>(?:<\/\1>|)$/,at=/^.[^:#\[\.,]*$/;Q.filter=function(t,e,n){var r=e[0];return n&&(t=":not("+t+")"),1===e.length&&1===r.nodeType?Q.find.matchesSelector(r,t)?[r]:[]:Q.find.matches(t,Q.grep(e,function(t){return 1===t.nodeType}))},Q.fn.extend({find:function(t){var e,n=this.length,r=[],i=this;if("string"!=typeof t)return this.pushStack(Q(t).filter(function(){
+for(e=0;e<n;e++)if(Q.contains(i[e],this))return!0}));for(e=0;e<n;e++)Q.find(t,i[e],r);return r=this.pushStack(n>1?Q.unique(r):r),r.selector=this.selector?this.selector+" "+t:t,r},filter:function(t){return this.pushStack(r(this,t||[],!1))},not:function(t){return this.pushStack(r(this,t||[],!0))},is:function(t){return!!r(this,"string"==typeof t&&ot.test(t)?Q(t):t||[],!1).length}});var ct,st=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]*))$/,lt=Q.fn.init=function(t,e){var n,r;if(!t)return this;if("string"==typeof t){if(n="<"===t[0]&&">"===t[t.length-1]&&t.length>=3?[null,t,null]:st.exec(t),!n||!n[1]&&e)return!e||e.jquery?(e||ct).find(t):this.constructor(e).find(t);if(n[1]){if(e=e instanceof Q?e[0]:e,Q.merge(this,Q.parseHTML(n[1],e&&e.nodeType?e.ownerDocument||e:G,!0)),ut.test(n[1])&&Q.isPlainObject(e))for(n in e)Q.isFunction(this[n])?this[n](e[n]):this.attr(n,e[n]);return this}return r=G.getElementById(n[2]),r&&r.parentNode&&(this.length=1,this[0]=r),this.context=G,this.selector=t,this}return t.nodeType?(this.context=this[0]=t,this.length=1,this):Q.isFunction(t)?"undefined"!=typeof ct.ready?ct.ready(t):t(Q):(void 0!==t.selector&&(this.selector=t.selector,this.context=t.context),Q.makeArray(t,this))};lt.prototype=Q.fn,ct=Q(G);var ft=/^(?:parents|prev(?:Until|All))/,pt={children:!0,contents:!0,next:!0,prev:!0};Q.extend({dir:function(t,e,n){for(var r=[],i=void 0!==n;(t=t[e])&&9!==t.nodeType;)if(1===t.nodeType){if(i&&Q(t).is(n))break;r.push(t)}return r},sibling:function(t,e){for(var n=[];t;t=t.nextSibling)1===t.nodeType&&t!==e&&n.push(t);return n}}),Q.fn.extend({has:function(t){var e=Q(t,this),n=e.length;return this.filter(function(){for(var t=0;t<n;t++)if(Q.contains(this,e[t]))return!0})},closest:function(t,e){for(var n,r=0,i=this.length,o=[],u=ot.test(t)||"string"!=typeof t?Q(t,e||this.context):0;r<i;r++)for(n=this[r];n&&n!==e;n=n.parentNode)if(n.nodeType<11&&(u?u.index(n)>-1:1===n.nodeType&&Q.find.matchesSelector(n,t))){o.push(n);break}return this.pushStack(o.length>1?Q.unique(o):o)},index:function(t){return t?"string"==typeof t?U.call(Q(t),this[0]):U.call(this,t.jquery?t[0]:t):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(t,e){return this.pushStack(Q.unique(Q.merge(this.get(),Q(t,e))))},addBack:function(t){return this.add(null==t?this.prevObject:this.prevObject.filter(t))}}),Q.each({parent:function(t){var e=t.parentNode;return e&&11!==e.nodeType?e:null},parents:function(t){return Q.dir(t,"parentNode")},parentsUntil:function(t,e,n){return Q.dir(t,"parentNode",n)},next:function(t){return i(t,"nextSibling")},prev:function(t){return i(t,"previousSibling")},nextAll:function(t){return Q.dir(t,"nextSibling")},prevAll:function(t){return Q.dir(t,"previousSibling")},nextUntil:function(t,e,n){return Q.dir(t,"nextSibling",n)},prevUntil:function(t,e,n){return Q.dir(t,"previousSibling",n)},siblings:function(t){return Q.sibling((t.parentNode||{}).firstChild,t)},children:function(t){return Q.sibling(t.firstChild)},contents:function(t){return t.contentDocument||Q.merge([],t.childNodes)}},function(t,e){Q.fn[t]=function(n,r){var i=Q.map(this,e,n);return"Until"!==t.slice(-5)&&(r=n),r&&"string"==typeof r&&(i=Q.filter(r,i)),this.length>1&&(pt[t]||Q.unique(i),ft.test(t)&&i.reverse()),this.pushStack(i)}});var ht=/\S+/g,dt={};Q.Callbacks=function(t){t="string"==typeof t?dt[t]||o(t):Q.extend({},t);var e,n,r,i,u,a,c=[],s=!t.once&&[],l=function(o){for(e=t.memory&&o,n=!0,a=i||0,i=0,u=c.length,r=!0;c&&a<u;a++)if(c[a].apply(o[0],o[1])===!1&&t.stopOnFalse){e=!1;break}r=!1,c&&(s?s.length&&l(s.shift()):e?c=[]:f.disable())},f={add:function(){if(c){var n=c.length;!function o(e){Q.each(e,function(e,n){var r=Q.type(n);"function"===r?t.unique&&f.has(n)||c.push(n):n&&n.length&&"string"!==r&&o(n)})}(arguments),r?u=c.length:e&&(i=n,l(e))}return this},remove:function(){return c&&Q.each(arguments,function(t,e){for(var n;(n=Q.inArray(e,c,n))>-1;)c.splice(n,1),r&&(n<=u&&u--,n<=a&&a--)}),this},has:function(t){return t?Q.inArray(t,c)>-1:!(!c||!c.length)},empty:function(){return c=[],u=0,this},disable:function(){return c=s=e=void 0,this},disabled:function(){return!c},lock:function(){return s=void 0,e||f.disable(),this},locked:function(){return!s},fireWith:function(t,e){return!c||n&&!s||(e=e||[],e=[t,e.slice?e.slice():e],r?s.push(e):l(e)),this},fire:function(){return f.fireWith(this,arguments),this},fired:function(){return!!n}};return f},Q.extend({Deferred:function(t){var e=[["resolve","done",Q.Callbacks("once memory"),"resolved"],["reject","fail",Q.Callbacks("once memory"),"rejected"],["notify","progress",Q.Callbacks("memory")]],n="pending",r={state:function(){return n},always:function(){return i.done(arguments).fail(arguments),this},then:function(){var t=arguments;return Q.Deferred(function(n){Q.each(e,function(e,o){var u=Q.isFunction(t[e])&&t[e];i[o[1]](function(){var t=u&&u.apply(this,arguments);t&&Q.isFunction(t.promise)?t.promise().done(n.resolve).fail(n.reject).progress(n.notify):n[o[0]+"With"](this===r?n.promise():this,u?[t]:arguments)})}),t=null}).promise()},promise:function(t){return null!=t?Q.extend(t,r):r}},i={};return r.pipe=r.then,Q.each(e,function(t,o){var u=o[2],a=o[3];r[o[1]]=u.add,a&&u.add(function(){n=a},e[1^t][2].disable,e[2][2].lock),i[o[0]]=function(){return i[o[0]+"With"](this===i?r:this,arguments),this},i[o[0]+"With"]=u.fireWith}),r.promise(i),t&&t.call(i,i),i},when:function(t){var e,n,r,i=0,o=B.call(arguments),u=o.length,a=1!==u||t&&Q.isFunction(t.promise)?u:0,c=1===a?t:Q.Deferred(),s=function(t,n,r){return function(i){n[t]=this,r[t]=arguments.length>1?B.call(arguments):i,r===e?c.notifyWith(n,r):--a||c.resolveWith(n,r)}};if(u>1)for(e=new Array(u),n=new Array(u),r=new Array(u);i<u;i++)o[i]&&Q.isFunction(o[i].promise)?o[i].promise().done(s(i,r,o)).fail(c.reject).progress(s(i,n,e)):--a;return a||c.resolveWith(r,o),c.promise()}});var gt;Q.fn.ready=function(t){return Q.ready.promise().done(t),this},Q.extend({isReady:!1,readyWait:1,holdReady:function(t){t?Q.readyWait++:Q.ready(!0)},ready:function(t){(t===!0?--Q.readyWait:Q.isReady)||(Q.isReady=!0,t!==!0&&--Q.readyWait>0||(gt.resolveWith(G,[Q]),Q.fn.triggerHandler&&(Q(G).triggerHandler("ready"),Q(G).off("ready"))))}}),Q.ready.promise=function(e){return gt||(gt=Q.Deferred(),"complete"===G.readyState?setTimeout(Q.ready):(G.addEventListener("DOMContentLoaded",u,!1),t.addEventListener("load",u,!1))),gt.promise(e)},Q.ready.promise();var vt=Q.access=function(t,e,n,r,i,o,u){var a=0,c=t.length,s=null==n;if("object"===Q.type(n)){i=!0;for(a in n)Q.access(t,e,a,n[a],!0,o,u)}else if(void 0!==r&&(i=!0,Q.isFunction(r)||(u=!0),s&&(u?(e.call(t,r),e=null):(s=e,e=function(t,e,n){return s.call(Q(t),n)})),e))for(;a<c;a++)e(t[a],n,u?r:r.call(t[a],a,e(t[a],n)));return i?t:s?e.call(t):c?e(t[0],n):o};Q.acceptData=function(t){return 1===t.nodeType||9===t.nodeType||!+t.nodeType},a.uid=1,a.accepts=Q.acceptData,a.prototype={key:function(t){if(!a.accepts(t))return 0;var e={},n=t[this.expando];if(!n){n=a.uid++;try{e[this.expando]={value:n},Object.defineProperties(t,e)}catch(r){e[this.expando]=n,Q.extend(t,e)}}return this.cache[n]||(this.cache[n]={}),n},set:function(t,e,n){var r,i=this.key(t),o=this.cache[i];if("string"==typeof e)o[e]=n;else if(Q.isEmptyObject(o))Q.extend(this.cache[i],e);else for(r in e)o[r]=e[r];return o},get:function(t,e){var n=this.cache[this.key(t)];return void 0===e?n:n[e]},access:function(t,e,n){var r;return void 0===e||e&&"string"==typeof e&&void 0===n?(r=this.get(t,e),void 0!==r?r:this.get(t,Q.camelCase(e))):(this.set(t,e,n),void 0!==n?n:e)},remove:function(t,e){var n,r,i,o=this.key(t),u=this.cache[o];if(void 0===e)this.cache[o]={};else{Q.isArray(e)?r=e.concat(e.map(Q.camelCase)):(i=Q.camelCase(e),e in u?r=[e,i]:(r=i,r=r in u?[r]:r.match(ht)||[])),n=r.length;for(;n--;)delete u[r[n]]}},hasData:function(t){return!Q.isEmptyObject(this.cache[t[this.expando]]||{})},discard:function(t){t[this.expando]&&delete this.cache[t[this.expando]]}};var mt=new a,yt=new a,bt=/^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,xt=/([A-Z])/g;Q.extend({hasData:function(t){return yt.hasData(t)||mt.hasData(t)},data:function(t,e,n){return yt.access(t,e,n)},removeData:function(t,e){yt.remove(t,e)},_data:function(t,e,n){return mt.access(t,e,n)},_removeData:function(t,e){mt.remove(t,e)}}),Q.fn.extend({data:function(t,e){var n,r,i,o=this[0],u=o&&o.attributes;if(void 0===t){if(this.length&&(i=yt.get(o),1===o.nodeType&&!mt.get(o,"hasDataAttrs"))){for(n=u.length;n--;)u[n]&&(r=u[n].name,0===r.indexOf("data-")&&(r=Q.camelCase(r.slice(5)),c(o,r,i[r])));mt.set(o,"hasDataAttrs",!0)}return i}return"object"==typeof t?this.each(function(){yt.set(this,t)}):vt(this,function(e){var n,r=Q.camelCase(t);if(o&&void 0===e){if(n=yt.get(o,t),void 0!==n)return n;if(n=yt.get(o,r),void 0!==n)return n;if(n=c(o,r,void 0),void 0!==n)return n}else this.each(function(){var n=yt.get(this,r);yt.set(this,r,e),t.indexOf("-")!==-1&&void 0!==n&&yt.set(this,t,e)})},null,e,arguments.length>1,null,!0)},removeData:function(t){return this.each(function(){yt.remove(this,t)})}}),Q.extend({queue:function(t,e,n){var r;if(t)return e=(e||"fx")+"queue",r=mt.get(t,e),n&&(!r||Q.isArray(n)?r=mt.access(t,e,Q.makeArray(n)):r.push(n)),r||[]},dequeue:function(t,e){e=e||"fx";var n=Q.queue(t,e),r=n.length,i=n.shift(),o=Q._queueHooks(t,e),u=function(){Q.dequeue(t,e)};"inprogress"===i&&(i=n.shift(),r--),i&&("fx"===e&&n.unshift("inprogress"),delete o.stop,i.call(t,u,o)),!r&&o&&o.empty.fire()},_queueHooks:function(t,e){var n=e+"queueHooks";return mt.get(t,n)||mt.access(t,n,{empty:Q.Callbacks("once memory").add(function(){mt.remove(t,[e+"queue",n])})})}}),Q.fn.extend({queue:function(t,e){var n=2;return"string"!=typeof t&&(e=t,t="fx",n--),arguments.length<n?Q.queue(this[0],t):void 0===e?this:this.each(function(){var n=Q.queue(this,t,e);Q._queueHooks(this,t),"fx"===t&&"inprogress"!==n[0]&&Q.dequeue(this,t)})},dequeue:function(t){return this.each(function(){Q.dequeue(this,t)})},clearQueue:function(t){return this.queue(t||"fx",[])},promise:function(t,e){var n,r=1,i=Q.Deferred(),o=this,u=this.length,a=function(){--r||i.resolveWith(o,[o])};for("string"!=typeof t&&(e=t,t=void 0),t=t||"fx";u--;)n=mt.get(o[u],t+"queueHooks"),n&&n.empty&&(r++,n.empty.add(a));return a(),i.promise(e)}});var _t=/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source,wt=["Top","Right","Bottom","Left"],Ct=function(t,e){return t=e||t,"none"===Q.css(t,"display")||!Q.contains(t.ownerDocument,t)},kt=/^(?:checkbox|radio)$/i;!function(){var t=G.createDocumentFragment(),e=t.appendChild(G.createElement("div")),n=G.createElement("input");n.setAttribute("type","radio"),n.setAttribute("checked","checked"),n.setAttribute("name","t"),e.appendChild(n),Y.checkClone=e.cloneNode(!0).cloneNode(!0).lastChild.checked,e.innerHTML="<textarea>x</textarea>",Y.noCloneChecked=!!e.cloneNode(!0).lastChild.defaultValue}();var Tt="undefined";Y.focusinBubbles="onfocusin"in t;var jt=/^key/,At=/^(?:mouse|pointer|contextmenu)|click/,Et=/^(?:focusinfocus|focusoutblur)$/,St=/^([^.]*)(?:\.(.+)|)$/;Q.event={global:{},add:function(t,e,n,r,i){var o,u,a,c,s,l,f,p,h,d,g,v=mt.get(t);if(v)for(n.handler&&(o=n,n=o.handler,i=o.selector),n.guid||(n.guid=Q.guid++),(c=v.events)||(c=v.events={}),(u=v.handle)||(u=v.handle=function(e){return typeof Q!==Tt&&Q.event.triggered!==e.type?Q.event.dispatch.apply(t,arguments):void 0}),e=(e||"").match(ht)||[""],s=e.length;s--;)a=St.exec(e[s])||[],h=g=a[1],d=(a[2]||"").split(".").sort(),h&&(f=Q.event.special[h]||{},h=(i?f.delegateType:f.bindType)||h,f=Q.event.special[h]||{},l=Q.extend({type:h,origType:g,data:r,handler:n,guid:n.guid,selector:i,needsContext:i&&Q.expr.match.needsContext.test(i),namespace:d.join(".")},o),(p=c[h])||(p=c[h]=[],p.delegateCount=0,f.setup&&f.setup.call(t,r,d,u)!==!1||t.addEventListener&&t.addEventListener(h,u,!1)),f.add&&(f.add.call(t,l),l.handler.guid||(l.handler.guid=n.guid)),i?p.splice(p.delegateCount++,0,l):p.push(l),Q.event.global[h]=!0)},remove:function(t,e,n,r,i){var o,u,a,c,s,l,f,p,h,d,g,v=mt.hasData(t)&&mt.get(t);if(v&&(c=v.events)){for(e=(e||"").match(ht)||[""],s=e.length;s--;)if(a=St.exec(e[s])||[],h=g=a[1],d=(a[2]||"").split(".").sort(),h){for(f=Q.event.special[h]||{},h=(r?f.delegateType:f.bindType)||h,p=c[h]||[],a=a[2]&&new RegExp("(^|\\.)"+d.join("\\.(?:.*\\.|)")+"(\\.|$)"),u=o=p.length;o--;)l=p[o],!i&&g!==l.origType||n&&n.guid!==l.guid||a&&!a.test(l.namespace)||r&&r!==l.selector&&("**"!==r||!l.selector)||(p.splice(o,1),l.selector&&p.delegateCount--,f.remove&&f.remove.call(t,l));u&&!p.length&&(f.teardown&&f.teardown.call(t,d,v.handle)!==!1||Q.removeEvent(t,h,v.handle),delete c[h])}else for(h in c)Q.event.remove(t,h+e[s],n,r,!0);Q.isEmptyObject(c)&&(delete v.handle,mt.remove(t,"events"))}},trigger:function(e,n,r,i){var o,u,a,c,s,l,f,p=[r||G],h=V.call(e,"type")?e.type:e,d=V.call(e,"namespace")?e.namespace.split("."):[];if(u=a=r=r||G,3!==r.nodeType&&8!==r.nodeType&&!Et.test(h+Q.event.triggered)&&(h.indexOf(".")>=0&&(d=h.split("."),h=d.shift(),d.sort()),s=h.indexOf(":")<0&&"on"+h,e=e[Q.expando]?e:new Q.Event(h,"object"==typeof e&&e),e.isTrigger=i?2:3,e.namespace=d.join("."),e.namespace_re=e.namespace?new RegExp("(^|\\.)"+d.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,e.result=void 0,e.target||(e.target=r),n=null==n?[e]:Q.makeArray(n,[e]),f=Q.event.special[h]||{},i||!f.trigger||f.trigger.apply(r,n)!==!1)){if(!i&&!f.noBubble&&!Q.isWindow(r)){for(c=f.delegateType||h,Et.test(c+h)||(u=u.parentNode);u;u=u.parentNode)p.push(u),a=u;a===(r.ownerDocument||G)&&p.push(a.defaultView||a.parentWindow||t)}for(o=0;(u=p[o++])&&!e.isPropagationStopped();)e.type=o>1?c:f.bindType||h,l=(mt.get(u,"events")||{})[e.type]&&mt.get(u,"handle"),l&&l.apply(u,n),l=s&&u[s],l&&l.apply&&Q.acceptData(u)&&(e.result=l.apply(u,n),e.result===!1&&e.preventDefault());return e.type=h,i||e.isDefaultPrevented()||f._default&&f._default.apply(p.pop(),n)!==!1||!Q.acceptData(r)||s&&Q.isFunction(r[h])&&!Q.isWindow(r)&&(a=r[s],a&&(r[s]=null),Q.event.triggered=h,r[h](),Q.event.triggered=void 0,a&&(r[s]=a)),e.result}},dispatch:function(t){t=Q.event.fix(t);var e,n,r,i,o,u=[],a=B.call(arguments),c=(mt.get(this,"events")||{})[t.type]||[],s=Q.event.special[t.type]||{};if(a[0]=t,t.delegateTarget=this,!s.preDispatch||s.preDispatch.call(this,t)!==!1){for(u=Q.event.handlers.call(this,t,c),e=0;(i=u[e++])&&!t.isPropagationStopped();)for(t.currentTarget=i.elem,n=0;(o=i.handlers[n++])&&!t.isImmediatePropagationStopped();)t.namespace_re&&!t.namespace_re.test(o.namespace)||(t.handleObj=o,t.data=o.data,r=((Q.event.special[o.origType]||{}).handle||o.handler).apply(i.elem,a),void 0!==r&&(t.result=r)===!1&&(t.preventDefault(),t.stopPropagation()));return s.postDispatch&&s.postDispatch.call(this,t),t.result}},handlers:function(t,e){var n,r,i,o,u=[],a=e.delegateCount,c=t.target;if(a&&c.nodeType&&(!t.button||"click"!==t.type))for(;c!==this;c=c.parentNode||this)if(c.disabled!==!0||"click"!==t.type){for(r=[],n=0;n<a;n++)o=e[n],i=o.selector+" ",void 0===r[i]&&(r[i]=o.needsContext?Q(i,this).index(c)>=0:Q.find(i,this,null,[c]).length),r[i]&&r.push(o);r.length&&u.push({elem:c,handlers:r})}return a<e.length&&u.push({elem:this,handlers:e.slice(a)}),u},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(t,e){return null==t.which&&(t.which=null!=e.charCode?e.charCode:e.keyCode),t}},mouseHooks:{props:"button buttons clientX clientY offsetX offsetY pageX pageY screenX screenY toElement".split(" "),filter:function(t,e){var n,r,i,o=e.button;return null==t.pageX&&null!=e.clientX&&(n=t.target.ownerDocument||G,r=n.documentElement,i=n.body,t.pageX=e.clientX+(r&&r.scrollLeft||i&&i.scrollLeft||0)-(r&&r.clientLeft||i&&i.clientLeft||0),t.pageY=e.clientY+(r&&r.scrollTop||i&&i.scrollTop||0)-(r&&r.clientTop||i&&i.clientTop||0)),t.which||void 0===o||(t.which=1&o?1:2&o?3:4&o?2:0),t}},fix:function(t){if(t[Q.expando])return t;var e,n,r,i=t.type,o=t,u=this.fixHooks[i];for(u||(this.fixHooks[i]=u=At.test(i)?this.mouseHooks:jt.test(i)?this.keyHooks:{}),r=u.props?this.props.concat(u.props):this.props,t=new Q.Event(o),e=r.length;e--;)n=r[e],t[n]=o[n];return t.target||(t.target=G),3===t.target.nodeType&&(t.target=t.target.parentNode),u.filter?u.filter(t,o):t},special:{load:{noBubble:!0},focus:{trigger:function(){if(this!==f()&&this.focus)return this.focus(),!1},delegateType:"focusin"},blur:{trigger:function(){if(this===f()&&this.blur)return this.blur(),!1},delegateType:"focusout"},click:{trigger:function(){if("checkbox"===this.type&&this.click&&Q.nodeName(this,"input"))return this.click(),!1},_default:function(t){return Q.nodeName(t.target,"a")}},beforeunload:{postDispatch:function(t){void 0!==t.result&&t.originalEvent&&(t.originalEvent.returnValue=t.result)}}},simulate:function(t,e,n,r){var i=Q.extend(new Q.Event,n,{type:t,isSimulated:!0,originalEvent:{}});r?Q.event.trigger(i,null,e):Q.event.dispatch.call(e,i),i.isDefaultPrevented()&&n.preventDefault()}},Q.removeEvent=function(t,e,n){t.removeEventListener&&t.removeEventListener(e,n,!1)},Q.Event=function(t,e){return this instanceof Q.Event?(t&&t.type?(this.originalEvent=t,this.type=t.type,this.isDefaultPrevented=t.defaultPrevented||void 0===t.defaultPrevented&&t.returnValue===!1?s:l):this.type=t,e&&Q.extend(this,e),this.timeStamp=t&&t.timeStamp||Q.now(),void(this[Q.expando]=!0)):new Q.Event(t,e)},Q.Event.prototype={isDefaultPrevented:l,isPropagationStopped:l,isImmediatePropagationStopped:l,preventDefault:function(){var t=this.originalEvent;this.isDefaultPrevented=s,t&&t.preventDefault&&t.preventDefault()},stopPropagation:function(){var t=this.originalEvent;this.isPropagationStopped=s,t&&t.stopPropagation&&t.stopPropagation()},stopImmediatePropagation:function(){var t=this.originalEvent;this.isImmediatePropagationStopped=s,t&&t.stopImmediatePropagation&&t.stopImmediatePropagation(),this.stopPropagation()}},Q.each({mouseenter:"mouseover",mouseleave:"mouseout",pointerenter:"pointerover",pointerleave:"pointerout"},function(t,e){Q.event.special[t]={delegateType:e,bindType:e,handle:function(t){var n,r=this,i=t.relatedTarget,o=t.handleObj;return i&&(i===r||Q.contains(r,i))||(t.type=o.origType,n=o.handler.apply(this,arguments),t.type=e),n}}}),Y.focusinBubbles||Q.each({focus:"focusin",blur:"focusout"},function(t,e){var n=function(t){Q.event.simulate(e,t.target,Q.event.fix(t),!0)};Q.event.special[e]={setup:function(){var r=this.ownerDocument||this,i=mt.access(r,e);i||r.addEventListener(t,n,!0),mt.access(r,e,(i||0)+1)},teardown:function(){var r=this.ownerDocument||this,i=mt.access(r,e)-1;i?mt.access(r,e,i):(r.removeEventListener(t,n,!0),mt.remove(r,e))}}}),Q.fn.extend({on:function(t,e,n,r,i){var o,u;if("object"==typeof t){"string"!=typeof e&&(n=n||e,e=void 0);for(u in t)this.on(u,e,n,t[u],i);return this}if(null==n&&null==r?(r=e,n=e=void 0):null==r&&("string"==typeof e?(r=n,n=void 0):(r=n,n=e,e=void 0)),r===!1)r=l;else if(!r)return this;return 1===i&&(o=r,r=function(t){return Q().off(t),o.apply(this,arguments)},r.guid=o.guid||(o.guid=Q.guid++)),this.each(function(){Q.event.add(this,t,r,n,e)})},one:function(t,e,n,r){return this.on(t,e,n,r,1)},off:function(t,e,n){var r,i;if(t&&t.preventDefault&&t.handleObj)return r=t.handleObj,Q(t.delegateTarget).off(r.namespace?r.origType+"."+r.namespace:r.origType,r.selector,r.handler),this;if("object"==typeof t){for(i in t)this.off(i,e,t[i]);return this}return e!==!1&&"function"!=typeof e||(n=e,e=void 0),n===!1&&(n=l),this.each(function(){Q.event.remove(this,t,n,e)})},trigger:function(t,e){return this.each(function(){Q.event.trigger(t,e,this)})},triggerHandler:function(t,e){var n=this[0];if(n)return Q.event.trigger(t,e,n,!0)}});var Nt=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/gi,Dt=/<([\w:]+)/,Ot=/<|&#?\w+;/,Lt=/<(?:script|style|link)/i,Rt=/checked\s*(?:[^=]|=\s*.checked.)/i,qt=/^$|\/(?:java|ecma)script/i,Ht=/^true\/(.*)/,Pt=/^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g,It={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,"",""]};It.optgroup=It.option,It.tbody=It.tfoot=It.colgroup=It.caption=It.thead,It.th=It.td,Q.extend({clone:function(t,e,n){var r,i,o,u,a=t.cloneNode(!0),c=Q.contains(t.ownerDocument,t);if(!(Y.noCloneChecked||1!==t.nodeType&&11!==t.nodeType||Q.isXMLDoc(t)))for(u=m(a),o=m(t),r=0,i=o.length;r<i;r++)y(o[r],u[r]);if(e)if(n)for(o=o||m(t),u=u||m(a),r=0,i=o.length;r<i;r++)v(o[r],u[r]);else v(t,a);return u=m(a,"script"),u.length>0&&g(u,!c&&m(t,"script")),a},buildFragment:function(t,e,n,r){for(var i,o,u,a,c,s,l=e.createDocumentFragment(),f=[],p=0,h=t.length;p<h;p++)if(i=t[p],i||0===i)if("object"===Q.type(i))Q.merge(f,i.nodeType?[i]:i);else if(Ot.test(i)){for(o=o||l.appendChild(e.createElement("div")),u=(Dt.exec(i)||["",""])[1].toLowerCase(),a=It[u]||It._default,o.innerHTML=a[1]+i.replace(Nt,"<$1></$2>")+a[2],s=a[0];s--;)o=o.lastChild;Q.merge(f,o.childNodes),o=l.firstChild,o.textContent=""}else f.push(e.createTextNode(i));for(l.textContent="",p=0;i=f[p++];)if((!r||Q.inArray(i,r)===-1)&&(c=Q.contains(i.ownerDocument,i),o=m(l.appendChild(i),"script"),c&&g(o),n))for(s=0;i=o[s++];)qt.test(i.type||"")&&n.push(i);return l},cleanData:function(t){for(var e,n,r,i,o=Q.event.special,u=0;void 0!==(n=t[u]);u++){if(Q.acceptData(n)&&(i=n[mt.expando],i&&(e=mt.cache[i]))){if(e.events)for(r in e.events)o[r]?Q.event.remove(n,r):Q.removeEvent(n,r,e.handle);mt.cache[i]&&delete mt.cache[i]}delete yt.cache[n[yt.expando]]}}}),Q.fn.extend({text:function(t){return vt(this,function(t){return void 0===t?Q.text(this):this.empty().each(function(){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||(this.textContent=t)})},null,t,arguments.length)},append:function(){return this.domManip(arguments,function(t){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var e=p(this,t);e.appendChild(t)}})},prepend:function(){return this.domManip(arguments,function(t){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var e=p(this,t);e.insertBefore(t,e.firstChild)}})},before:function(){return this.domManip(arguments,function(t){this.parentNode&&this.parentNode.insertBefore(t,this)})},after:function(){return this.domManip(arguments,function(t){this.parentNode&&this.parentNode.insertBefore(t,this.nextSibling)})},remove:function(t,e){for(var n,r=t?Q.filter(t,this):this,i=0;null!=(n=r[i]);i++)e||1!==n.nodeType||Q.cleanData(m(n)),n.parentNode&&(e&&Q.contains(n.ownerDocument,n)&&g(m(n,"script")),n.parentNode.removeChild(n));return this},empty:function(){for(var t,e=0;null!=(t=this[e]);e++)1===t.nodeType&&(Q.cleanData(m(t,!1)),t.textContent="");return this},clone:function(t,e){return t=null!=t&&t,e=null==e?t:e,this.map(function(){return Q.clone(this,t,e)})},html:function(t){return vt(this,function(t){var e=this[0]||{},n=0,r=this.length;if(void 0===t&&1===e.nodeType)return e.innerHTML;if("string"==typeof t&&!Lt.test(t)&&!It[(Dt.exec(t)||["",""])[1].toLowerCase()]){t=t.replace(Nt,"<$1></$2>");try{for(;n<r;n++)e=this[n]||{},1===e.nodeType&&(Q.cleanData(m(e,!1)),e.innerHTML=t);e=0}catch(i){}}e&&this.empty().append(t)},null,t,arguments.length)},replaceWith:function(){var t=arguments[0];return this.domManip(arguments,function(e){t=this.parentNode,Q.cleanData(m(this)),t&&t.replaceChild(e,this)}),t&&(t.length||t.nodeType)?this:this.remove()},detach:function(t){return this.remove(t,!0)},domManip:function(t,e){t=z.apply([],t);var n,r,i,o,u,a,c=0,s=this.length,l=this,f=s-1,p=t[0],g=Q.isFunction(p);if(g||s>1&&"string"==typeof p&&!Y.checkClone&&Rt.test(p))return this.each(function(n){var r=l.eq(n);g&&(t[0]=p.call(this,n,r.html())),r.domManip(t,e)});if(s&&(n=Q.buildFragment(t,this[0].ownerDocument,!1,this),r=n.firstChild,1===n.childNodes.length&&(n=r),r)){for(i=Q.map(m(n,"script"),h),o=i.length;c<s;c++)u=n,c!==f&&(u=Q.clone(u,!0,!0),o&&Q.merge(i,m(u,"script"))),e.call(this[c],u,c);if(o)for(a=i[i.length-1].ownerDocument,Q.map(i,d),c=0;c<o;c++)u=i[c],qt.test(u.type||"")&&!mt.access(u,"globalEval")&&Q.contains(a,u)&&(u.src?Q._evalUrl&&Q._evalUrl(u.src):Q.globalEval(u.textContent.replace(Pt,"")))}return this}}),Q.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(t,e){Q.fn[t]=function(t){for(var n,r=[],i=Q(t),o=i.length-1,u=0;u<=o;u++)n=u===o?this:this.clone(!0),Q(i[u])[e](n),J.apply(r,n.get());return this.pushStack(r)}});var Wt,Ft={},Mt=/^margin/,$t=new RegExp("^("+_t+")(?!px)[a-z%]+$","i"),Bt=function(e){return e.ownerDocument.defaultView.opener?e.ownerDocument.defaultView.getComputedStyle(e,null):t.getComputedStyle(e,null)};!function(){function e(){u.style.cssText="-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;display:block;margin-top:1%;top:1%;border:1px;padding:1px;width:4px;position:absolute",u.innerHTML="",i.appendChild(o);var e=t.getComputedStyle(u,null);n="1%"!==e.top,r="4px"===e.width,i.removeChild(o)}var n,r,i=G.documentElement,o=G.createElement("div"),u=G.createElement("div");u.style&&(u.style.backgroundClip="content-box",u.cloneNode(!0).style.backgroundClip="",Y.clearCloneStyle="content-box"===u.style.backgroundClip,o.style.cssText="border:0;width:0;height:0;top:0;left:-9999px;margin-top:1px;position:absolute",o.appendChild(u),t.getComputedStyle&&Q.extend(Y,{pixelPosition:function(){return e(),n},boxSizingReliable:function(){return null==r&&e(),r},reliableMarginRight:function(){var e,n=u.appendChild(G.createElement("div"));return n.style.cssText=u.style.cssText="-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box;display:block;margin:0;border:0;padding:0",n.style.marginRight=n.style.width="0",u.style.width="1px",i.appendChild(o),e=!parseFloat(t.getComputedStyle(n,null).marginRight),i.removeChild(o),u.removeChild(n),e}}))}(),Q.swap=function(t,e,n,r){var i,o,u={};for(o in e)u[o]=t.style[o],t.style[o]=e[o];i=n.apply(t,r||[]);for(o in e)t.style[o]=u[o];return i};var zt=/^(none|table(?!-c[ea]).+)/,Jt=new RegExp("^("+_t+")(.*)$","i"),Ut=new RegExp("^([+-])=("+_t+")","i"),Kt={position:"absolute",visibility:"hidden",display:"block"},Xt={letterSpacing:"0",fontWeight:"400"},Vt=["Webkit","O","Moz","ms"];Q.extend({cssHooks:{opacity:{get:function(t,e){if(e){var n=_(t,"opacity");return""===n?"1":n}}}},cssNumber:{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(t,e,n,r){if(t&&3!==t.nodeType&&8!==t.nodeType&&t.style){var i,o,u,a=Q.camelCase(e),c=t.style;return e=Q.cssProps[a]||(Q.cssProps[a]=C(c,a)),u=Q.cssHooks[e]||Q.cssHooks[a],void 0===n?u&&"get"in u&&void 0!==(i=u.get(t,!1,r))?i:c[e]:(o=typeof n,"string"===o&&(i=Ut.exec(n))&&(n=(i[1]+1)*i[2]+parseFloat(Q.css(t,e)),o="number"),null!=n&&n===n&&("number"!==o||Q.cssNumber[a]||(n+="px"),Y.clearCloneStyle||""!==n||0!==e.indexOf("background")||(c[e]="inherit"),u&&"set"in u&&void 0===(n=u.set(t,n,r))||(c[e]=n)),void 0)}},css:function(t,e,n,r){var i,o,u,a=Q.camelCase(e);return e=Q.cssProps[a]||(Q.cssProps[a]=C(t.style,a)),u=Q.cssHooks[e]||Q.cssHooks[a],u&&"get"in u&&(i=u.get(t,!0,n)),void 0===i&&(i=_(t,e,r)),"normal"===i&&e in Xt&&(i=Xt[e]),""===n||n?(o=parseFloat(i),n===!0||Q.isNumeric(o)?o||0:i):i}}),Q.each(["height","width"],function(t,e){Q.cssHooks[e]={get:function(t,n,r){if(n)return zt.test(Q.css(t,"display"))&&0===t.offsetWidth?Q.swap(t,Kt,function(){return j(t,e,r)}):j(t,e,r)},set:function(t,n,r){var i=r&&Bt(t);return k(t,n,r?T(t,e,r,"border-box"===Q.css(t,"boxSizing",!1,i),i):0)}}}),Q.cssHooks.marginRight=w(Y.reliableMarginRight,function(t,e){if(e)return Q.swap(t,{display:"inline-block"},_,[t,"marginRight"])}),Q.each({margin:"",padding:"",border:"Width"},function(t,e){Q.cssHooks[t+e]={expand:function(n){for(var r=0,i={},o="string"==typeof n?n.split(" "):[n];r<4;r++)i[t+wt[r]+e]=o[r]||o[r-2]||o[0];return i}},Mt.test(t)||(Q.cssHooks[t+e].set=k)}),Q.fn.extend({css:function(t,e){return vt(this,function(t,e,n){var r,i,o={},u=0;if(Q.isArray(e)){for(r=Bt(t),i=e.length;u<i;u++)o[e[u]]=Q.css(t,e[u],!1,r);return o}return void 0!==n?Q.style(t,e,n):Q.css(t,e)},t,e,arguments.length>1)},show:function(){return A(this,!0)},hide:function(){return A(this)},toggle:function(t){return"boolean"==typeof t?t?this.show():this.hide():this.each(function(){Ct(this)?Q(this).show():Q(this).hide()})}}),Q.Tween=E,E.prototype={constructor:E,init:function(t,e,n,r,i,o){this.elem=t,this.prop=n,this.easing=i||"swing",this.options=e,this.start=this.now=this.cur(),this.end=r,this.unit=o||(Q.cssNumber[n]?"":"px")},cur:function(){var t=E.propHooks[this.prop];return t&&t.get?t.get(this):E.propHooks._default.get(this)},run:function(t){var e,n=E.propHooks[this.prop];return this.options.duration?this.pos=e=Q.easing[this.easing](t,this.options.duration*t,0,1,this.options.duration):this.pos=e=t,this.now=(this.end-this.start)*e+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),n&&n.set?n.set(this):E.propHooks._default.set(this),this}},E.prototype.init.prototype=E.prototype,E.propHooks={_default:{get:function(t){var e;return null==t.elem[t.prop]||t.elem.style&&null!=t.elem.style[t.prop]?(e=Q.css(t.elem,t.prop,""),e&&"auto"!==e?e:0):t.elem[t.prop]},set:function(t){Q.fx.step[t.prop]?Q.fx.step[t.prop](t):t.elem.style&&(null!=t.elem.style[Q.cssProps[t.prop]]||Q.cssHooks[t.prop])?Q.style(t.elem,t.prop,t.now+t.unit):t.elem[t.prop]=t.now}}},E.propHooks.scrollTop=E.propHooks.scrollLeft={set:function(t){t.elem.nodeType&&t.elem.parentNode&&(t.elem[t.prop]=t.now)}},Q.easing={linear:function(t){return t},swing:function(t){return.5-Math.cos(t*Math.PI)/2}},Q.fx=E.prototype.init,Q.fx.step={};var Yt,Gt,Zt=/^(?:toggle|show|hide)$/,Qt=new RegExp("^(?:([+-])=|)("+_t+")([a-z%]*)$","i"),te=/queueHooks$/,ee=[O],ne={"*":[function(t,e){var n=this.createTween(t,e),r=n.cur(),i=Qt.exec(e),o=i&&i[3]||(Q.cssNumber[t]?"":"px"),u=(Q.cssNumber[t]||"px"!==o&&+r)&&Qt.exec(Q.css(n.elem,t)),a=1,c=20;if(u&&u[3]!==o){o=o||u[3],i=i||[],u=+r||1;do a=a||".5",u/=a,Q.style(n.elem,t,u+o);while(a!==(a=n.cur()/r)&&1!==a&&--c)}return i&&(u=n.start=+u||+r||0,n.unit=o,n.end=i[1]?u+(i[1]+1)*i[2]:+i[2]),n}]};Q.Animation=Q.extend(R,{tweener:function(t,e){Q.isFunction(t)?(e=t,t=["*"]):t=t.split(" ");for(var n,r=0,i=t.length;r<i;r++)n=t[r],ne[n]=ne[n]||[],ne[n].unshift(e)},prefilter:function(t,e){e?ee.unshift(t):ee.push(t)}}),Q.speed=function(t,e,n){var r=t&&"object"==typeof t?Q.extend({},t):{complete:n||!n&&e||Q.isFunction(t)&&t,duration:t,easing:n&&e||e&&!Q.isFunction(e)&&e};return r.duration=Q.fx.off?0:"number"==typeof r.duration?r.duration:r.duration in Q.fx.speeds?Q.fx.speeds[r.duration]:Q.fx.speeds._default,null!=r.queue&&r.queue!==!0||(r.queue="fx"),r.old=r.complete,r.complete=function(){Q.isFunction(r.old)&&r.old.call(this),r.queue&&Q.dequeue(this,r.queue)},r},Q.fn.extend({fadeTo:function(t,e,n,r){return this.filter(Ct).css("opacity",0).show().end().animate({opacity:e},t,n,r)},animate:function(t,e,n,r){var i=Q.isEmptyObject(t),o=Q.speed(e,n,r),u=function(){var e=R(this,Q.extend({},t),o);(i||mt.get(this,"finish"))&&e.stop(!0)};return u.finish=u,i||o.queue===!1?this.each(u):this.queue(o.queue,u)},stop:function(t,e,n){var r=function(t){var e=t.stop;delete t.stop,e(n)};return"string"!=typeof t&&(n=e,e=t,t=void 0),e&&t!==!1&&this.queue(t||"fx",[]),this.each(function(){var e=!0,i=null!=t&&t+"queueHooks",o=Q.timers,u=mt.get(this);if(i)u[i]&&u[i].stop&&r(u[i]);else for(i in u)u[i]&&u[i].stop&&te.test(i)&&r(u[i]);for(i=o.length;i--;)o[i].elem!==this||null!=t&&o[i].queue!==t||(o[i].anim.stop(n),e=!1,o.splice(i,1));!e&&n||Q.dequeue(this,t)})},finish:function(t){return t!==!1&&(t=t||"fx"),this.each(function(){var e,n=mt.get(this),r=n[t+"queue"],i=n[t+"queueHooks"],o=Q.timers,u=r?r.length:0;for(n.finish=!0,Q.queue(this,t,[]),i&&i.stop&&i.stop.call(this,!0),e=o.length;e--;)o[e].elem===this&&o[e].queue===t&&(o[e].anim.stop(!0),o.splice(e,1));
+for(e=0;e<u;e++)r[e]&&r[e].finish&&r[e].finish.call(this);delete n.finish})}}),Q.each(["toggle","show","hide"],function(t,e){var n=Q.fn[e];Q.fn[e]=function(t,r,i){return null==t||"boolean"==typeof t?n.apply(this,arguments):this.animate(N(e,!0),t,r,i)}}),Q.each({slideDown:N("show"),slideUp:N("hide"),slideToggle:N("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(t,e){Q.fn[t]=function(t,n,r){return this.animate(e,t,n,r)}}),Q.timers=[],Q.fx.tick=function(){var t,e=0,n=Q.timers;for(Yt=Q.now();e<n.length;e++)t=n[e],t()||n[e]!==t||n.splice(e--,1);n.length||Q.fx.stop(),Yt=void 0},Q.fx.timer=function(t){Q.timers.push(t),t()?Q.fx.start():Q.timers.pop()},Q.fx.interval=13,Q.fx.start=function(){Gt||(Gt=setInterval(Q.fx.tick,Q.fx.interval))},Q.fx.stop=function(){clearInterval(Gt),Gt=null},Q.fx.speeds={slow:600,fast:200,_default:400},Q.fn.delay=function(t,e){return t=Q.fx?Q.fx.speeds[t]||t:t,e=e||"fx",this.queue(e,function(e,n){var r=setTimeout(e,t);n.stop=function(){clearTimeout(r)}})},function(){var t=G.createElement("input"),e=G.createElement("select"),n=e.appendChild(G.createElement("option"));t.type="checkbox",Y.checkOn=""!==t.value,Y.optSelected=n.selected,e.disabled=!0,Y.optDisabled=!n.disabled,t=G.createElement("input"),t.value="t",t.type="radio",Y.radioValue="t"===t.value}();var re,ie,oe=Q.expr.attrHandle;Q.fn.extend({attr:function(t,e){return vt(this,Q.attr,t,e,arguments.length>1)},removeAttr:function(t){return this.each(function(){Q.removeAttr(this,t)})}}),Q.extend({attr:function(t,e,n){var r,i,o=t.nodeType;if(t&&3!==o&&8!==o&&2!==o)return typeof t.getAttribute===Tt?Q.prop(t,e,n):(1===o&&Q.isXMLDoc(t)||(e=e.toLowerCase(),r=Q.attrHooks[e]||(Q.expr.match.bool.test(e)?ie:re)),void 0===n?r&&"get"in r&&null!==(i=r.get(t,e))?i:(i=Q.find.attr(t,e),null==i?void 0:i):null!==n?r&&"set"in r&&void 0!==(i=r.set(t,n,e))?i:(t.setAttribute(e,n+""),n):void Q.removeAttr(t,e))},removeAttr:function(t,e){var n,r,i=0,o=e&&e.match(ht);if(o&&1===t.nodeType)for(;n=o[i++];)r=Q.propFix[n]||n,Q.expr.match.bool.test(n)&&(t[r]=!1),t.removeAttribute(n)},attrHooks:{type:{set:function(t,e){if(!Y.radioValue&&"radio"===e&&Q.nodeName(t,"input")){var n=t.value;return t.setAttribute("type",e),n&&(t.value=n),e}}}}}),ie={set:function(t,e,n){return e===!1?Q.removeAttr(t,n):t.setAttribute(n,n),n}},Q.each(Q.expr.match.bool.source.match(/\w+/g),function(t,e){var n=oe[e]||Q.find.attr;oe[e]=function(t,e,r){var i,o;return r||(o=oe[e],oe[e]=i,i=null!=n(t,e,r)?e.toLowerCase():null,oe[e]=o),i}});var ue=/^(?:input|select|textarea|button)$/i;Q.fn.extend({prop:function(t,e){return vt(this,Q.prop,t,e,arguments.length>1)},removeProp:function(t){return this.each(function(){delete this[Q.propFix[t]||t]})}}),Q.extend({propFix:{"for":"htmlFor","class":"className"},prop:function(t,e,n){var r,i,o,u=t.nodeType;if(t&&3!==u&&8!==u&&2!==u)return o=1!==u||!Q.isXMLDoc(t),o&&(e=Q.propFix[e]||e,i=Q.propHooks[e]),void 0!==n?i&&"set"in i&&void 0!==(r=i.set(t,n,e))?r:t[e]=n:i&&"get"in i&&null!==(r=i.get(t,e))?r:t[e]},propHooks:{tabIndex:{get:function(t){return t.hasAttribute("tabindex")||ue.test(t.nodeName)||t.href?t.tabIndex:-1}}}}),Y.optSelected||(Q.propHooks.selected={get:function(t){var e=t.parentNode;return e&&e.parentNode&&e.parentNode.selectedIndex,null}}),Q.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],function(){Q.propFix[this.toLowerCase()]=this});var ae=/[\t\r\n\f]/g;Q.fn.extend({addClass:function(t){var e,n,r,i,o,u,a="string"==typeof t&&t,c=0,s=this.length;if(Q.isFunction(t))return this.each(function(e){Q(this).addClass(t.call(this,e,this.className))});if(a)for(e=(t||"").match(ht)||[];c<s;c++)if(n=this[c],r=1===n.nodeType&&(n.className?(" "+n.className+" ").replace(ae," "):" ")){for(o=0;i=e[o++];)r.indexOf(" "+i+" ")<0&&(r+=i+" ");u=Q.trim(r),n.className!==u&&(n.className=u)}return this},removeClass:function(t){var e,n,r,i,o,u,a=0===arguments.length||"string"==typeof t&&t,c=0,s=this.length;if(Q.isFunction(t))return this.each(function(e){Q(this).removeClass(t.call(this,e,this.className))});if(a)for(e=(t||"").match(ht)||[];c<s;c++)if(n=this[c],r=1===n.nodeType&&(n.className?(" "+n.className+" ").replace(ae," "):"")){for(o=0;i=e[o++];)for(;r.indexOf(" "+i+" ")>=0;)r=r.replace(" "+i+" "," ");u=t?Q.trim(r):"",n.className!==u&&(n.className=u)}return this},toggleClass:function(t,e){var n=typeof t;return"boolean"==typeof e&&"string"===n?e?this.addClass(t):this.removeClass(t):Q.isFunction(t)?this.each(function(n){Q(this).toggleClass(t.call(this,n,this.className,e),e)}):this.each(function(){if("string"===n)for(var e,r=0,i=Q(this),o=t.match(ht)||[];e=o[r++];)i.hasClass(e)?i.removeClass(e):i.addClass(e);else n!==Tt&&"boolean"!==n||(this.className&&mt.set(this,"__className__",this.className),this.className=this.className||t===!1?"":mt.get(this,"__className__")||"")})},hasClass:function(t){for(var e=" "+t+" ",n=0,r=this.length;n<r;n++)if(1===this[n].nodeType&&(" "+this[n].className+" ").replace(ae," ").indexOf(e)>=0)return!0;return!1}});var ce=/\r/g;Q.fn.extend({val:function(t){var e,n,r,i=this[0];{if(arguments.length)return r=Q.isFunction(t),this.each(function(n){var i;1===this.nodeType&&(i=r?t.call(this,n,Q(this).val()):t,null==i?i="":"number"==typeof i?i+="":Q.isArray(i)&&(i=Q.map(i,function(t){return null==t?"":t+""})),e=Q.valHooks[this.type]||Q.valHooks[this.nodeName.toLowerCase()],e&&"set"in e&&void 0!==e.set(this,i,"value")||(this.value=i))});if(i)return e=Q.valHooks[i.type]||Q.valHooks[i.nodeName.toLowerCase()],e&&"get"in e&&void 0!==(n=e.get(i,"value"))?n:(n=i.value,"string"==typeof n?n.replace(ce,""):null==n?"":n)}}}),Q.extend({valHooks:{option:{get:function(t){var e=Q.find.attr(t,"value");return null!=e?e:Q.trim(Q.text(t))}},select:{get:function(t){for(var e,n,r=t.options,i=t.selectedIndex,o="select-one"===t.type||i<0,u=o?null:[],a=o?i+1:r.length,c=i<0?a:o?i:0;c<a;c++)if(n=r[c],(n.selected||c===i)&&(Y.optDisabled?!n.disabled:null===n.getAttribute("disabled"))&&(!n.parentNode.disabled||!Q.nodeName(n.parentNode,"optgroup"))){if(e=Q(n).val(),o)return e;u.push(e)}return u},set:function(t,e){for(var n,r,i=t.options,o=Q.makeArray(e),u=i.length;u--;)r=i[u],(r.selected=Q.inArray(r.value,o)>=0)&&(n=!0);return n||(t.selectedIndex=-1),o}}}}),Q.each(["radio","checkbox"],function(){Q.valHooks[this]={set:function(t,e){if(Q.isArray(e))return t.checked=Q.inArray(Q(t).val(),e)>=0}},Y.checkOn||(Q.valHooks[this].get=function(t){return null===t.getAttribute("value")?"on":t.value})}),Q.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(t,e){Q.fn[e]=function(t,n){return arguments.length>0?this.on(e,null,t,n):this.trigger(e)}}),Q.fn.extend({hover:function(t,e){return this.mouseenter(t).mouseleave(e||t)},bind:function(t,e,n){return this.on(t,null,e,n)},unbind:function(t,e){return this.off(t,null,e)},delegate:function(t,e,n,r){return this.on(e,t,n,r)},undelegate:function(t,e,n){return 1===arguments.length?this.off(t,"**"):this.off(e,t||"**",n)}});var se=Q.now(),le=/\?/;Q.parseJSON=function(t){return JSON.parse(t+"")},Q.parseXML=function(t){var e,n;if(!t||"string"!=typeof t)return null;try{n=new DOMParser,e=n.parseFromString(t,"text/xml")}catch(r){e=void 0}return e&&!e.getElementsByTagName("parsererror").length||Q.error("Invalid XML: "+t),e};var fe=/#.*$/,pe=/([?&])_=[^&]*/,he=/^(.*?):[ \t]*([^\r\n]*)$/gm,de=/^(?:about|app|app-storage|.+-extension|file|res|widget):$/,ge=/^(?:GET|HEAD)$/,ve=/^\/\//,me=/^([\w.+-]+:)(?:\/\/(?:[^\/?#]*@|)([^\/?#:]*)(?::(\d+)|)|)/,ye={},be={},xe="*/".concat("*"),_e=t.location.href,we=me.exec(_e.toLowerCase())||[];Q.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:_e,type:"GET",isLocal:de.test(we[1]),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":xe,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":Q.parseJSON,"text xml":Q.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(t,e){return e?P(P(t,Q.ajaxSettings),e):P(Q.ajaxSettings,t)},ajaxPrefilter:q(ye),ajaxTransport:q(be),ajax:function(t,e){function n(t,e,n,u){var c,l,m,y,x,w=e;2!==b&&(b=2,a&&clearTimeout(a),r=void 0,o=u||"",_.readyState=t>0?4:0,c=t>=200&&t<300||304===t,n&&(y=I(f,_,n)),y=W(f,y,_,c),c?(f.ifModified&&(x=_.getResponseHeader("Last-Modified"),x&&(Q.lastModified[i]=x),x=_.getResponseHeader("etag"),x&&(Q.etag[i]=x)),204===t||"HEAD"===f.type?w="nocontent":304===t?w="notmodified":(w=y.state,l=y.data,m=y.error,c=!m)):(m=w,!t&&w||(w="error",t<0&&(t=0))),_.status=t,_.statusText=(e||w)+"",c?d.resolveWith(p,[l,w,_]):d.rejectWith(p,[_,w,m]),_.statusCode(v),v=void 0,s&&h.trigger(c?"ajaxSuccess":"ajaxError",[_,f,c?l:m]),g.fireWith(p,[_,w]),s&&(h.trigger("ajaxComplete",[_,f]),--Q.active||Q.event.trigger("ajaxStop")))}"object"==typeof t&&(e=t,t=void 0),e=e||{};var r,i,o,u,a,c,s,l,f=Q.ajaxSetup({},e),p=f.context||f,h=f.context&&(p.nodeType||p.jquery)?Q(p):Q.event,d=Q.Deferred(),g=Q.Callbacks("once memory"),v=f.statusCode||{},m={},y={},b=0,x="canceled",_={readyState:0,getResponseHeader:function(t){var e;if(2===b){if(!u)for(u={};e=he.exec(o);)u[e[1].toLowerCase()]=e[2];e=u[t.toLowerCase()]}return null==e?null:e},getAllResponseHeaders:function(){return 2===b?o:null},setRequestHeader:function(t,e){var n=t.toLowerCase();return b||(t=y[n]=y[n]||t,m[t]=e),this},overrideMimeType:function(t){return b||(f.mimeType=t),this},statusCode:function(t){var e;if(t)if(b<2)for(e in t)v[e]=[v[e],t[e]];else _.always(t[_.status]);return this},abort:function(t){var e=t||x;return r&&r.abort(e),n(0,e),this}};if(d.promise(_).complete=g.add,_.success=_.done,_.error=_.fail,f.url=((t||f.url||_e)+"").replace(fe,"").replace(ve,we[1]+"//"),f.type=e.method||e.type||f.method||f.type,f.dataTypes=Q.trim(f.dataType||"*").toLowerCase().match(ht)||[""],null==f.crossDomain&&(c=me.exec(f.url.toLowerCase()),f.crossDomain=!(!c||c[1]===we[1]&&c[2]===we[2]&&(c[3]||("http:"===c[1]?"80":"443"))===(we[3]||("http:"===we[1]?"80":"443")))),f.data&&f.processData&&"string"!=typeof f.data&&(f.data=Q.param(f.data,f.traditional)),H(ye,f,e,_),2===b)return _;s=Q.event&&f.global,s&&0===Q.active++&&Q.event.trigger("ajaxStart"),f.type=f.type.toUpperCase(),f.hasContent=!ge.test(f.type),i=f.url,f.hasContent||(f.data&&(i=f.url+=(le.test(i)?"&":"?")+f.data,delete f.data),f.cache===!1&&(f.url=pe.test(i)?i.replace(pe,"$1_="+se++):i+(le.test(i)?"&":"?")+"_="+se++)),f.ifModified&&(Q.lastModified[i]&&_.setRequestHeader("If-Modified-Since",Q.lastModified[i]),Q.etag[i]&&_.setRequestHeader("If-None-Match",Q.etag[i])),(f.data&&f.hasContent&&f.contentType!==!1||e.contentType)&&_.setRequestHeader("Content-Type",f.contentType),_.setRequestHeader("Accept",f.dataTypes[0]&&f.accepts[f.dataTypes[0]]?f.accepts[f.dataTypes[0]]+("*"!==f.dataTypes[0]?", "+xe+"; q=0.01":""):f.accepts["*"]);for(l in f.headers)_.setRequestHeader(l,f.headers[l]);if(f.beforeSend&&(f.beforeSend.call(p,_,f)===!1||2===b))return _.abort();x="abort";for(l in{success:1,error:1,complete:1})_[l](f[l]);if(r=H(be,f,e,_)){_.readyState=1,s&&h.trigger("ajaxSend",[_,f]),f.async&&f.timeout>0&&(a=setTimeout(function(){_.abort("timeout")},f.timeout));try{b=1,r.send(m,n)}catch(w){if(!(b<2))throw w;n(-1,w)}}else n(-1,"No Transport");return _},getJSON:function(t,e,n){return Q.get(t,e,n,"json")},getScript:function(t,e){return Q.get(t,void 0,e,"script")}}),Q.each(["get","post"],function(t,e){Q[e]=function(t,n,r,i){return Q.isFunction(n)&&(i=i||r,r=n,n=void 0),Q.ajax({url:t,type:e,dataType:i,data:n,success:r})}}),Q._evalUrl=function(t){return Q.ajax({url:t,type:"GET",dataType:"script",async:!1,global:!1,"throws":!0})},Q.fn.extend({wrapAll:function(t){var e;return Q.isFunction(t)?this.each(function(e){Q(this).wrapAll(t.call(this,e))}):(this[0]&&(e=Q(t,this[0].ownerDocument).eq(0).clone(!0),this[0].parentNode&&e.insertBefore(this[0]),e.map(function(){for(var t=this;t.firstElementChild;)t=t.firstElementChild;return t}).append(this)),this)},wrapInner:function(t){return Q.isFunction(t)?this.each(function(e){Q(this).wrapInner(t.call(this,e))}):this.each(function(){var e=Q(this),n=e.contents();n.length?n.wrapAll(t):e.append(t)})},wrap:function(t){var e=Q.isFunction(t);return this.each(function(n){Q(this).wrapAll(e?t.call(this,n):t)})},unwrap:function(){return this.parent().each(function(){Q.nodeName(this,"body")||Q(this).replaceWith(this.childNodes)}).end()}}),Q.expr.filters.hidden=function(t){return t.offsetWidth<=0&&t.offsetHeight<=0},Q.expr.filters.visible=function(t){return!Q.expr.filters.hidden(t)};var Ce=/%20/g,ke=/\[\]$/,Te=/\r?\n/g,je=/^(?:submit|button|image|reset|file)$/i,Ae=/^(?:input|select|textarea|keygen)/i;Q.param=function(t,e){var n,r=[],i=function(t,e){e=Q.isFunction(e)?e():null==e?"":e,r[r.length]=encodeURIComponent(t)+"="+encodeURIComponent(e)};if(void 0===e&&(e=Q.ajaxSettings&&Q.ajaxSettings.traditional),Q.isArray(t)||t.jquery&&!Q.isPlainObject(t))Q.each(t,function(){i(this.name,this.value)});else for(n in t)F(n,t[n],e,i);return r.join("&").replace(Ce,"+")},Q.fn.extend({serialize:function(){return Q.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var t=Q.prop(this,"elements");return t?Q.makeArray(t):this}).filter(function(){var t=this.type;return this.name&&!Q(this).is(":disabled")&&Ae.test(this.nodeName)&&!je.test(t)&&(this.checked||!kt.test(t))}).map(function(t,e){var n=Q(this).val();return null==n?null:Q.isArray(n)?Q.map(n,function(t){return{name:e.name,value:t.replace(Te,"\r\n")}}):{name:e.name,value:n.replace(Te,"\r\n")}}).get()}}),Q.ajaxSettings.xhr=function(){try{return new XMLHttpRequest}catch(t){}};var Ee=0,Se={},Ne={0:200,1223:204},De=Q.ajaxSettings.xhr();t.attachEvent&&t.attachEvent("onunload",function(){for(var t in Se)Se[t]()}),Y.cors=!!De&&"withCredentials"in De,Y.ajax=De=!!De,Q.ajaxTransport(function(t){var e;if(Y.cors||De&&!t.crossDomain)return{send:function(n,r){var i,o=t.xhr(),u=++Ee;if(o.open(t.type,t.url,t.async,t.username,t.password),t.xhrFields)for(i in t.xhrFields)o[i]=t.xhrFields[i];t.mimeType&&o.overrideMimeType&&o.overrideMimeType(t.mimeType),t.crossDomain||n["X-Requested-With"]||(n["X-Requested-With"]="XMLHttpRequest");for(i in n)o.setRequestHeader(i,n[i]);e=function(t){return function(){e&&(delete Se[u],e=o.onload=o.onerror=null,"abort"===t?o.abort():"error"===t?r(o.status,o.statusText):r(Ne[o.status]||o.status,o.statusText,"string"==typeof o.responseText?{text:o.responseText}:void 0,o.getAllResponseHeaders()))}},o.onload=e(),o.onerror=e("error"),e=Se[u]=e("abort");try{o.send(t.hasContent&&t.data||null)}catch(a){if(e)throw a}},abort:function(){e&&e()}}}),Q.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/(?:java|ecma)script/},converters:{"text script":function(t){return Q.globalEval(t),t}}}),Q.ajaxPrefilter("script",function(t){void 0===t.cache&&(t.cache=!1),t.crossDomain&&(t.type="GET")}),Q.ajaxTransport("script",function(t){if(t.crossDomain){var e,n;return{send:function(r,i){e=Q("<script>").prop({async:!0,charset:t.scriptCharset,src:t.url}).on("load error",n=function(t){e.remove(),n=null,t&&i("error"===t.type?404:200,t.type)}),G.head.appendChild(e[0])},abort:function(){n&&n()}}}});var Oe=[],Le=/(=)\?(?=&|$)|\?\?/;Q.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var t=Oe.pop()||Q.expando+"_"+se++;return this[t]=!0,t}}),Q.ajaxPrefilter("json jsonp",function(e,n,r){var i,o,u,a=e.jsonp!==!1&&(Le.test(e.url)?"url":"string"==typeof e.data&&!(e.contentType||"").indexOf("application/x-www-form-urlencoded")&&Le.test(e.data)&&"data");if(a||"jsonp"===e.dataTypes[0])return i=e.jsonpCallback=Q.isFunction(e.jsonpCallback)?e.jsonpCallback():e.jsonpCallback,a?e[a]=e[a].replace(Le,"$1"+i):e.jsonp!==!1&&(e.url+=(le.test(e.url)?"&":"?")+e.jsonp+"="+i),e.converters["script json"]=function(){return u||Q.error(i+" was not called"),u[0]},e.dataTypes[0]="json",o=t[i],t[i]=function(){u=arguments},r.always(function(){t[i]=o,e[i]&&(e.jsonpCallback=n.jsonpCallback,Oe.push(i)),u&&Q.isFunction(o)&&o(u[0]),u=o=void 0}),"script"}),Q.parseHTML=function(t,e,n){if(!t||"string"!=typeof t)return null;"boolean"==typeof e&&(n=e,e=!1),e=e||G;var r=ut.exec(t),i=!n&&[];return r?[e.createElement(r[1])]:(r=Q.buildFragment([t],e,i),i&&i.length&&Q(i).remove(),Q.merge([],r.childNodes))};var Re=Q.fn.load;Q.fn.load=function(t,e,n){if("string"!=typeof t&&Re)return Re.apply(this,arguments);var r,i,o,u=this,a=t.indexOf(" ");return a>=0&&(r=Q.trim(t.slice(a)),t=t.slice(0,a)),Q.isFunction(e)?(n=e,e=void 0):e&&"object"==typeof e&&(i="POST"),u.length>0&&Q.ajax({url:t,type:i,dataType:"html",data:e}).done(function(t){o=arguments,u.html(r?Q("<div>").append(Q.parseHTML(t)).find(r):t)}).complete(n&&function(t,e){u.each(n,o||[t.responseText,e,t])}),this},Q.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(t,e){Q.fn[e]=function(t){return this.on(e,t)}}),Q.expr.filters.animated=function(t){return Q.grep(Q.timers,function(e){return t===e.elem}).length};var qe=t.document.documentElement;Q.offset={setOffset:function(t,e,n){var r,i,o,u,a,c,s,l=Q.css(t,"position"),f=Q(t),p={};"static"===l&&(t.style.position="relative"),a=f.offset(),o=Q.css(t,"top"),c=Q.css(t,"left"),s=("absolute"===l||"fixed"===l)&&(o+c).indexOf("auto")>-1,s?(r=f.position(),u=r.top,i=r.left):(u=parseFloat(o)||0,i=parseFloat(c)||0),Q.isFunction(e)&&(e=e.call(t,n,a)),null!=e.top&&(p.top=e.top-a.top+u),null!=e.left&&(p.left=e.left-a.left+i),"using"in e?e.using.call(t,p):f.css(p)}},Q.fn.extend({offset:function(t){if(arguments.length)return void 0===t?this:this.each(function(e){Q.offset.setOffset(this,t,e)});var e,n,r=this[0],i={top:0,left:0},o=r&&r.ownerDocument;if(o)return e=o.documentElement,Q.contains(e,r)?(typeof r.getBoundingClientRect!==Tt&&(i=r.getBoundingClientRect()),n=M(o),{top:i.top+n.pageYOffset-e.clientTop,left:i.left+n.pageXOffset-e.clientLeft}):i},position:function(){if(this[0]){var t,e,n=this[0],r={top:0,left:0};return"fixed"===Q.css(n,"position")?e=n.getBoundingClientRect():(t=this.offsetParent(),e=this.offset(),Q.nodeName(t[0],"html")||(r=t.offset()),r.top+=Q.css(t[0],"borderTopWidth",!0),r.left+=Q.css(t[0],"borderLeftWidth",!0)),{top:e.top-r.top-Q.css(n,"marginTop",!0),left:e.left-r.left-Q.css(n,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){for(var t=this.offsetParent||qe;t&&!Q.nodeName(t,"html")&&"static"===Q.css(t,"position");)t=t.offsetParent;return t||qe})}}),Q.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(e,n){var r="pageYOffset"===n;Q.fn[e]=function(i){return vt(this,function(e,i,o){var u=M(e);return void 0===o?u?u[n]:e[i]:void(u?u.scrollTo(r?t.pageXOffset:o,r?o:t.pageYOffset):e[i]=o)},e,i,arguments.length,null)}}),Q.each(["top","left"],function(t,e){Q.cssHooks[e]=w(Y.pixelPosition,function(t,n){if(n)return n=_(t,e),$t.test(n)?Q(t).position()[e]+"px":n})}),Q.each({Height:"height",Width:"width"},function(t,e){Q.each({padding:"inner"+t,content:e,"":"outer"+t},function(n,r){Q.fn[r]=function(r,i){var o=arguments.length&&(n||"boolean"!=typeof r),u=n||(r===!0||i===!0?"margin":"border");return vt(this,function(e,n,r){var i;return Q.isWindow(e)?e.document.documentElement["client"+t]:9===e.nodeType?(i=e.documentElement,Math.max(e.body["scroll"+t],i["scroll"+t],e.body["offset"+t],i["offset"+t],i["client"+t])):void 0===r?Q.css(e,n,u):Q.style(e,n,r,u)},e,o?r:void 0,o,null)}})}),Q.fn.size=function(){return this.length},Q.fn.andSelf=Q.fn.addBack,"function"==typeof define&&define.amd&&define("jquery",[],function(){return Q});var He=t.jQuery,Pe=t.$;return Q.noConflict=function(e){return t.$===Q&&(t.$=Pe),e&&t.jQuery===Q&&(t.jQuery=He),Q},typeof e===Tt&&(t.jQuery=t.$=Q),Q}),function(){function t(t,e){return t.set(e[0],e[1]),t}function e(t,e){return t.add(e),t}function n(t,e,n){var r=n.length;switch(r){case 0:return t.call(e);case 1:return t.call(e,n[0]);case 2:return t.call(e,n[0],n[1]);case 3:return t.call(e,n[0],n[1],n[2])}return t.apply(e,n)}function r(t,e,n,r){for(var i=-1,o=t.length;++i<o;){var u=t[i];e(r,u,n(u),t)}return r}function i(t,e){for(var n=-1,r=t.length,i=-1,o=e.length,u=Array(r+o);++n<r;)u[n]=t[n];for(;++i<o;)u[n++]=e[i];return u}function o(t,e){for(var n=-1,r=t.length;++n<r&&e(t[n],n,t)!==!1;);return t}function u(t,e){for(var n=t.length;n--&&e(t[n],n,t)!==!1;);return t}function a(t,e){for(var n=-1,r=t.length;++n<r;)if(!e(t[n],n,t))return!1;return!0}function c(t,e){for(var n=-1,r=t.length,i=0,o=[];++n<r;){var u=t[n];e(u,n,t)&&(o[i++]=u)}return o}function s(t,e){return!!t.length&&y(t,e,0)>-1}function l(t,e,n){for(var r=-1,i=t.length;++r<i;)if(n(e,t[r]))return!0;return!1}function f(t,e){for(var n=-1,r=t.length,i=Array(r);++n<r;)i[n]=e(t[n],n,t);return i}function p(t,e){for(var n=-1,r=e.length,i=t.length;++n<r;)t[i+n]=e[n];return t}function h(t,e,n,r){var i=-1,o=t.length;for(r&&o&&(n=t[++i]);++i<o;)n=e(n,t[i],i,t);return n}function d(t,e,n,r){var i=t.length;for(r&&i&&(n=t[--i]);i--;)n=e(n,t[i],i,t);return n}function g(t,e){for(var n=-1,r=t.length;++n<r;)if(e(t[n],n,t))return!0;return!1}function v(t,e,n,r){var i;return n(t,function(t,n,o){if(e(t,n,o))return i=r?n:t,!1}),i}function m(t,e,n){for(var r=t.length,i=n?r:-1;n?i--:++i<r;)if(e(t[i],i,t))return i;return-1}function y(t,e,n){if(e!==e)return q(t,n);for(var r=n-1,i=t.length;++r<i;)if(t[r]===e)return r;return-1}function b(t,e,n,r){for(var i=n-1,o=t.length;++i<o;)if(r(t[i],e))return i;return-1}function x(t,e){var n=t?t.length:0;return n?C(t,e)/n:bt}function _(t,e,n,r,i){return i(t,function(t,i,o){n=r?(r=!1,t):e(n,t,i,o)}),n}function w(t,e){var n=t.length;for(t.sort(e);n--;)t[n]=t[n].value;return t}function C(t,e){for(var n,r=-1,i=t.length;++r<i;){var o=e(t[r]);o!==J&&(n=n===J?o:n+o)}return n}function k(t,e){for(var n=-1,r=Array(t);++n<t;)r[n]=e(n);return r}function T(t,e){return f(e,function(e){return[e,t[e]]})}function j(t){return function(e){return t(e)}}function A(t,e){return f(e,function(e){return t[e]})}function E(t,e){for(var n=-1,r=t.length;++n<r&&y(e,t[n],0)>-1;);return n}function S(t,e){for(var n=t.length;n--&&y(e,t[n],0)>-1;);return n}function N(t){return t&&t.Object===Object?t:null}function D(t,e){for(var n=t.length,r=0;n--;)t[n]===e&&r++;return r}function O(t){return wn[t]}function L(t){return Cn[t]}function R(t){return"\\"+jn[t]}function q(t,e,n){for(var r=t.length,i=e+(n?0:-1);n?i--:++i<r;){var o=t[i];if(o!==o)return i}return-1}function H(t){var e=!1;if(null!=t&&"function"!=typeof t.toString)try{e=!!(t+"")}catch(n){}return e}function P(t){for(var e,n=[];!(e=t.next()).done;)n.push(e.value);return n}function I(t){var e=-1,n=Array(t.size);return t.forEach(function(t,r){n[++e]=[r,t]}),n}function W(t,e){for(var n=-1,r=t.length,i=0,o=[];++n<r;){var u=t[n];u!==e&&u!==Y||(t[n]=Y,o[i++]=n)}return o}function F(t){var e=-1,n=Array(t.size);return t.forEach(function(t){n[++e]=t}),n}function M(t){if(!t||!vn.test(t))return t.length;for(var e=dn.lastIndex=0;dn.test(t);)e++;return e}function $(t){return t.match(dn)}function B(t){return kn[t]}function z(N){function Ee(t){if(sa(t)&&!tf(t)&&!(t instanceof De)){if(t instanceof Ne)return t;if(ds.call(t,"__wrapped__"))return eo(t)}return new Ne(t)}function Se(){}function Ne(t,e){this.__wrapped__=t,this.__actions__=[],this.__chain__=!!e,this.__index__=0,this.__values__=J}function De(t){this.__wrapped__=t,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=xt,this.__views__=[]}function Oe(){var t=new De(this.__wrapped__);return t.__actions__=Yr(this.__actions__),t.__dir__=this.__dir__,t.__filtered__=this.__filtered__,t.__iteratees__=Yr(this.__iteratees__),t.__takeCount__=this.__takeCount__,t.__views__=Yr(this.__views__),t}function Le(){if(this.__filtered__){var t=new De(this);t.__dir__=-1,t.__filtered__=!0}else t=this.clone(),t.__dir__*=-1;return t}function Re(){var t=this.__wrapped__.value(),e=this.__dir__,n=tf(t),r=e<0,i=n?t.length:0,o=Li(0,i,this.__views__),u=o.start,a=o.end,c=a-u,s=r?a:u-1,l=this.__iteratees__,f=l.length,p=0,h=Ws(c,this.__takeCount__);if(!n||i<K||i==c&&h==c)return Dr(t,this.__actions__);var d=[];t:for(;c--&&p<h;){s+=e;for(var g=-1,v=t[s];++g<f;){var m=l[g],y=m.iteratee,b=m.type,x=y(v);if(b==dt)v=x;else if(!x){if(b==ht)continue t;break t}}d[p++]=v}return d}function qe(){}function He(t,e){return Ie(t,e)&&delete t[e]}function Pe(t,e){if(Ys){var n=t[e];return n===V?J:n}return ds.call(t,e)?t[e]:J}function Ie(t,e){return Ys?t[e]!==J:ds.call(t,e)}function We(t,e,n){t[e]=Ys&&n===J?V:n}function Fe(t){var e=-1,n=t?t.length:0;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}function Me(){this.__data__={hash:new qe,map:Us?new Us:[],string:new qe}}function $e(t){var e=this.__data__;return zi(t)?He("string"==typeof t?e.string:e.hash,t):Us?e.map["delete"](t):en(e.map,t)}function Be(t){var e=this.__data__;return zi(t)?Pe("string"==typeof t?e.string:e.hash,t):Us?e.map.get(t):nn(e.map,t)}function ze(t){var e=this.__data__;return zi(t)?Ie("string"==typeof t?e.string:e.hash,t):Us?e.map.has(t):rn(e.map,t)}function Je(t,e){var n=this.__data__;return zi(t)?We("string"==typeof t?n.string:n.hash,t,e):Us?n.map.set(t,e):un(n.map,t,e),this}function Ue(t){var e=-1,n=t?t.length:0;for(this.__data__=new Fe;++e<n;)this.push(t[e])}function Ke(t,e){var n=t.__data__;if(zi(e)){var r=n.__data__,i="string"==typeof e?r.string:r.hash;return i[e]===V}return n.has(e)}function Xe(t){var e=this.__data__;if(zi(t)){var n=e.__data__,r="string"==typeof t?n.string:n.hash;r[t]=V}else e.set(t,V)}function Ve(t){var e=-1,n=t?t.length:0;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}function Ye(){this.__data__={array:[],map:null}}function Ge(t){var e=this.__data__,n=e.array;return n?en(n,t):e.map["delete"](t)}function Ze(t){var e=this.__data__,n=e.array;return n?nn(n,t):e.map.get(t)}function Qe(t){var e=this.__data__,n=e.array;return n?rn(n,t):e.map.has(t)}function tn(t,e){var n=this.__data__,r=n.array;r&&(r.length<K-1?un(r,t,e):(n.array=null,n.map=new Fe(r)));var i=n.map;return i&&i.set(t,e),this}function en(t,e){var n=on(t,e);if(n<0)return!1;var r=t.length-1;return n==r?t.pop():Ds.call(t,n,1),!0}function nn(t,e){var n=on(t,e);return n<0?J:t[n][1]}function rn(t,e){return on(t,e)>-1}function on(t,e){for(var n=t.length;n--;)if(Uu(t[n][0],e))return n;return-1}function un(t,e,n){var r=on(t,e);r<0?t.push([e,n]):t[r][1]=n}function an(t,e,n,r){return t===J||Uu(t,fs[n])&&!ds.call(r,n)?e:t}function cn(t,e,n){(n===J||Uu(t[e],n))&&("number"!=typeof e||n!==J||e in t)||(t[e]=n)}function sn(t,e,n){var r=t[e];ds.call(t,e)&&Uu(r,n)&&(n!==J||e in t)||(t[e]=n)}function ln(t,e,n,r){return cl(t,function(t,i,o){e(r,t,n(t),o)}),r}function fn(t,e){return t&&Gr(e,Ka(e),t)}function dn(t,e){for(var n=-1,r=null==t,i=e.length,o=Array(i);++n<i;)o[n]=r?J:za(t,e[n]);return o}function wn(t,e,n){return t===t&&(n!==J&&(t=t<=n?t:n),e!==J&&(t=t>=e?t:e)),t}function Cn(t,e,n,r,i,u,a){var c;if(r&&(c=u?r(t,i,u,a):r(t)),c!==J)return c;if(!ca(t))return t;var s=tf(t);if(s){if(c=qi(t),!e)return Yr(t,c)}else{var l=Oi(t),f=l==Et||l==St;if(ef(t))return Ir(t,e);if(l==Ot||l==Ct||f&&!u){if(H(t))return u?t:{};if(c=Hi(f?{}:t),!e)return Zr(t,fn(c,t))}else{if(!_n[l])return u?t:{};c=Pi(t,l,Cn,e)}}a||(a=new Ve);var p=a.get(t);if(p)return p;if(a.set(t,c),!s)var h=n?Ci(t):Ka(t);return o(h||t,function(i,o){h&&(o=i,i=t[o]),sn(c,o,Cn(i,e,n,r,o,t,a))}),c}function kn(t){var e=Ka(t),n=e.length;return function(r){if(null==r)return!n;for(var i=n;i--;){var o=e[i],u=t[o],a=r[o];if(a===J&&!(o in Object(r))||!u(a))return!1}return!0}}function Tn(t){return ca(t)?Es(t):{}}function jn(t,e,n){if("function"!=typeof t)throw new ss(X);return Ns(function(){t.apply(J,n)},e)}function Sn(t,e,n,r){var i=-1,o=s,u=!0,a=t.length,c=[],p=e.length;if(!a)return c;n&&(e=f(e,j(n))),r?(o=l,u=!1):e.length>=K&&(o=Ke,u=!1,e=new Ue(e));t:for(;++i<a;){var h=t[i],d=n?n(h):h;if(h=r||0!==h?h:0,u&&d===d){for(var g=p;g--;)if(e[g]===d)continue t;c.push(h)}else o(e,d,r)||c.push(h)}return c}function Nn(t,e){var n=!0;return cl(t,function(t,r,i){return n=!!e(t,r,i)}),n}function On(t,e,n){for(var r=-1,i=t.length;++r<i;){var o=t[r],u=e(o);if(null!=u&&(a===J?u===u&&!Ca(u):n(u,a)))var a=u,c=o}return c}function Ln(t,e,n,r){var i=t.length;for(n=Sa(n),n<0&&(n=-n>i?0:i+n),r=r===J||r>i?i:Sa(r),r<0&&(r+=i),r=n>r?0:Na(r);n<r;)t[n++]=e;return t}function Rn(t,e){var n=[];return cl(t,function(t,r,i){e(t,r,i)&&n.push(t)}),n}function qn(t,e,n,r,i){var o=-1,u=t.length;for(n||(n=Wi),i||(i=[]);++o<u;){var a=t[o];e>0&&n(a)?e>1?qn(a,e-1,n,r,i):p(i,a):r||(i[i.length]=a)}return i}function In(t,e){return t&&ll(t,e,Ka)}function Wn(t,e){return t&&fl(t,e,Ka)}function Fn(t,e){return c(e,function(e){return oa(t[e])})}function Mn(t,e){e=Bi(e,t)?[e]:Hr(e);for(var n=0,r=e.length;null!=t&&n<r;)t=t[Qi(e[n++])];return n&&n==r?t:J}function $n(t,e,n){var r=e(t);return tf(t)?r:p(r,n(t))}function Bn(t,e){return t>e}function zn(t,e){return ds.call(t,e)||"object"==typeof t&&e in t&&null===Ni(t)}function Jn(t,e){return e in Object(t)}function Un(t,e,n){return t>=Ws(e,n)&&t<Is(e,n)}function Kn(t,e,n){for(var r=n?l:s,i=t[0].length,o=t.length,u=o,a=Array(o),c=1/0,p=[];u--;){var h=t[u];u&&e&&(h=f(h,j(e))),c=Ws(h.length,c),a[u]=!n&&(e||i>=120&&h.length>=120)?new Ue(u&&h):J}h=t[0];var d=-1,g=a[0];t:for(;++d<i&&p.length<c;){var v=h[d],m=e?e(v):v;if(v=n||0!==v?v:0,!(g?Ke(g,m):r(p,m,n))){for(u=o;--u;){var y=a[u];if(!(y?Ke(y,m):r(t[u],m,n)))continue t}g&&g.push(m),p.push(v)}}return p}function Xn(t,e,n,r){return In(t,function(t,i,o){e(r,n(t),i,o)}),r}function Vn(t,e,r){Bi(e,t)||(e=Hr(e),t=Gi(t,e),e=_o(e));var i=null==t?t:t[Qi(e)];return null==i?J:n(i,t,r)}function Yn(t,e,n,r,i){return t===e||(null==t||null==e||!ca(t)&&!sa(e)?t!==t&&e!==e:Gn(t,e,Yn,n,r,i))}function Gn(t,e,n,r,i,o){var u=tf(t),a=tf(e),c=kt,s=kt;u||(c=Oi(t),c=c==Ct?Ot:c),a||(s=Oi(e),s=s==Ct?Ot:s);var l=c==Ot&&!H(t),f=s==Ot&&!H(e),p=c==s;if(p&&!l)return o||(o=new Ve),u||ka(t)?xi(t,e,n,r,i,o):_i(t,e,c,n,r,i,o);if(!(i&ct)){var h=l&&ds.call(t,"__wrapped__"),d=f&&ds.call(e,"__wrapped__");if(h||d){var g=h?t.value():t,v=d?e.value():e;return o||(o=new Ve),n(g,v,r,i,o)}}return!!p&&(o||(o=new Ve),wi(t,e,n,r,i,o))}function Zn(t,e,n,r){var i=n.length,o=i,u=!r;if(null==t)return!o;for(t=Object(t);i--;){var a=n[i];if(u&&a[2]?a[1]!==t[a[0]]:!(a[0]in t))return!1}for(;++i<o;){a=n[i];var c=a[0],s=t[c],l=a[1];if(u&&a[2]){if(s===J&&!(c in t))return!1}else{var f=new Ve;if(r)var p=r(s,l,c,t,e,f);if(!(p===J?Yn(l,s,r,at|ct,f):p))return!1}}return!0}function Qn(t){return"function"==typeof t?t:null==t?Ic:"object"==typeof t?tf(t)?or(t[0],t[1]):ir(t):Uc(t)}function tr(t){return Ps(Object(t))}function er(t){t=null==t?t:Object(t);var e=[];for(var n in t)e.push(n);return e}function nr(t,e){return t<e}function rr(t,e){var n=-1,r=Vu(t)?Array(t.length):[];return cl(t,function(t,i,o){r[++n]=e(t,i,o)}),r}function ir(t){var e=Ai(t);return 1==e.length&&e[0][2]?Xi(e[0][0],e[0][1]):function(n){return n===t||Zn(n,t,e)}}function or(t,e){return Bi(t)&&Ki(e)?Xi(Qi(t),e):function(n){var r=za(n,t);return r===J&&r===e?Ua(n,t):Yn(e,r,J,at|ct)}}function ur(t,e,n,r,i){if(t!==e){if(!tf(e)&&!ka(e))var u=Xa(e);o(u||e,function(o,a){if(u&&(a=o,o=e[a]),ca(o))i||(i=new Ve),ar(t,e,a,n,ur,r,i);else{var c=r?r(t[a],o,a+"",t,e,i):J;c===J&&(c=o),cn(t,a,c)}})}}function ar(t,e,n,r,i,o,u){var a=t[n],c=e[n],s=u.get(c);if(s)return void cn(t,n,s);var l=o?o(a,c,n+"",t,e,u):J,f=l===J;f&&(l=c,tf(c)||ka(c)?tf(a)?l=a:Yu(a)?l=Yr(a):(f=!1,l=Cn(c,!0)):ya(c)||Ku(c)?Ku(a)?l=Oa(a):!ca(a)||r&&oa(a)?(f=!1,l=Cn(c,!0)):l=a:f=!1),u.set(c,l),f&&i(l,c,r,o,u),u["delete"](c),cn(t,n,l)}function cr(t,e){var n=t.length;if(n)return e+=e<0?n:0,Mi(e,n)?t[e]:J}function sr(t,e,n){var r=-1;e=f(e.length?e:[Ic],j(ji()));
+var i=rr(t,function(t,n,i){var o=f(e,function(e){return e(t)});return{criteria:o,index:++r,value:t}});return w(i,function(t,e){return Kr(t,e,n)})}function lr(t,e){return t=Object(t),h(e,function(e,n){return n in t&&(e[n]=t[n]),e},{})}function fr(t,e){for(var n=-1,r=ki(t),i=r.length,o={};++n<i;){var u=r[n],a=t[u];e(a,u)&&(o[u]=a)}return o}function pr(t){return function(e){return null==e?J:e[t]}}function hr(t){return function(e){return Mn(e,t)}}function dr(t,e,n,r){var i=r?b:y,o=-1,u=e.length,a=t;for(n&&(a=f(t,j(n)));++o<u;)for(var c=0,s=e[o],l=n?n(s):s;(c=i(a,l,c,r))>-1;)a!==t&&Ds.call(a,c,1),Ds.call(t,c,1);return t}function gr(t,e){for(var n=t?e.length:0,r=n-1;n--;){var i=e[n];if(n==r||i!==o){var o=i;if(Mi(i))Ds.call(t,i,1);else if(Bi(i,t))delete t[Qi(i)];else{var u=Hr(i),a=Gi(t,u);null!=a&&delete a[Qi(_o(u))]}}}return t}function vr(t,e){return t+Ls(Ms()*(e-t+1))}function mr(t,e,n,r){for(var i=-1,o=Is(Os((e-t)/(n||1)),0),u=Array(o);o--;)u[r?o:++i]=t,t+=n;return u}function yr(t,e){var n="";if(!t||e<1||e>mt)return n;do e%2&&(n+=t),e=Ls(e/2),e&&(t+=t);while(e);return n}function br(t,e,n,r){e=Bi(e,t)?[e]:Hr(e);for(var i=-1,o=e.length,u=o-1,a=t;null!=a&&++i<o;){var c=Qi(e[i]);if(ca(a)){var s=n;if(i!=u){var l=a[c];s=r?r(l,c,a):J,s===J&&(s=null==l?Mi(e[i+1])?[]:{}:l)}sn(a,c,s)}a=a[c]}return t}function xr(t,e,n){var r=-1,i=t.length;e<0&&(e=-e>i?0:i+e),n=n>i?i:n,n<0&&(n+=i),i=e>n?0:n-e>>>0,e>>>=0;for(var o=Array(i);++r<i;)o[r]=t[r+e];return o}function _r(t,e){var n;return cl(t,function(t,r,i){return n=e(t,r,i),!n}),!!n}function wr(t,e,n){var r=0,i=t?t.length:r;if("number"==typeof e&&e===e&&i<=wt){for(;r<i;){var o=r+i>>>1,u=t[o];null!==u&&!Ca(u)&&(n?u<=e:u<e)?r=o+1:i=o}return i}return Cr(t,e,Ic,n)}function Cr(t,e,n,r){e=n(e);for(var i=0,o=t?t.length:0,u=e!==e,a=null===e,c=Ca(e),s=e===J;i<o;){var l=Ls((i+o)/2),f=n(t[l]),p=f!==J,h=null===f,d=f===f,g=Ca(f);if(u)var v=r||d;else v=s?d&&(r||p):a?d&&p&&(r||!h):c?d&&p&&!h&&(r||!g):!h&&!g&&(r?f<=e:f<e);v?i=l+1:o=l}return Ws(o,_t)}function kr(t,e){for(var n=-1,r=t.length,i=0,o=[];++n<r;){var u=t[n],a=e?e(u):u;if(!n||!Uu(a,c)){var c=a;o[i++]=0===u?0:u}}return o}function Tr(t){return"number"==typeof t?t:Ca(t)?bt:+t}function jr(t){if("string"==typeof t)return t;if(Ca(t))return al?al.call(t):"";var e=t+"";return"0"==e&&1/t==-vt?"-0":e}function Ar(t,e,n){var r=-1,i=s,o=t.length,u=!0,a=[],c=a;if(n)u=!1,i=l;else if(o>=K){var f=e?null:hl(t);if(f)return F(f);u=!1,i=Ke,c=new Ue}else c=e?[]:a;t:for(;++r<o;){var p=t[r],h=e?e(p):p;if(p=n||0!==p?p:0,u&&h===h){for(var d=c.length;d--;)if(c[d]===h)continue t;e&&c.push(h),a.push(p)}else i(c,h,n)||(c!==a&&c.push(h),a.push(p))}return a}function Er(t,e){e=Bi(e,t)?[e]:Hr(e),t=Gi(t,e);var n=Qi(_o(e));return!(null!=t&&zn(t,n))||delete t[n]}function Sr(t,e,n,r){return br(t,e,n(Mn(t,e)),r)}function Nr(t,e,n,r){for(var i=t.length,o=r?i:-1;(r?o--:++o<i)&&e(t[o],o,t););return n?xr(t,r?0:o,r?o+1:i):xr(t,r?o+1:0,r?i:o)}function Dr(t,e){var n=t;return n instanceof De&&(n=n.value()),h(e,function(t,e){return e.func.apply(e.thisArg,p([t],e.args))},n)}function Or(t,e,n){for(var r=-1,i=t.length;++r<i;)var o=o?p(Sn(o,t[r],e,n),Sn(t[r],o,e,n)):t[r];return o&&o.length?Ar(o,e,n):[]}function Lr(t,e,n){for(var r=-1,i=t.length,o=e.length,u={};++r<i;){var a=r<o?e[r]:J;n(u,t[r],a)}return u}function Rr(t){return Yu(t)?t:[]}function qr(t){return"function"==typeof t?t:Ic}function Hr(t){return tf(t)?t:yl(t)}function Pr(t,e,n){var r=t.length;return n=n===J?r:n,!e&&n>=r?t:xr(t,e,n)}function Ir(t,e){if(e)return t.slice();var n=new t.constructor(t.length);return t.copy(n),n}function Wr(t){var e=new t.constructor(t.byteLength);return new Cs(e).set(new Cs(t)),e}function Fr(t,e){var n=e?Wr(t.buffer):t.buffer;return new t.constructor(n,t.byteOffset,t.byteLength)}function Mr(e,n,r){var i=n?r(I(e),!0):I(e);return h(i,t,new e.constructor)}function $r(t){var e=new t.constructor(t.source,ye.exec(t));return e.lastIndex=t.lastIndex,e}function Br(t,n,r){var i=n?r(F(t),!0):F(t);return h(i,e,new t.constructor)}function zr(t){return ul?Object(ul.call(t)):{}}function Jr(t,e){var n=e?Wr(t.buffer):t.buffer;return new t.constructor(n,t.byteOffset,t.length)}function Ur(t,e){if(t!==e){var n=t!==J,r=null===t,i=t===t,o=Ca(t),u=e!==J,a=null===e,c=e===e,s=Ca(e);if(!a&&!s&&!o&&t>e||o&&u&&c&&!a&&!s||r&&u&&c||!n&&c||!i)return 1;if(!r&&!o&&!s&&t<e||s&&n&&i&&!r&&!o||a&&n&&i||!u&&i||!c)return-1}return 0}function Kr(t,e,n){for(var r=-1,i=t.criteria,o=e.criteria,u=i.length,a=n.length;++r<u;){var c=Ur(i[r],o[r]);if(c){if(r>=a)return c;var s=n[r];return c*("desc"==s?-1:1)}}return t.index-e.index}function Xr(t,e,n,r){for(var i=-1,o=t.length,u=n.length,a=-1,c=e.length,s=Is(o-u,0),l=Array(c+s),f=!r;++a<c;)l[a]=e[a];for(;++i<u;)(f||i<o)&&(l[n[i]]=t[i]);for(;s--;)l[a++]=t[i++];return l}function Vr(t,e,n,r){for(var i=-1,o=t.length,u=-1,a=n.length,c=-1,s=e.length,l=Is(o-a,0),f=Array(l+s),p=!r;++i<l;)f[i]=t[i];for(var h=i;++c<s;)f[h+c]=e[c];for(;++u<a;)(p||i<o)&&(f[h+n[u]]=t[i++]);return f}function Yr(t,e){var n=-1,r=t.length;for(e||(e=Array(r));++n<r;)e[n]=t[n];return e}function Gr(t,e,n,r){n||(n={});for(var i=-1,o=e.length;++i<o;){var u=e[i],a=r?r(n[u],t[u],u,n,t):t[u];sn(n,u,a)}return n}function Zr(t,e){return Gr(t,Di(t),e)}function Qr(t,e){return function(n,i){var o=tf(n)?r:ln,u=e?e():{};return o(n,t,ji(i),u)}}function ti(t){return Hu(function(e,n){var r=-1,i=n.length,o=i>1?n[i-1]:J,u=i>2?n[2]:J;for(o="function"==typeof o?(i--,o):J,u&&$i(n[0],n[1],u)&&(o=i<3?J:o,i=1),e=Object(e);++r<i;){var a=n[r];a&&t(e,a,r,o)}return e})}function ei(t,e){return function(n,r){if(null==n)return n;if(!Vu(n))return t(n,r);for(var i=n.length,o=e?i:-1,u=Object(n);(e?o--:++o<i)&&r(u[o],o,u)!==!1;);return n}}function ni(t){return function(e,n,r){for(var i=-1,o=Object(e),u=r(e),a=u.length;a--;){var c=u[t?a:++i];if(n(o[c],c,o)===!1)break}return e}}function ri(t,e,n){function r(){var e=this&&this!==Hn&&this instanceof r?o:t;return e.apply(i?n:this,arguments)}var i=e&G,o=ui(t);return r}function ii(t){return function(e){e=Ra(e);var n=vn.test(e)?$(e):J,r=n?n[0]:e.charAt(0),i=n?Pr(n,1).join(""):e.slice(1);return r[t]()+i}}function oi(t){return function(e){return h(Rc(dc(e).replace(pn,"")),t,"")}}function ui(t){return function(){var e=arguments;switch(e.length){case 0:return new t;case 1:return new t(e[0]);case 2:return new t(e[0],e[1]);case 3:return new t(e[0],e[1],e[2]);case 4:return new t(e[0],e[1],e[2],e[3]);case 5:return new t(e[0],e[1],e[2],e[3],e[4]);case 6:return new t(e[0],e[1],e[2],e[3],e[4],e[5]);case 7:return new t(e[0],e[1],e[2],e[3],e[4],e[5],e[6])}var n=Tn(t.prototype),r=t.apply(n,e);return ca(r)?r:n}}function ai(t,e,r){function i(){for(var u=arguments.length,a=Array(u),c=u,s=Si(i);c--;)a[c]=arguments[c];var l=u<3&&a[0]!==s&&a[u-1]!==s?[]:W(a,s);if(u-=l.length,u<r)return mi(t,e,si,i.placeholder,J,a,l,J,J,r-u);var f=this&&this!==Hn&&this instanceof i?o:t;return n(f,this,a)}var o=ui(t);return i}function ci(t){return Hu(function(e){e=qn(e,1);var n=e.length,r=n,i=Ne.prototype.thru;for(t&&e.reverse();r--;){var o=e[r];if("function"!=typeof o)throw new ss(X);if(i&&!u&&"wrapper"==Ti(o))var u=new Ne([],(!0))}for(r=u?r:n;++r<n;){o=e[r];var a=Ti(o),c="wrapper"==a?dl(o):J;u=c&&Ji(c[0])&&c[1]==(it|tt|nt|ot)&&!c[4].length&&1==c[9]?u[Ti(c[0])].apply(u,c[3]):1==o.length&&Ji(o)?u[a]():u.thru(o)}return function(){var t=arguments,r=t[0];if(u&&1==t.length&&tf(r)&&r.length>=K)return u.plant(r).value();for(var i=0,o=n?e[i].apply(this,t):r;++i<n;)o=e[i].call(this,o);return o}})}function si(t,e,n,r,i,o,u,a,c,s){function l(){for(var m=arguments.length,y=m,b=Array(m);y--;)b[y]=arguments[y];if(d)var x=Si(l),_=D(b,x);if(r&&(b=Xr(b,r,i,d)),o&&(b=Vr(b,o,u,d)),m-=_,d&&m<s){var w=W(b,x);return mi(t,e,si,l.placeholder,n,b,w,a,c,s-m)}var C=p?n:this,k=h?C[t]:t;return m=b.length,a?b=Zi(b,a):g&&m>1&&b.reverse(),f&&c<m&&(b.length=c),this&&this!==Hn&&this instanceof l&&(k=v||ui(k)),k.apply(C,b)}var f=e&it,p=e&G,h=e&Z,d=e&(tt|et),g=e&ut,v=h?J:ui(t);return l}function li(t,e){return function(n,r){return Xn(n,t,e(r),{})}}function fi(t){return function(e,n){var r;if(e===J&&n===J)return 0;if(e!==J&&(r=e),n!==J){if(r===J)return n;"string"==typeof e||"string"==typeof n?(e=jr(e),n=jr(n)):(e=Tr(e),n=Tr(n)),r=t(e,n)}return r}}function pi(t){return Hu(function(e){return e=1==e.length&&tf(e[0])?f(e[0],j(ji())):f(qn(e,1,Fi),j(ji())),Hu(function(r){var i=this;return t(e,function(t){return n(t,i,r)})})})}function hi(t,e){e=e===J?" ":jr(e);var n=e.length;if(n<2)return n?yr(e,t):e;var r=yr(e,Os(t/M(e)));return vn.test(e)?Pr($(r),0,t).join(""):r.slice(0,t)}function di(t,e,r,i){function o(){for(var e=-1,c=arguments.length,s=-1,l=i.length,f=Array(l+c),p=this&&this!==Hn&&this instanceof o?a:t;++s<l;)f[s]=i[s];for(;c--;)f[s++]=arguments[++e];return n(p,u?r:this,f)}var u=e&G,a=ui(t);return o}function gi(t){return function(e,n,r){return r&&"number"!=typeof r&&$i(e,n,r)&&(n=r=J),e=Da(e),e=e===e?e:0,n===J?(n=e,e=0):n=Da(n)||0,r=r===J?e<n?1:-1:Da(r)||0,mr(e,n,r,t)}}function vi(t){return function(e,n){return"string"==typeof e&&"string"==typeof n||(e=Da(e),n=Da(n)),t(e,n)}}function mi(t,e,n,r,i,o,u,a,c,s){var l=e&tt,f=l?u:J,p=l?J:u,h=l?o:J,d=l?J:o;e|=l?nt:rt,e&=~(l?rt:nt),e&Q||(e&=~(G|Z));var g=[t,e,i,h,f,d,p,a,c,s],v=n.apply(J,g);return Ji(t)&&ml(v,g),v.placeholder=r,v}function yi(t){var e=as[t];return function(t,n){if(t=Da(t),n=Sa(n)){var r=(Ra(t)+"e").split("e"),i=e(r[0]+"e"+(+r[1]+n));return r=(Ra(i)+"e").split("e"),+(r[0]+"e"+(+r[1]-n))}return e(t)}}function bi(t,e,n,r,i,o,u,a){var c=e&Z;if(!c&&"function"!=typeof t)throw new ss(X);var s=r?r.length:0;if(s||(e&=~(nt|rt),r=i=J),u=u===J?u:Is(Sa(u),0),a=a===J?a:Sa(a),s-=i?i.length:0,e&rt){var l=r,f=i;r=i=J}var p=c?J:dl(t),h=[t,e,n,r,i,l,f,o,u,a];if(p&&Vi(h,p),t=h[0],e=h[1],n=h[2],r=h[3],i=h[4],a=h[9]=null==h[9]?c?0:t.length:Is(h[9]-s,0),!a&&e&(tt|et)&&(e&=~(tt|et)),e&&e!=G)d=e==tt||e==et?ai(t,e,a):e!=nt&&e!=(G|nt)||i.length?si.apply(J,h):di(t,e,n,r);else var d=ri(t,e,n);var g=p?pl:ml;return g(d,h)}function xi(t,e,n,r,i,o){var u=-1,a=i&ct,c=i&at,s=t.length,l=e.length;if(s!=l&&!(a&&l>s))return!1;var f=o.get(t);if(f)return f==e;var p=!0;for(o.set(t,e);++u<s;){var h=t[u],d=e[u];if(r)var v=a?r(d,h,u,e,t,o):r(h,d,u,t,e,o);if(v!==J){if(v)continue;p=!1;break}if(c){if(!g(e,function(t){return h===t||n(h,t,r,i,o)})){p=!1;break}}else if(h!==d&&!n(h,d,r,i,o)){p=!1;break}}return o["delete"](t),p}function _i(t,e,n,r,i,o,u){switch(n){case Mt:if(t.byteLength!=e.byteLength||t.byteOffset!=e.byteOffset)return!1;t=t.buffer,e=e.buffer;case Ft:return!(t.byteLength!=e.byteLength||!r(new Cs(t),new Cs(e)));case Tt:case jt:return+t==+e;case At:return t.name==e.name&&t.message==e.message;case Dt:return t!=+t?e!=+e:t==+e;case Rt:case Ht:return t==e+"";case Nt:var a=I;case qt:var c=o&ct;if(a||(a=F),t.size!=e.size&&!c)return!1;var s=u.get(t);return s?s==e:(o|=at,u.set(t,e),xi(a(t),a(e),r,i,o,u));case Pt:if(ul)return ul.call(t)==ul.call(e)}return!1}function wi(t,e,n,r,i,o){var u=i&ct,a=Ka(t),c=a.length,s=Ka(e),l=s.length;if(c!=l&&!u)return!1;for(var f=c;f--;){var p=a[f];if(!(u?p in e:zn(e,p)))return!1}var h=o.get(t);if(h)return h==e;var d=!0;o.set(t,e);for(var g=u;++f<c;){p=a[f];var v=t[p],m=e[p];if(r)var y=u?r(m,v,p,e,t,o):r(v,m,p,t,e,o);if(!(y===J?v===m||n(v,m,r,i,o):y)){d=!1;break}g||(g="constructor"==p)}if(d&&!g){var b=t.constructor,x=e.constructor;b!=x&&"constructor"in t&&"constructor"in e&&!("function"==typeof b&&b instanceof b&&"function"==typeof x&&x instanceof x)&&(d=!1)}return o["delete"](t),d}function Ci(t){return $n(t,Ka,Di)}function ki(t){return $n(t,Xa,vl)}function Ti(t){for(var e=t.name+"",n=Qs[e],r=ds.call(Qs,e)?n.length:0;r--;){var i=n[r],o=i.func;if(null==o||o==t)return i.name}return e}function ji(){var t=Ee.iteratee||Wc;return t=t===Wc?Qn:t,arguments.length?t(arguments[0],arguments[1]):t}function Ai(t){for(var e=nc(t),n=e.length;n--;)e[n][2]=Ki(e[n][1]);return e}function Ei(t,e){var n=t[e];return da(n)?n:J}function Si(t){var e=ds.call(Ee,"placeholder")?Ee:t;return e.placeholder}function Ni(t){return Rs(Object(t))}function Di(t){return js(Object(t))}function Oi(t){return ms.call(t)}function Li(t,e,n){for(var r=-1,i=n.length;++r<i;){var o=n[r],u=o.size;switch(o.type){case"drop":t+=u;break;case"dropRight":e-=u;break;case"take":e=Ws(e,t+u);break;case"takeRight":t=Is(t,e-u)}}return{start:t,end:e}}function Ri(t,e,n){e=Bi(e,t)?[e]:Hr(e);for(var r,i=-1,o=e.length;++i<o;){var u=Qi(e[i]);if(!(r=null!=t&&n(t,u)))break;t=t[u]}if(r)return r;var o=t?t.length:0;return!!o&&aa(o)&&Mi(u,o)&&(tf(t)||wa(t)||Ku(t))}function qi(t){var e=t.length,n=t.constructor(e);return e&&"string"==typeof t[0]&&ds.call(t,"index")&&(n.index=t.index,n.input=t.input),n}function Hi(t){return"function"!=typeof t.constructor||Ui(t)?{}:Tn(Ni(t))}function Pi(t,e,n,r){var i=t.constructor;switch(e){case Ft:return Wr(t);case Tt:case jt:return new i((+t));case Mt:return Fr(t,r);case $t:case Bt:case zt:case Jt:case Ut:case Kt:case Xt:case Vt:case Yt:return Jr(t,r);case Nt:return Mr(t,r,n);case Dt:case Ht:return new i(t);case Rt:return $r(t);case qt:return Br(t,r,n);case Pt:return zr(t)}}function Ii(t){var e=t?t.length:J;return aa(e)&&(tf(t)||wa(t)||Ku(t))?k(e,String):null}function Wi(t){return Yu(t)&&(tf(t)||Ku(t))}function Fi(t){return tf(t)&&!(2==t.length&&!oa(t[0]))}function Mi(t,e){return e=null==e?mt:e,!!e&&("number"==typeof t||ke.test(t))&&t>-1&&t%1==0&&t<e}function $i(t,e,n){if(!ca(n))return!1;var r=typeof e;return!!("number"==r?Vu(n)&&Mi(e,n.length):"string"==r&&e in n)&&Uu(n[e],t)}function Bi(t,e){if(tf(t))return!1;var n=typeof t;return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=t&&!Ca(t))||(ce.test(t)||!ae.test(t)||null!=e&&t in Object(e))}function zi(t){var e=typeof t;return"string"==e||"number"==e||"symbol"==e||"boolean"==e?"__proto__"!==t:null===t}function Ji(t){var e=Ti(t),n=Ee[e];if("function"!=typeof n||!(e in De.prototype))return!1;if(t===n)return!0;var r=dl(n);return!!r&&t===r[0]}function Ui(t){var e=t&&t.constructor,n="function"==typeof e&&e.prototype||fs;return t===n}function Ki(t){return t===t&&!ca(t)}function Xi(t,e){return function(n){return null!=n&&(n[t]===e&&(e!==J||t in Object(n)))}}function Vi(t,e){var n=t[1],r=e[1],i=n|r,o=i<(G|Z|it),u=r==it&&n==tt||r==it&&n==ot&&t[7].length<=e[8]||r==(it|ot)&&e[7].length<=e[8]&&n==tt;if(!o&&!u)return t;r&G&&(t[2]=e[2],i|=n&G?0:Q);var a=e[3];if(a){var c=t[3];t[3]=c?Xr(c,a,e[4]):a,t[4]=c?W(t[3],Y):e[4]}return a=e[5],a&&(c=t[5],t[5]=c?Vr(c,a,e[6]):a,t[6]=c?W(t[5],Y):e[6]),a=e[7],a&&(t[7]=a),r&it&&(t[8]=null==t[8]?e[8]:Ws(t[8],e[8])),null==t[9]&&(t[9]=e[9]),t[0]=e[0],t[1]=i,t}function Yi(t,e,n,r,i,o){return ca(t)&&ca(e)&&ur(t,e,J,Yi,o.set(e,t)),t}function Gi(t,e){return 1==e.length?t:Mn(t,xr(e,0,-1))}function Zi(t,e){for(var n=t.length,r=Ws(e.length,n),i=Yr(t);r--;){var o=e[r];t[r]=Mi(o,n)?i[o]:J}return t}function Qi(t){if("string"==typeof t||Ca(t))return t;var e=t+"";return"0"==e&&1/t==-vt?"-0":e}function to(t){if(null!=t){try{return hs.call(t)}catch(e){}try{return t+""}catch(e){}}return""}function eo(t){if(t instanceof De)return t.clone();var e=new Ne(t.__wrapped__,t.__chain__);return e.__actions__=Yr(t.__actions__),e.__index__=t.__index__,e.__values__=t.__values__,e}function no(t,e,n){e=(n?$i(t,e,n):e===J)?1:Is(Sa(e),0);var r=t?t.length:0;if(!r||e<1)return[];for(var i=0,o=0,u=Array(Os(r/e));i<r;)u[o++]=xr(t,i,i+=e);return u}function ro(t){for(var e=-1,n=t?t.length:0,r=0,i=[];++e<n;){var o=t[e];o&&(i[r++]=o)}return i}function io(){var t=arguments.length,e=Mu(arguments[0]);if(t<2)return t?Yr(e):[];for(var n=Array(t-1);t--;)n[t-1]=arguments[t];return i(e,qn(n,1))}function oo(t,e,n){var r=t?t.length:0;return r?(e=n||e===J?1:Sa(e),xr(t,e<0?0:e,r)):[]}function uo(t,e,n){var r=t?t.length:0;return r?(e=n||e===J?1:Sa(e),e=r-e,xr(t,0,e<0?0:e)):[]}function ao(t,e){return t&&t.length?Nr(t,ji(e,3),!0,!0):[]}function co(t,e){return t&&t.length?Nr(t,ji(e,3),!0):[]}function so(t,e,n,r){var i=t?t.length:0;return i?(n&&"number"!=typeof n&&$i(t,e,n)&&(n=0,r=i),Ln(t,e,n,r)):[]}function lo(t,e){return t&&t.length?m(t,ji(e,3)):-1}function fo(t,e){return t&&t.length?m(t,ji(e,3),!0):-1}function po(t){var e=t?t.length:0;return e?qn(t,1):[]}function ho(t){var e=t?t.length:0;return e?qn(t,vt):[]}function go(t,e){var n=t?t.length:0;return n?(e=e===J?1:Sa(e),qn(t,e)):[]}function vo(t){for(var e=-1,n=t?t.length:0,r={};++e<n;){var i=t[e];r[i[0]]=i[1]}return r}function mo(t){return t&&t.length?t[0]:J}function yo(t,e,n){var r=t?t.length:0;return r?(n=Sa(n),n<0&&(n=Is(r+n,0)),y(t,e,n)):-1}function bo(t){return uo(t,1)}function xo(t,e){return t?Hs.call(t,e):""}function _o(t){var e=t?t.length:0;return e?t[e-1]:J}function wo(t,e,n){var r=t?t.length:0;if(!r)return-1;var i=r;if(n!==J&&(i=Sa(n),i=(i<0?Is(r+i,0):Ws(i,r-1))+1),e!==e)return q(t,i,!0);for(;i--;)if(t[i]===e)return i;return-1}function Co(t,e){return t&&t.length?cr(t,Sa(e)):J}function ko(t,e){return t&&t.length&&e&&e.length?dr(t,e):t}function To(t,e,n){return t&&t.length&&e&&e.length?dr(t,e,ji(n)):t}function jo(t,e,n){return t&&t.length&&e&&e.length?dr(t,e,J,n):t}function Ao(t,e){var n=[];if(!t||!t.length)return n;var r=-1,i=[],o=t.length;for(e=ji(e,3);++r<o;){var u=t[r];e(u,r,t)&&(n.push(u),i.push(r))}return gr(t,i),n}function Eo(t){return t?Bs.call(t):t}function So(t,e,n){var r=t?t.length:0;return r?(n&&"number"!=typeof n&&$i(t,e,n)?(e=0,n=r):(e=null==e?0:Sa(e),n=n===J?r:Sa(n)),xr(t,e,n)):[]}function No(t,e){return wr(t,e)}function Do(t,e,n){return Cr(t,e,ji(n))}function Oo(t,e){var n=t?t.length:0;if(n){var r=wr(t,e);if(r<n&&Uu(t[r],e))return r}return-1}function Lo(t,e){return wr(t,e,!0)}function Ro(t,e,n){return Cr(t,e,ji(n),!0)}function qo(t,e){var n=t?t.length:0;if(n){var r=wr(t,e,!0)-1;if(Uu(t[r],e))return r}return-1}function Ho(t){return t&&t.length?kr(t):[]}function Po(t,e){return t&&t.length?kr(t,ji(e)):[]}function Io(t){return oo(t,1)}function Wo(t,e,n){return t&&t.length?(e=n||e===J?1:Sa(e),xr(t,0,e<0?0:e)):[]}function Fo(t,e,n){var r=t?t.length:0;return r?(e=n||e===J?1:Sa(e),e=r-e,xr(t,e<0?0:e,r)):[]}function Mo(t,e){return t&&t.length?Nr(t,ji(e,3),!1,!0):[]}function $o(t,e){return t&&t.length?Nr(t,ji(e,3)):[]}function Bo(t){return t&&t.length?Ar(t):[]}function zo(t,e){return t&&t.length?Ar(t,ji(e)):[]}function Jo(t,e){return t&&t.length?Ar(t,J,e):[]}function Uo(t){if(!t||!t.length)return[];var e=0;return t=c(t,function(t){if(Yu(t))return e=Is(t.length,e),!0}),k(e,function(e){return f(t,pr(e))})}function Ko(t,e){if(!t||!t.length)return[];var r=Uo(t);return null==e?r:f(r,function(t){return n(e,J,t)})}function Xo(t,e){return Lr(t||[],e||[],sn)}function Vo(t,e){return Lr(t||[],e||[],br)}function Yo(t){var e=Ee(t);return e.__chain__=!0,e}function Go(t,e){return e(t),t}function Zo(t,e){return e(t)}function Qo(){return Yo(this)}function tu(){return new Ne(this.value(),this.__chain__)}function eu(){this.__values__===J&&(this.__values__=Ea(this.value()));var t=this.__index__>=this.__values__.length,e=t?J:this.__values__[this.__index__++];return{done:t,value:e}}function nu(){return this}function ru(t){for(var e,n=this;n instanceof Se;){var r=eo(n);r.__index__=0,r.__values__=J,e?i.__wrapped__=r:e=r;var i=r;n=n.__wrapped__}return i.__wrapped__=t,e}function iu(){var t=this.__wrapped__;if(t instanceof De){var e=t;return this.__actions__.length&&(e=new De(this)),e=e.reverse(),e.__actions__.push({func:Zo,args:[Eo],thisArg:J}),new Ne(e,this.__chain__)}return this.thru(Eo)}function ou(){return Dr(this.__wrapped__,this.__actions__)}function uu(t,e,n){var r=tf(t)?a:Nn;return n&&$i(t,e,n)&&(e=J),r(t,ji(e,3))}function au(t,e){var n=tf(t)?c:Rn;return n(t,ji(e,3))}function cu(t,e){if(e=ji(e,3),tf(t)){var n=m(t,e);return n>-1?t[n]:J}return v(t,e,cl)}function su(t,e){if(e=ji(e,3),tf(t)){var n=m(t,e,!0);return n>-1?t[n]:J}return v(t,e,sl)}function lu(t,e){return qn(vu(t,e),1)}function fu(t,e){return qn(vu(t,e),vt)}function pu(t,e,n){return n=n===J?1:Sa(n),qn(vu(t,e),n)}function hu(t,e){return"function"==typeof e&&tf(t)?o(t,e):cl(t,ji(e))}function du(t,e){return"function"==typeof e&&tf(t)?u(t,e):sl(t,ji(e))}function gu(t,e,n,r){t=Vu(t)?t:cc(t),n=n&&!r?Sa(n):0;var i=t.length;return n<0&&(n=Is(i+n,0)),wa(t)?n<=i&&t.indexOf(e,n)>-1:!!i&&y(t,e,n)>-1}function vu(t,e){var n=tf(t)?f:rr;return n(t,ji(e,3))}function mu(t,e,n,r){return null==t?[]:(tf(e)||(e=null==e?[]:[e]),n=r?J:n,tf(n)||(n=null==n?[]:[n]),sr(t,e,n))}function yu(t,e,n){var r=tf(t)?h:_,i=arguments.length<3;return r(t,ji(e,4),n,i,cl)}function bu(t,e,n){var r=tf(t)?d:_,i=arguments.length<3;return r(t,ji(e,4),n,i,sl)}function xu(t,e){var n=tf(t)?c:Rn;return e=ji(e,3),n(t,function(t,n,r){return!e(t,n,r)})}function _u(t){var e=Vu(t)?t:cc(t),n=e.length;return n>0?e[vr(0,n-1)]:J}function wu(t,e,n){var r=-1,i=Ea(t),o=i.length,u=o-1;for(e=(n?$i(t,e,n):e===J)?1:wn(Sa(e),0,o);++r<e;){var a=vr(r,u),c=i[a];i[a]=i[r],i[r]=c}return i.length=e,i}function Cu(t){return wu(t,xt)}function ku(t){if(null==t)return 0;if(Vu(t)){var e=t.length;return e&&wa(t)?M(t):e}if(sa(t)){var n=Oi(t);if(n==Nt||n==qt)return t.size}return Ka(t).length}function Tu(t,e,n){var r=tf(t)?g:_r;return n&&$i(t,e,n)&&(e=J),r(t,ji(e,3))}function ju(t,e){if("function"!=typeof e)throw new ss(X);return t=Sa(t),function(){if(--t<1)return e.apply(this,arguments)}}function Au(t,e,n){return e=n?J:e,e=t&&null==e?t.length:e,bi(t,it,J,J,J,J,e)}function Eu(t,e){var n;if("function"!=typeof e)throw new ss(X);return t=Sa(t),function(){return--t>0&&(n=e.apply(this,arguments)),t<=1&&(e=J),n}}function Su(t,e,n){e=n?J:e;var r=bi(t,tt,J,J,J,J,J,e);return r.placeholder=Su.placeholder,r}function Nu(t,e,n){e=n?J:e;var r=bi(t,et,J,J,J,J,J,e);return r.placeholder=Nu.placeholder,r}function Du(t,e,n){function r(e){var n=p,r=h;return p=h=J,y=e,g=t.apply(r,n)}function i(t){return y=t,v=Ns(a,e),b?r(t):g}function o(t){var n=t-m,r=t-y,i=e-n;return x?Ws(i,d-r):i}function u(t){var n=t-m,r=t-y;return!m||n>=e||n<0||x&&r>=d}function a(){var t=Bl();return u(t)?c(t):void(v=Ns(a,o(t)))}function c(t){return ks(v),v=J,_&&p?r(t):(p=h=J,g)}function s(){v!==J&&ks(v),m=y=0,p=h=v=J}function l(){return v===J?g:c(Bl())}function f(){var t=Bl(),n=u(t);if(p=arguments,h=this,m=t,n){if(v===J)return i(m);if(x)return ks(v),v=Ns(a,e),r(m)}return v===J&&(v=Ns(a,e)),g}var p,h,d,g,v,m=0,y=0,b=!1,x=!1,_=!0;if("function"!=typeof t)throw new ss(X);return e=Da(e)||0,ca(n)&&(b=!!n.leading,x="maxWait"in n,d=x?Is(Da(n.maxWait)||0,e):d,_="trailing"in n?!!n.trailing:_),f.cancel=s,f.flush=l,f}function Ou(t){return bi(t,ut)}function Lu(t,e){if("function"!=typeof t||e&&"function"!=typeof e)throw new ss(X);var n=function(){var r=arguments,i=e?e.apply(this,r):r[0],o=n.cache;if(o.has(i))return o.get(i);var u=t.apply(this,r);return n.cache=o.set(i,u),u};return n.cache=new(Lu.Cache||Fe),n}function Ru(t){if("function"!=typeof t)throw new ss(X);return function(){return!t.apply(this,arguments)}}function qu(t){return Eu(2,t)}function Hu(t,e){if("function"!=typeof t)throw new ss(X);return e=Is(e===J?t.length-1:Sa(e),0),function(){for(var r=arguments,i=-1,o=Is(r.length-e,0),u=Array(o);++i<o;)u[i]=r[e+i];switch(e){case 0:return t.call(this,u);case 1:return t.call(this,r[0],u);case 2:return t.call(this,r[0],r[1],u)}var a=Array(e+1);for(i=-1;++i<e;)a[i]=r[i];return a[e]=u,n(t,this,a)}}function Pu(t,e){if("function"!=typeof t)throw new ss(X);return e=e===J?0:Is(Sa(e),0),Hu(function(r){var i=r[e],o=Pr(r,0,e);return i&&p(o,i),n(t,this,o)})}function Iu(t,e,n){var r=!0,i=!0;if("function"!=typeof t)throw new ss(X);return ca(n)&&(r="leading"in n?!!n.leading:r,i="trailing"in n?!!n.trailing:i),Du(t,e,{leading:r,maxWait:e,trailing:i})}function Wu(t){return Au(t,1)}function Fu(t,e){return e=null==e?Ic:e,Vl(e,t)}function Mu(){if(!arguments.length)return[];var t=arguments[0];return tf(t)?t:[t]}function $u(t){return Cn(t,!1,!0)}function Bu(t,e){return Cn(t,!1,!0,e)}function zu(t){return Cn(t,!0,!0)}function Ju(t,e){return Cn(t,!0,!0,e)}function Uu(t,e){return t===e||t!==t&&e!==e}function Ku(t){return Yu(t)&&ds.call(t,"callee")&&(!Ss.call(t,"callee")||ms.call(t)==Ct)}function Xu(t){return sa(t)&&ms.call(t)==Ft}function Vu(t){return null!=t&&aa(gl(t))&&!oa(t)}function Yu(t){return sa(t)&&Vu(t)}function Gu(t){return t===!0||t===!1||sa(t)&&ms.call(t)==Tt}function Zu(t){return sa(t)&&ms.call(t)==jt}function Qu(t){return!!t&&1===t.nodeType&&sa(t)&&!ya(t)}function ta(t){if(Vu(t)&&(tf(t)||wa(t)||oa(t.splice)||Ku(t)||ef(t)))return!t.length;if(sa(t)){var e=Oi(t);if(e==Nt||e==qt)return!t.size}for(var n in t)if(ds.call(t,n))return!1;return!(Zs&&Ka(t).length)}function ea(t,e){return Yn(t,e)}function na(t,e,n){n="function"==typeof n?n:J;var r=n?n(t,e):J;return r===J?Yn(t,e,n):!!r}function ra(t){return!!sa(t)&&(ms.call(t)==At||"string"==typeof t.message&&"string"==typeof t.name)}function ia(t){return"number"==typeof t&&qs(t)}function oa(t){var e=ca(t)?ms.call(t):"";return e==Et||e==St}function ua(t){return"number"==typeof t&&t==Sa(t)}function aa(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=mt}function ca(t){var e=typeof t;return!!t&&("object"==e||"function"==e)}function sa(t){return!!t&&"object"==typeof t}function la(t){return sa(t)&&Oi(t)==Nt}function fa(t,e){return t===e||Zn(t,e,Ai(e))}function pa(t,e,n){return n="function"==typeof n?n:J,Zn(t,e,Ai(e),n)}function ha(t){return ma(t)&&t!=+t}function da(t){if(!ca(t))return!1;var e=oa(t)||H(t)?bs:we;return e.test(to(t))}function ga(t){return null===t}function va(t){return null==t}function ma(t){return"number"==typeof t||sa(t)&&ms.call(t)==Dt}function ya(t){if(!sa(t)||ms.call(t)!=Ot||H(t))return!1;var e=Ni(t);if(null===e)return!0;var n=ds.call(e,"constructor")&&e.constructor;return"function"==typeof n&&n instanceof n&&hs.call(n)==vs}function ba(t){return ca(t)&&ms.call(t)==Rt}function xa(t){return ua(t)&&t>=-mt&&t<=mt}function _a(t){return sa(t)&&Oi(t)==qt}function wa(t){return"string"==typeof t||!tf(t)&&sa(t)&&ms.call(t)==Ht}function Ca(t){return"symbol"==typeof t||sa(t)&&ms.call(t)==Pt}function ka(t){return sa(t)&&aa(t.length)&&!!xn[ms.call(t)]}function Ta(t){return t===J}function ja(t){return sa(t)&&Oi(t)==It}function Aa(t){return sa(t)&&ms.call(t)==Wt}function Ea(t){if(!t)return[];if(Vu(t))return wa(t)?$(t):Yr(t);if(As&&t[As])return P(t[As]());var e=Oi(t),n=e==Nt?I:e==qt?F:cc;return n(t)}function Sa(t){if(!t)return 0===t?t:0;if(t=Da(t),t===vt||t===-vt){var e=t<0?-1:1;return e*yt}var n=t%1;return t===t?n?t-n:t:0}function Na(t){return t?wn(Sa(t),0,xt):0}function Da(t){if("number"==typeof t)return t;if(Ca(t))return bt;if(ca(t)){var e=oa(t.valueOf)?t.valueOf():t;t=ca(e)?e+"":e}if("string"!=typeof t)return 0===t?t:+t;t=t.replace(pe,"");var n=_e.test(t);return n||Ce.test(t)?En(t.slice(2),n?2:8):xe.test(t)?bt:+t}function Oa(t){return Gr(t,Xa(t))}function La(t){return wn(Sa(t),-mt,mt)}function Ra(t){return null==t?"":jr(t)}function qa(t,e){var n=Tn(t);return e?fn(n,e):n}function Ha(t,e){return v(t,ji(e,3),In,!0)}function Pa(t,e){return v(t,ji(e,3),Wn,!0)}function Ia(t,e){return null==t?t:ll(t,ji(e),Xa)}function Wa(t,e){return null==t?t:fl(t,ji(e),Xa)}function Fa(t,e){return t&&In(t,ji(e))}function Ma(t,e){return t&&Wn(t,ji(e))}function $a(t){return null==t?[]:Fn(t,Ka(t))}function Ba(t){return null==t?[]:Fn(t,Xa(t))}function za(t,e,n){var r=null==t?J:Mn(t,e);return r===J?n:r}function Ja(t,e){return null!=t&&Ri(t,e,zn)}function Ua(t,e){return null!=t&&Ri(t,e,Jn)}function Ka(t){var e=Ui(t);if(!e&&!Vu(t))return tr(t);var n=Ii(t),r=!!n,i=n||[],o=i.length;for(var u in t)!zn(t,u)||r&&("length"==u||Mi(u,o))||e&&"constructor"==u||i.push(u);return i}function Xa(t){for(var e=-1,n=Ui(t),r=er(t),i=r.length,o=Ii(t),u=!!o,a=o||[],c=a.length;++e<i;){var s=r[e];u&&("length"==s||Mi(s,c))||"constructor"==s&&(n||!ds.call(t,s))||a.push(s)}return a}function Va(t,e){var n={};return e=ji(e,3),In(t,function(t,r,i){n[e(t,r,i)]=t}),n}function Ya(t,e){var n={};return e=ji(e,3),In(t,function(t,r,i){n[r]=e(t,r,i)}),n}function Ga(t,e){return e=ji(e),fr(t,function(t,n){return!e(t,n)})}function Za(t,e){return null==t?{}:fr(t,ji(e))}function Qa(t,e,n){e=Bi(e,t)?[e]:Hr(e);var r=-1,i=e.length;for(i||(t=J,i=1);++r<i;){var o=null==t?J:t[Qi(e[r])];o===J&&(r=i,o=n),t=oa(o)?o.call(t):o}return t}function tc(t,e,n){return null==t?t:br(t,e,n)}function ec(t,e,n,r){return r="function"==typeof r?r:J,null==t?t:br(t,e,n,r)}function nc(t){return T(t,Ka(t))}function rc(t){return T(t,Xa(t))}function ic(t,e,n){var r=tf(t)||ka(t);if(e=ji(e,4),null==n)if(r||ca(t)){var i=t.constructor;n=r?tf(t)?new i:[]:oa(i)?Tn(Ni(t)):{}}else n={};return(r?o:In)(t,function(t,r,i){return e(n,t,r,i)}),n}function oc(t,e){return null==t||Er(t,e)}function uc(t,e,n){return null==t?t:Sr(t,e,qr(n))}function ac(t,e,n,r){return r="function"==typeof r?r:J,null==t?t:Sr(t,e,qr(n),r)}function cc(t){return t?A(t,Ka(t)):[]}function sc(t){return null==t?[]:A(t,Xa(t))}function lc(t,e,n){return n===J&&(n=e,e=J),n!==J&&(n=Da(n),n=n===n?n:0),e!==J&&(e=Da(e),e=e===e?e:0),wn(Da(t),e,n)}function fc(t,e,n){return e=Da(e)||0,n===J?(n=e,e=0):n=Da(n)||0,t=Da(t),Un(t,e,n)}function pc(t,e,n){if(n&&"boolean"!=typeof n&&$i(t,e,n)&&(e=n=J),n===J&&("boolean"==typeof e?(n=e,e=J):"boolean"==typeof t&&(n=t,t=J)),t===J&&e===J?(t=0,e=1):(t=Da(t)||0,e===J?(e=t,t=0):e=Da(e)||0),t>e){var r=t;t=e,e=r}if(n||t%1||e%1){var i=Ms();return Ws(t+i*(e-t+An("1e-"+((i+"").length-1))),e)}return vr(t,e)}function hc(t){return jf(Ra(t).toLowerCase())}function dc(t){return t=Ra(t),t&&t.replace(Te,O).replace(hn,"")}function gc(t,e,n){t=Ra(t),e=jr(e);var r=t.length;return n=n===J?r:wn(Sa(n),0,r),n-=e.length,n>=0&&t.indexOf(e,n)==n}function vc(t){return t=Ra(t),t&&re.test(t)?t.replace(ee,L):t}function mc(t){return t=Ra(t),t&&fe.test(t)?t.replace(le,"\\$&"):t}function yc(t,e,n){t=Ra(t),e=Sa(e);var r=e?M(t):0;if(!e||r>=e)return t;var i=(e-r)/2;return hi(Ls(i),n)+t+hi(Os(i),n)}function bc(t,e,n){t=Ra(t),e=Sa(e);var r=e?M(t):0;return e&&r<e?t+hi(e-r,n):t}function xc(t,e,n){t=Ra(t),e=Sa(e);var r=e?M(t):0;return e&&r<e?hi(e-r,n)+t:t}function _c(t,e,n){return n||null==e?e=0:e&&(e=+e),t=Ra(t).replace(pe,""),Fs(t,e||(be.test(t)?16:10))}function wc(t,e,n){return e=(n?$i(t,e,n):e===J)?1:Sa(e),yr(Ra(t),e)}function Cc(){var t=arguments,e=Ra(t[0]);return t.length<3?e:$s.call(e,t[1],t[2])}function kc(t,e,n){return n&&"number"!=typeof n&&$i(t,e,n)&&(e=n=J),(n=n===J?xt:n>>>0)?(t=Ra(t),t&&("string"==typeof e||null!=e&&!ba(e))&&(e=jr(e),""==e&&vn.test(t))?Pr($(t),0,n):zs.call(t,e,n)):[]}function Tc(t,e,n){return t=Ra(t),n=wn(Sa(n),0,t.length),t.lastIndexOf(jr(e),n)==n}function jc(t,e,n){var r=Ee.templateSettings;n&&$i(t,e,n)&&(e=J),t=Ra(t),e=af({},e,r,an);var i,o,u=af({},e.imports,r.imports,an),a=Ka(u),c=A(u,a),s=0,l=e.interpolate||je,f="__p += '",p=cs((e.escape||je).source+"|"+l.source+"|"+(l===ue?me:je).source+"|"+(e.evaluate||je).source+"|$","g"),h="//# sourceURL="+("sourceURL"in e?e.sourceURL:"lodash.templateSources["+ ++bn+"]")+"\n";t.replace(p,function(e,n,r,u,a,c){return r||(r=u),f+=t.slice(s,c).replace(Ae,R),n&&(i=!0,f+="' +\n__e("+n+") +\n'"),a&&(o=!0,f+="';\n"+a+";\n__p += '"),r&&(f+="' +\n((__t = ("+r+")) == null ? '' : __t) +\n'"),s=c+e.length,e}),f+="';\n";var d=e.variable;d||(f="with (obj) {\n"+f+"\n}\n"),f=(o?f.replace(Gt,""):f).replace(Zt,"$1").replace(Qt,"$1;"),f="function("+(d||"obj")+") {\n"+(d?"":"obj || (obj = {});\n")+"var __t, __p = ''"+(i?", __e = _.escape":"")+(o?", __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\n":";\n")+f+"return __p\n}";var g=Af(function(){return Function(a,h+"return "+f).apply(J,c)});if(g.source=f,ra(g))throw g;return g}function Ac(t){return Ra(t).toLowerCase()}function Ec(t){return Ra(t).toUpperCase()}function Sc(t,e,n){if(t=Ra(t),t&&(n||e===J))return t.replace(pe,"");if(!t||!(e=jr(e)))return t;var r=$(t),i=$(e),o=E(r,i),u=S(r,i)+1;return Pr(r,o,u).join("")}function Nc(t,e,n){if(t=Ra(t),t&&(n||e===J))return t.replace(de,"");if(!t||!(e=jr(e)))return t;var r=$(t),i=S(r,$(e))+1;return Pr(r,0,i).join("")}function Dc(t,e,n){if(t=Ra(t),t&&(n||e===J))return t.replace(he,"");if(!t||!(e=jr(e)))return t;var r=$(t),i=E(r,$(e));return Pr(r,i).join("")}function Oc(t,e){var n=st,r=lt;if(ca(e)){var i="separator"in e?e.separator:i;n="length"in e?Sa(e.length):n,r="omission"in e?jr(e.omission):r;
+}t=Ra(t);var o=t.length;if(vn.test(t)){var u=$(t);o=u.length}if(n>=o)return t;var a=n-M(r);if(a<1)return r;var c=u?Pr(u,0,a).join(""):t.slice(0,a);if(i===J)return c+r;if(u&&(a+=c.length-a),ba(i)){if(t.slice(a).search(i)){var s,l=c;for(i.global||(i=cs(i.source,Ra(ye.exec(i))+"g")),i.lastIndex=0;s=i.exec(l);)var f=s.index;c=c.slice(0,f===J?a:f)}}else if(t.indexOf(jr(i),a)!=a){var p=c.lastIndexOf(i);p>-1&&(c=c.slice(0,p))}return c+r}function Lc(t){return t=Ra(t),t&&ne.test(t)?t.replace(te,B):t}function Rc(t,e,n){return t=Ra(t),e=n?J:e,e===J&&(e=mn.test(t)?gn:ge),t.match(e)||[]}function qc(t){var e=t?t.length:0,r=ji();return t=e?f(t,function(t){if("function"!=typeof t[1])throw new ss(X);return[r(t[0]),t[1]]}):[],Hu(function(r){for(var i=-1;++i<e;){var o=t[i];if(n(o[0],this,r))return n(o[1],this,r)}})}function Hc(t){return kn(Cn(t,!0))}function Pc(t){return function(){return t}}function Ic(t){return t}function Wc(t){return Qn("function"==typeof t?t:Cn(t,!0))}function Fc(t){return ir(Cn(t,!0))}function Mc(t,e){return or(t,Cn(e,!0))}function $c(t,e,n){var r=Ka(e),i=Fn(e,r);null!=n||ca(e)&&(i.length||!r.length)||(n=e,e=t,t=this,i=Fn(e,Ka(e)));var u=!(ca(n)&&"chain"in n&&!n.chain),a=oa(t);return o(i,function(n){var r=e[n];t[n]=r,a&&(t.prototype[n]=function(){var e=this.__chain__;if(u||e){var n=t(this.__wrapped__),i=n.__actions__=Yr(this.__actions__);return i.push({func:r,args:arguments,thisArg:t}),n.__chain__=e,n}return r.apply(t,p([this.value()],arguments))})}),t}function Bc(){return Hn._===this&&(Hn._=ys),this}function zc(){}function Jc(t){return t=Sa(t),Hu(function(e){return cr(e,t)})}function Uc(t){return Bi(t)?pr(Qi(t)):hr(t)}function Kc(t){return function(e){return null==t?J:Mn(t,e)}}function Xc(t,e){if(t=Sa(t),t<1||t>mt)return[];var n=xt,r=Ws(t,xt);e=ji(e),t-=xt;for(var i=k(r,e);++n<t;)e(n);return i}function Vc(t){return tf(t)?f(t,Qi):Ca(t)?[t]:Yr(yl(t))}function Yc(t){var e=++gs;return Ra(t)+e}function Gc(t){return t&&t.length?On(t,Ic,Bn):J}function Zc(t,e){return t&&t.length?On(t,ji(e),Bn):J}function Qc(t){return x(t,Ic)}function ts(t,e){return x(t,ji(e))}function es(t){return t&&t.length?On(t,Ic,nr):J}function ns(t,e){return t&&t.length?On(t,ji(e),nr):J}function rs(t){return t&&t.length?C(t,Ic):0}function is(t,e){return t&&t.length?C(t,ji(e)):0}N=N?Pn.defaults({},N,Pn.pick(Hn,yn)):Hn;var os=N.Date,us=N.Error,as=N.Math,cs=N.RegExp,ss=N.TypeError,ls=N.Array.prototype,fs=N.Object.prototype,ps=N.String.prototype,hs=N.Function.prototype.toString,ds=fs.hasOwnProperty,gs=0,vs=hs.call(Object),ms=fs.toString,ys=Hn._,bs=cs("^"+hs.call(ds).replace(le,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),xs=Dn?N.Buffer:J,_s=N.Reflect,ws=N.Symbol,Cs=N.Uint8Array,ks=N.clearTimeout,Ts=_s?_s.enumerate:J,js=Object.getOwnPropertySymbols,As="symbol"==typeof(As=ws&&ws.iterator)?As:J,Es=Object.create,Ss=fs.propertyIsEnumerable,Ns=N.setTimeout,Ds=ls.splice,Os=as.ceil,Ls=as.floor,Rs=Object.getPrototypeOf,qs=N.isFinite,Hs=ls.join,Ps=Object.keys,Is=as.max,Ws=as.min,Fs=N.parseInt,Ms=as.random,$s=ps.replace,Bs=ls.reverse,zs=ps.split,Js=Ei(N,"DataView"),Us=Ei(N,"Map"),Ks=Ei(N,"Promise"),Xs=Ei(N,"Set"),Vs=Ei(N,"WeakMap"),Ys=Ei(Object,"create"),Gs=Vs&&new Vs,Zs=!Ss.call({valueOf:1},"valueOf"),Qs={},tl=to(Js),el=to(Us),nl=to(Ks),rl=to(Xs),il=to(Vs),ol=ws?ws.prototype:J,ul=ol?ol.valueOf:J,al=ol?ol.toString:J;Ee.templateSettings={escape:ie,evaluate:oe,interpolate:ue,variable:"",imports:{_:Ee}},Ee.prototype=Se.prototype,Ee.prototype.constructor=Ee,Ne.prototype=Tn(Se.prototype),Ne.prototype.constructor=Ne,De.prototype=Tn(Se.prototype),De.prototype.constructor=De,qe.prototype=Ys?Ys(null):fs,Fe.prototype.clear=Me,Fe.prototype["delete"]=$e,Fe.prototype.get=Be,Fe.prototype.has=ze,Fe.prototype.set=Je,Ue.prototype.push=Xe,Ve.prototype.clear=Ye,Ve.prototype["delete"]=Ge,Ve.prototype.get=Ze,Ve.prototype.has=Qe,Ve.prototype.set=tn;var cl=ei(In),sl=ei(Wn,!0),ll=ni(),fl=ni(!0);Ts&&!Ss.call({valueOf:1},"valueOf")&&(er=function(t){return P(Ts(t))});var pl=Gs?function(t,e){return Gs.set(t,e),t}:Ic,hl=Xs&&1/F(new Xs([,-0]))[1]==vt?function(t){return new Xs(t)}:zc,dl=Gs?function(t){return Gs.get(t)}:zc,gl=pr("length");js||(Di=function(){return[]});var vl=js?function(t){for(var e=[];t;)p(e,Di(t)),t=Ni(t);return e}:Di;(Js&&Oi(new Js(new ArrayBuffer(1)))!=Mt||Us&&Oi(new Us)!=Nt||Ks&&Oi(Ks.resolve())!=Lt||Xs&&Oi(new Xs)!=qt||Vs&&Oi(new Vs)!=It)&&(Oi=function(t){var e=ms.call(t),n=e==Ot?t.constructor:J,r=n?to(n):J;if(r)switch(r){case tl:return Mt;case el:return Nt;case nl:return Lt;case rl:return qt;case il:return It}return e});var ml=function(){var t=0,e=0;return function(n,r){var i=Bl(),o=pt-(i-e);if(e=i,o>0){if(++t>=ft)return n}else t=0;return pl(n,r)}}(),yl=Lu(function(t){var e=[];return Ra(t).replace(se,function(t,n,r,i){e.push(r?i.replace(ve,"$1"):n||t)}),e}),bl=Hu(function(t,e){return Yu(t)?Sn(t,qn(e,1,Yu,!0)):[]}),xl=Hu(function(t,e){var n=_o(e);return Yu(n)&&(n=J),Yu(t)?Sn(t,qn(e,1,Yu,!0),ji(n)):[]}),_l=Hu(function(t,e){var n=_o(e);return Yu(n)&&(n=J),Yu(t)?Sn(t,qn(e,1,Yu,!0),J,n):[]}),wl=Hu(function(t){var e=f(t,Rr);return e.length&&e[0]===t[0]?Kn(e):[]}),Cl=Hu(function(t){var e=_o(t),n=f(t,Rr);return e===_o(n)?e=J:n.pop(),n.length&&n[0]===t[0]?Kn(n,ji(e)):[]}),kl=Hu(function(t){var e=_o(t),n=f(t,Rr);return e===_o(n)?e=J:n.pop(),n.length&&n[0]===t[0]?Kn(n,J,e):[]}),Tl=Hu(ko),jl=Hu(function(t,e){e=qn(e,1);var n=t?t.length:0,r=dn(t,e);return gr(t,f(e,function(t){return Mi(t,n)?+t:t}).sort(Ur)),r}),Al=Hu(function(t){return Ar(qn(t,1,Yu,!0))}),El=Hu(function(t){var e=_o(t);return Yu(e)&&(e=J),Ar(qn(t,1,Yu,!0),ji(e))}),Sl=Hu(function(t){var e=_o(t);return Yu(e)&&(e=J),Ar(qn(t,1,Yu,!0),J,e)}),Nl=Hu(function(t,e){return Yu(t)?Sn(t,e):[]}),Dl=Hu(function(t){return Or(c(t,Yu))}),Ol=Hu(function(t){var e=_o(t);return Yu(e)&&(e=J),Or(c(t,Yu),ji(e))}),Ll=Hu(function(t){var e=_o(t);return Yu(e)&&(e=J),Or(c(t,Yu),J,e)}),Rl=Hu(Uo),ql=Hu(function(t){var e=t.length,n=e>1?t[e-1]:J;return n="function"==typeof n?(t.pop(),n):J,Ko(t,n)}),Hl=Hu(function(t){t=qn(t,1);var e=t.length,n=e?t[0]:0,r=this.__wrapped__,i=function(e){return dn(e,t)};return!(e>1||this.__actions__.length)&&r instanceof De&&Mi(n)?(r=r.slice(n,+n+(e?1:0)),r.__actions__.push({func:Zo,args:[i],thisArg:J}),new Ne(r,this.__chain__).thru(function(t){return e&&!t.length&&t.push(J),t})):this.thru(i)}),Pl=Qr(function(t,e,n){ds.call(t,n)?++t[n]:t[n]=1}),Il=Qr(function(t,e,n){ds.call(t,n)?t[n].push(e):t[n]=[e]}),Wl=Hu(function(t,e,r){var i=-1,o="function"==typeof e,u=Bi(e),a=Vu(t)?Array(t.length):[];return cl(t,function(t){var c=o?e:u&&null!=t?t[e]:J;a[++i]=c?n(c,t,r):Vn(t,e,r)}),a}),Fl=Qr(function(t,e,n){t[n]=e}),Ml=Qr(function(t,e,n){t[n?0:1].push(e)},function(){return[[],[]]}),$l=Hu(function(t,e){if(null==t)return[];var n=e.length;return n>1&&$i(t,e[0],e[1])?e=[]:n>2&&$i(e[0],e[1],e[2])&&(e=[e[0]]),e=1==e.length&&tf(e[0])?e[0]:qn(e,1,Fi),sr(t,e,[])}),Bl=os.now,zl=Hu(function(t,e,n){var r=G;if(n.length){var i=W(n,Si(zl));r|=nt}return bi(t,r,e,n,i)}),Jl=Hu(function(t,e,n){var r=G|Z;if(n.length){var i=W(n,Si(Jl));r|=nt}return bi(e,r,t,n,i)}),Ul=Hu(function(t,e){return jn(t,1,e)}),Kl=Hu(function(t,e,n){return jn(t,Da(e)||0,n)});Lu.Cache=Fe;var Xl=Hu(function(t,e){e=1==e.length&&tf(e[0])?f(e[0],j(ji())):f(qn(e,1,Fi),j(ji()));var r=e.length;return Hu(function(i){for(var o=-1,u=Ws(i.length,r);++o<u;)i[o]=e[o].call(this,i[o]);return n(t,this,i)})}),Vl=Hu(function(t,e){var n=W(e,Si(Vl));return bi(t,nt,J,e,n)}),Yl=Hu(function(t,e){var n=W(e,Si(Yl));return bi(t,rt,J,e,n)}),Gl=Hu(function(t,e){return bi(t,ot,J,J,J,qn(e,1))}),Zl=vi(Bn),Ql=vi(function(t,e){return t>=e}),tf=Array.isArray,ef=xs?function(t){return t instanceof xs}:Pc(!1),nf=vi(nr),rf=vi(function(t,e){return t<=e}),of=ti(function(t,e){if(Zs||Ui(e)||Vu(e))return void Gr(e,Ka(e),t);for(var n in e)ds.call(e,n)&&sn(t,n,e[n])}),uf=ti(function(t,e){if(Zs||Ui(e)||Vu(e))return void Gr(e,Xa(e),t);for(var n in e)sn(t,n,e[n])}),af=ti(function(t,e,n,r){Gr(e,Xa(e),t,r)}),cf=ti(function(t,e,n,r){Gr(e,Ka(e),t,r)}),sf=Hu(function(t,e){return dn(t,qn(e,1))}),lf=Hu(function(t){return t.push(J,an),n(af,J,t)}),ff=Hu(function(t){return t.push(J,Yi),n(vf,J,t)}),pf=li(function(t,e,n){t[e]=n},Pc(Ic)),hf=li(function(t,e,n){ds.call(t,e)?t[e].push(n):t[e]=[n]},ji),df=Hu(Vn),gf=ti(function(t,e,n){ur(t,e,n)}),vf=ti(function(t,e,n,r){ur(t,e,n,r)}),mf=Hu(function(t,e){return null==t?{}:(e=f(qn(e,1),Qi),lr(t,Sn(ki(t),e)))}),yf=Hu(function(t,e){return null==t?{}:lr(t,f(qn(e,1),Qi))}),bf=oi(function(t,e,n){return e=e.toLowerCase(),t+(n?hc(e):e)}),xf=oi(function(t,e,n){return t+(n?"-":"")+e.toLowerCase()}),_f=oi(function(t,e,n){return t+(n?" ":"")+e.toLowerCase()}),wf=ii("toLowerCase"),Cf=oi(function(t,e,n){return t+(n?"_":"")+e.toLowerCase()}),kf=oi(function(t,e,n){return t+(n?" ":"")+jf(e)}),Tf=oi(function(t,e,n){return t+(n?" ":"")+e.toUpperCase()}),jf=ii("toUpperCase"),Af=Hu(function(t,e){try{return n(t,J,e)}catch(r){return ra(r)?r:new us(r)}}),Ef=Hu(function(t,e){return o(qn(e,1),function(e){e=Qi(e),t[e]=zl(t[e],t)}),t}),Sf=ci(),Nf=ci(!0),Df=Hu(function(t,e){return function(n){return Vn(n,t,e)}}),Of=Hu(function(t,e){return function(n){return Vn(t,n,e)}}),Lf=pi(f),Rf=pi(a),qf=pi(g),Hf=gi(),Pf=gi(!0),If=fi(function(t,e){return t+e}),Wf=yi("ceil"),Ff=fi(function(t,e){return t/e}),Mf=yi("floor"),$f=fi(function(t,e){return t*e}),Bf=yi("round"),zf=fi(function(t,e){return t-e});return Ee.after=ju,Ee.ary=Au,Ee.assign=of,Ee.assignIn=uf,Ee.assignInWith=af,Ee.assignWith=cf,Ee.at=sf,Ee.before=Eu,Ee.bind=zl,Ee.bindAll=Ef,Ee.bindKey=Jl,Ee.castArray=Mu,Ee.chain=Yo,Ee.chunk=no,Ee.compact=ro,Ee.concat=io,Ee.cond=qc,Ee.conforms=Hc,Ee.constant=Pc,Ee.countBy=Pl,Ee.create=qa,Ee.curry=Su,Ee.curryRight=Nu,Ee.debounce=Du,Ee.defaults=lf,Ee.defaultsDeep=ff,Ee.defer=Ul,Ee.delay=Kl,Ee.difference=bl,Ee.differenceBy=xl,Ee.differenceWith=_l,Ee.drop=oo,Ee.dropRight=uo,Ee.dropRightWhile=ao,Ee.dropWhile=co,Ee.fill=so,Ee.filter=au,Ee.flatMap=lu,Ee.flatMapDeep=fu,Ee.flatMapDepth=pu,Ee.flatten=po,Ee.flattenDeep=ho,Ee.flattenDepth=go,Ee.flip=Ou,Ee.flow=Sf,Ee.flowRight=Nf,Ee.fromPairs=vo,Ee.functions=$a,Ee.functionsIn=Ba,Ee.groupBy=Il,Ee.initial=bo,Ee.intersection=wl,Ee.intersectionBy=Cl,Ee.intersectionWith=kl,Ee.invert=pf,Ee.invertBy=hf,Ee.invokeMap=Wl,Ee.iteratee=Wc,Ee.keyBy=Fl,Ee.keys=Ka,Ee.keysIn=Xa,Ee.map=vu,Ee.mapKeys=Va,Ee.mapValues=Ya,Ee.matches=Fc,Ee.matchesProperty=Mc,Ee.memoize=Lu,Ee.merge=gf,Ee.mergeWith=vf,Ee.method=Df,Ee.methodOf=Of,Ee.mixin=$c,Ee.negate=Ru,Ee.nthArg=Jc,Ee.omit=mf,Ee.omitBy=Ga,Ee.once=qu,Ee.orderBy=mu,Ee.over=Lf,Ee.overArgs=Xl,Ee.overEvery=Rf,Ee.overSome=qf,Ee.partial=Vl,Ee.partialRight=Yl,Ee.partition=Ml,Ee.pick=yf,Ee.pickBy=Za,Ee.property=Uc,Ee.propertyOf=Kc,Ee.pull=Tl,Ee.pullAll=ko,Ee.pullAllBy=To,Ee.pullAllWith=jo,Ee.pullAt=jl,Ee.range=Hf,Ee.rangeRight=Pf,Ee.rearg=Gl,Ee.reject=xu,Ee.remove=Ao,Ee.rest=Hu,Ee.reverse=Eo,Ee.sampleSize=wu,Ee.set=tc,Ee.setWith=ec,Ee.shuffle=Cu,Ee.slice=So,Ee.sortBy=$l,Ee.sortedUniq=Ho,Ee.sortedUniqBy=Po,Ee.split=kc,Ee.spread=Pu,Ee.tail=Io,Ee.take=Wo,Ee.takeRight=Fo,Ee.takeRightWhile=Mo,Ee.takeWhile=$o,Ee.tap=Go,Ee.throttle=Iu,Ee.thru=Zo,Ee.toArray=Ea,Ee.toPairs=nc,Ee.toPairsIn=rc,Ee.toPath=Vc,Ee.toPlainObject=Oa,Ee.transform=ic,Ee.unary=Wu,Ee.union=Al,Ee.unionBy=El,Ee.unionWith=Sl,Ee.uniq=Bo,Ee.uniqBy=zo,Ee.uniqWith=Jo,Ee.unset=oc,Ee.unzip=Uo,Ee.unzipWith=Ko,Ee.update=uc,Ee.updateWith=ac,Ee.values=cc,Ee.valuesIn=sc,Ee.without=Nl,Ee.words=Rc,Ee.wrap=Fu,Ee.xor=Dl,Ee.xorBy=Ol,Ee.xorWith=Ll,Ee.zip=Rl,Ee.zipObject=Xo,Ee.zipObjectDeep=Vo,Ee.zipWith=ql,Ee.entries=nc,Ee.entriesIn=rc,Ee.extend=uf,Ee.extendWith=af,$c(Ee,Ee),Ee.add=If,Ee.attempt=Af,Ee.camelCase=bf,Ee.capitalize=hc,Ee.ceil=Wf,Ee.clamp=lc,Ee.clone=$u,Ee.cloneDeep=zu,Ee.cloneDeepWith=Ju,Ee.cloneWith=Bu,Ee.deburr=dc,Ee.divide=Ff,Ee.endsWith=gc,Ee.eq=Uu,Ee.escape=vc,Ee.escapeRegExp=mc,Ee.every=uu,Ee.find=cu,Ee.findIndex=lo,Ee.findKey=Ha,Ee.findLast=su,Ee.findLastIndex=fo,Ee.findLastKey=Pa,Ee.floor=Mf,Ee.forEach=hu,Ee.forEachRight=du,Ee.forIn=Ia,Ee.forInRight=Wa,Ee.forOwn=Fa,Ee.forOwnRight=Ma,Ee.get=za,Ee.gt=Zl,Ee.gte=Ql,Ee.has=Ja,Ee.hasIn=Ua,Ee.head=mo,Ee.identity=Ic,Ee.includes=gu,Ee.indexOf=yo,Ee.inRange=fc,Ee.invoke=df,Ee.isArguments=Ku,Ee.isArray=tf,Ee.isArrayBuffer=Xu,Ee.isArrayLike=Vu,Ee.isArrayLikeObject=Yu,Ee.isBoolean=Gu,Ee.isBuffer=ef,Ee.isDate=Zu,Ee.isElement=Qu,Ee.isEmpty=ta,Ee.isEqual=ea,Ee.isEqualWith=na,Ee.isError=ra,Ee.isFinite=ia,Ee.isFunction=oa,Ee.isInteger=ua,Ee.isLength=aa,Ee.isMap=la,Ee.isMatch=fa,Ee.isMatchWith=pa,Ee.isNaN=ha,Ee.isNative=da,Ee.isNil=va,Ee.isNull=ga,Ee.isNumber=ma,Ee.isObject=ca,Ee.isObjectLike=sa,Ee.isPlainObject=ya,Ee.isRegExp=ba,Ee.isSafeInteger=xa,Ee.isSet=_a,Ee.isString=wa,Ee.isSymbol=Ca,Ee.isTypedArray=ka,Ee.isUndefined=Ta,Ee.isWeakMap=ja,Ee.isWeakSet=Aa,Ee.join=xo,Ee.kebabCase=xf,Ee.last=_o,Ee.lastIndexOf=wo,Ee.lowerCase=_f,Ee.lowerFirst=wf,Ee.lt=nf,Ee.lte=rf,Ee.max=Gc,Ee.maxBy=Zc,Ee.mean=Qc,Ee.meanBy=ts,Ee.min=es,Ee.minBy=ns,Ee.multiply=$f,Ee.nth=Co,Ee.noConflict=Bc,Ee.noop=zc,Ee.now=Bl,Ee.pad=yc,Ee.padEnd=bc,Ee.padStart=xc,Ee.parseInt=_c,Ee.random=pc,Ee.reduce=yu,Ee.reduceRight=bu,Ee.repeat=wc,Ee.replace=Cc,Ee.result=Qa,Ee.round=Bf,Ee.runInContext=z,Ee.sample=_u,Ee.size=ku,Ee.snakeCase=Cf,Ee.some=Tu,Ee.sortedIndex=No,Ee.sortedIndexBy=Do,Ee.sortedIndexOf=Oo,Ee.sortedLastIndex=Lo,Ee.sortedLastIndexBy=Ro,Ee.sortedLastIndexOf=qo,Ee.startCase=kf,Ee.startsWith=Tc,Ee.subtract=zf,Ee.sum=rs,Ee.sumBy=is,Ee.template=jc,Ee.times=Xc,Ee.toInteger=Sa,Ee.toLength=Na,Ee.toLower=Ac,Ee.toNumber=Da,Ee.toSafeInteger=La,Ee.toString=Ra,Ee.toUpper=Ec,Ee.trim=Sc,Ee.trimEnd=Nc,Ee.trimStart=Dc,Ee.truncate=Oc,Ee.unescape=Lc,Ee.uniqueId=Yc,Ee.upperCase=Tf,Ee.upperFirst=jf,Ee.each=hu,Ee.eachRight=du,Ee.first=mo,$c(Ee,function(){var t={};return In(Ee,function(e,n){ds.call(Ee.prototype,n)||(t[n]=e)}),t}(),{chain:!1}),Ee.VERSION=U,o(["bind","bindKey","curry","curryRight","partial","partialRight"],function(t){Ee[t].placeholder=Ee}),o(["drop","take"],function(t,e){De.prototype[t]=function(n){var r=this.__filtered__;if(r&&!e)return new De(this);n=n===J?1:Is(Sa(n),0);var i=this.clone();return r?i.__takeCount__=Ws(n,i.__takeCount__):i.__views__.push({size:Ws(n,xt),type:t+(i.__dir__<0?"Right":"")}),i},De.prototype[t+"Right"]=function(e){return this.reverse()[t](e).reverse()}}),o(["filter","map","takeWhile"],function(t,e){var n=e+1,r=n==ht||n==gt;De.prototype[t]=function(t){var e=this.clone();return e.__iteratees__.push({iteratee:ji(t,3),type:n}),e.__filtered__=e.__filtered__||r,e}}),o(["head","last"],function(t,e){var n="take"+(e?"Right":"");De.prototype[t]=function(){return this[n](1).value()[0]}}),o(["initial","tail"],function(t,e){var n="drop"+(e?"":"Right");De.prototype[t]=function(){return this.__filtered__?new De(this):this[n](1)}}),De.prototype.compact=function(){return this.filter(Ic)},De.prototype.find=function(t){return this.filter(t).head()},De.prototype.findLast=function(t){return this.reverse().find(t)},De.prototype.invokeMap=Hu(function(t,e){return"function"==typeof t?new De(this):this.map(function(n){return Vn(n,t,e)})}),De.prototype.reject=function(t){return t=ji(t,3),this.filter(function(e){return!t(e)})},De.prototype.slice=function(t,e){t=Sa(t);var n=this;return n.__filtered__&&(t>0||e<0)?new De(n):(t<0?n=n.takeRight(-t):t&&(n=n.drop(t)),e!==J&&(e=Sa(e),n=e<0?n.dropRight(-e):n.take(e-t)),n)},De.prototype.takeRightWhile=function(t){return this.reverse().takeWhile(t).reverse()},De.prototype.toArray=function(){return this.take(xt)},In(De.prototype,function(t,e){var n=/^(?:filter|find|map|reject)|While$/.test(e),r=/^(?:head|last)$/.test(e),i=Ee[r?"take"+("last"==e?"Right":""):e],o=r||/^find/.test(e);i&&(Ee.prototype[e]=function(){var e=this.__wrapped__,u=r?[1]:arguments,a=e instanceof De,c=u[0],s=a||tf(e),l=function(t){var e=i.apply(Ee,p([t],u));return r&&f?e[0]:e};s&&n&&"function"==typeof c&&1!=c.length&&(a=s=!1);var f=this.__chain__,h=!!this.__actions__.length,d=o&&!f,g=a&&!h;if(!o&&s){e=g?e:new De(this);var v=t.apply(e,u);return v.__actions__.push({func:Zo,args:[l],thisArg:J}),new Ne(v,f)}return d&&g?t.apply(this,u):(v=this.thru(l),d?r?v.value()[0]:v.value():v)})}),o(["pop","push","shift","sort","splice","unshift"],function(t){var e=ls[t],n=/^(?:push|sort|unshift)$/.test(t)?"tap":"thru",r=/^(?:pop|shift)$/.test(t);Ee.prototype[t]=function(){var t=arguments;if(r&&!this.__chain__){var i=this.value();return e.apply(tf(i)?i:[],t)}return this[n](function(n){return e.apply(tf(n)?n:[],t)})}}),In(De.prototype,function(t,e){var n=Ee[e];if(n){var r=n.name+"",i=Qs[r]||(Qs[r]=[]);i.push({name:e,func:n})}}),Qs[si(J,Z).name]=[{name:"wrapper",func:J}],De.prototype.clone=Oe,De.prototype.reverse=Le,De.prototype.value=Re,Ee.prototype.at=Hl,Ee.prototype.chain=Qo,Ee.prototype.commit=tu,Ee.prototype.next=eu,Ee.prototype.plant=ru,Ee.prototype.reverse=iu,Ee.prototype.toJSON=Ee.prototype.valueOf=Ee.prototype.value=ou,As&&(Ee.prototype[As]=nu),Ee}var J,U="4.11.2",K=200,X="Expected a function",V="__lodash_hash_undefined__",Y="__lodash_placeholder__",G=1,Z=2,Q=4,tt=8,et=16,nt=32,rt=64,it=128,ot=256,ut=512,at=1,ct=2,st=30,lt="...",ft=150,pt=16,ht=1,dt=2,gt=3,vt=1/0,mt=9007199254740991,yt=1.7976931348623157e308,bt=NaN,xt=4294967295,_t=xt-1,wt=xt>>>1,Ct="[object Arguments]",kt="[object Array]",Tt="[object Boolean]",jt="[object Date]",At="[object Error]",Et="[object Function]",St="[object GeneratorFunction]",Nt="[object Map]",Dt="[object Number]",Ot="[object Object]",Lt="[object Promise]",Rt="[object RegExp]",qt="[object Set]",Ht="[object String]",Pt="[object Symbol]",It="[object WeakMap]",Wt="[object WeakSet]",Ft="[object ArrayBuffer]",Mt="[object DataView]",$t="[object Float32Array]",Bt="[object Float64Array]",zt="[object Int8Array]",Jt="[object Int16Array]",Ut="[object Int32Array]",Kt="[object Uint8Array]",Xt="[object Uint8ClampedArray]",Vt="[object Uint16Array]",Yt="[object Uint32Array]",Gt=/\b__p \+= '';/g,Zt=/\b(__p \+=) '' \+/g,Qt=/(__e\(.*?\)|\b__t\)) \+\n'';/g,te=/&(?:amp|lt|gt|quot|#39|#96);/g,ee=/[&<>"'`]/g,ne=RegExp(te.source),re=RegExp(ee.source),ie=/<%-([\s\S]+?)%>/g,oe=/<%([\s\S]+?)%>/g,ue=/<%=([\s\S]+?)%>/g,ae=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,ce=/^\w*$/,se=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]/g,le=/[\\^$.*+?()[\]{}|]/g,fe=RegExp(le.source),pe=/^\s+|\s+$/g,he=/^\s+/,de=/\s+$/,ge=/[a-zA-Z0-9]+/g,ve=/\\(\\)?/g,me=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,ye=/\w*$/,be=/^0x/i,xe=/^[-+]0x[0-9a-f]+$/i,_e=/^0b[01]+$/i,we=/^\[object .+?Constructor\]$/,Ce=/^0o[0-7]+$/i,ke=/^(?:0|[1-9]\d*)$/,Te=/[\xc0-\xd6\xd8-\xde\xdf-\xf6\xf8-\xff]/g,je=/($^)/,Ae=/['\n\r\u2028\u2029\\]/g,Ee="\\ud800-\\udfff",Se="\\u0300-\\u036f\\ufe20-\\ufe23",Ne="\\u20d0-\\u20f0",De="\\u2700-\\u27bf",Oe="a-z\\xdf-\\xf6\\xf8-\\xff",Le="\\xac\\xb1\\xd7\\xf7",Re="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",qe="\\u2000-\\u206f",He=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",Pe="A-Z\\xc0-\\xd6\\xd8-\\xde",Ie="\\ufe0e\\ufe0f",We=Le+Re+qe+He,Fe="['’]",Me="["+Ee+"]",$e="["+We+"]",Be="["+Se+Ne+"]",ze="\\d+",Je="["+De+"]",Ue="["+Oe+"]",Ke="[^"+Ee+We+ze+De+Oe+Pe+"]",Xe="\\ud83c[\\udffb-\\udfff]",Ve="(?:"+Be+"|"+Xe+")",Ye="[^"+Ee+"]",Ge="(?:\\ud83c[\\udde6-\\uddff]){2}",Ze="[\\ud800-\\udbff][\\udc00-\\udfff]",Qe="["+Pe+"]",tn="\\u200d",en="(?:"+Ue+"|"+Ke+")",nn="(?:"+Qe+"|"+Ke+")",rn="(?:"+Fe+"(?:d|ll|m|re|s|t|ve))?",on="(?:"+Fe+"(?:D|LL|M|RE|S|T|VE))?",un=Ve+"?",an="["+Ie+"]?",cn="(?:"+tn+"(?:"+[Ye,Ge,Ze].join("|")+")"+an+un+")*",sn=an+un+cn,ln="(?:"+[Je,Ge,Ze].join("|")+")"+sn,fn="(?:"+[Ye+Be+"?",Be,Ge,Ze,Me].join("|")+")",pn=RegExp(Fe,"g"),hn=RegExp(Be,"g"),dn=RegExp(Xe+"(?="+Xe+")|"+fn+sn,"g"),gn=RegExp([Qe+"?"+Ue+"+"+rn+"(?="+[$e,Qe,"$"].join("|")+")",nn+"+"+on+"(?="+[$e,Qe+en,"$"].join("|")+")",Qe+"?"+en+"+"+rn,Qe+"+"+on,ze,ln].join("|"),"g"),vn=RegExp("["+tn+Ee+Se+Ne+Ie+"]"),mn=/[a-z][A-Z]|[A-Z]{2,}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,yn=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","Reflect","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],bn=-1,xn={};xn[$t]=xn[Bt]=xn[zt]=xn[Jt]=xn[Ut]=xn[Kt]=xn[Xt]=xn[Vt]=xn[Yt]=!0,xn[Ct]=xn[kt]=xn[Ft]=xn[Tt]=xn[Mt]=xn[jt]=xn[At]=xn[Et]=xn[Nt]=xn[Dt]=xn[Ot]=xn[Rt]=xn[qt]=xn[Ht]=xn[It]=!1;var _n={};_n[Ct]=_n[kt]=_n[Ft]=_n[Mt]=_n[Tt]=_n[jt]=_n[$t]=_n[Bt]=_n[zt]=_n[Jt]=_n[Ut]=_n[Nt]=_n[Dt]=_n[Ot]=_n[Rt]=_n[qt]=_n[Ht]=_n[Pt]=_n[Kt]=_n[Xt]=_n[Vt]=_n[Yt]=!0,_n[At]=_n[Et]=_n[It]=!1;var wn={"À":"A","Á":"A","Â":"A","Ã":"A","Ä":"A","Å":"A","à":"a","á":"a","â":"a","ã":"a","ä":"a","å":"a","Ç":"C","ç":"c","Ð":"D","ð":"d","È":"E","É":"E","Ê":"E","Ë":"E","è":"e","é":"e","ê":"e","ë":"e","Ì":"I","Í":"I","Î":"I","Ï":"I","ì":"i","í":"i","î":"i","ï":"i","Ñ":"N","ñ":"n","Ò":"O","Ó":"O","Ô":"O","Õ":"O","Ö":"O","Ø":"O","ò":"o","ó":"o","ô":"o","õ":"o","ö":"o","ø":"o","Ù":"U","Ú":"U","Û":"U","Ü":"U","ù":"u","ú":"u","û":"u","ü":"u","Ý":"Y","ý":"y","ÿ":"y","Æ":"Ae","æ":"ae","Þ":"Th","þ":"th","ß":"ss"},Cn={"&":"&","<":"<",">":">",'"':""","'":"'","`":"`"},kn={"&":"&","<":"<",">":">",""":'"',"'":"'","`":"`"},Tn={"function":!0,object:!0},jn={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},An=parseFloat,En=parseInt,Sn=Tn[typeof exports]&&exports&&!exports.nodeType?exports:J,Nn=Tn[typeof module]&&module&&!module.nodeType?module:J,Dn=Nn&&Nn.exports===Sn?Sn:J,On=N(Sn&&Nn&&"object"==typeof global&&global),Ln=N(Tn[typeof self]&&self),Rn=N(Tn[typeof window]&&window),qn=N(Tn[typeof this]&&this),Hn=On||Rn!==(qn&&qn.window)&&Rn||Ln||qn||Function("return this")(),Pn=z();(Rn||Ln||{})._=Pn,"function"==typeof define&&"object"==typeof define.amd&&define.amd?define(function(){return Pn}):Sn&&Nn?(Dn&&((Nn.exports=Pn)._=Pn),Sn._=Pn):Hn._=Pn}.call(this);var Josh=Josh||{};Josh.Version="0.2.10",function(t){Josh.Keys={Special:{Backspace:8,Tab:9,Enter:13,Pause:19,CapsLock:20,Escape:27,Space:32,PageUp:33,PageDown:34,End:35,Home:36,Left:37,Up:38,Right:39,Down:40,Insert:45,Delete:46}},Josh.ReadLine=function(e){function n(t,e,n){t.addEventListener?t.addEventListener(e,n,!1):t.attachEvent&&t.attachEvent("on"+e,n)}function r(t,e,n){t.removeEventListener?t.removeEventListener(e,n,!1):t.detachEvent&&t.detachEvent("on"+e,n)}function i(t){var e=t.keyCode||t.charCode,n=String.fromCharCode(e);return{code:e,character:n,shift:t.shiftKey,control:t.controlKey,alt:t.altKey,isChar:!0}}function o(t){var e={modifier:"default",code:t.keyCode};return t.metaKey||t.altKey?e.modifier="meta":t.ctrlKey&&(e.modifier="control"),t["char"]&&(e.code=t["char"].charCodeAt(0)),e}function u(t){return vt?void gt.push(t):void a(t)}function a(t){ut.log("calling: "+t.name+", previous: "+it),pt&&"cmdKeyPress"!=t.name&&"cmdReverseSearch"!=t.name&&(pt=!1,"cmdEsc"==t.name&&(rt=null),rt&&(rt.text&&(dt=rt.cursoridx,ht=rt.text,at.applySearch()),rt=null),et&&et()),!pt&&ct.isinkill()&&"cmdKill"!=t.name.substr(0,7)&&ct.commit(),it=t.name,t()}function c(t){vt=!0,t(s)}function s(){var t=gt.shift();return t?(a(t),void s()):void(vt=!1)}function l(){}function f(){}function p(){0!=dt&&(--dt,ht=B(ht,dt,dt+1),I())}function h(){X&&c(function(t){X(bt.getLine(),function(e){e&&(ht=z(ht,dt,e),R(dt+e.length)),ot=!0,t()})})}function d(){if(ht){var t=ht;at.accept(t),ht="",dt=0,V&&c(function(e){V(t,function(t){t&&(ht=t,dt=ht.length),Y&&Y(bt.getLine()),e()})})}}function g(){R(ht.length)}function v(){R(0)}function m(){0!=dt&&R(dt-1)}function y(){dt!=ht.length&&R(dt+1)}function b(){0!=dt&&R(F())}function x(){dt!=ht.length&&R(M())}function _(){at.hasPrev()&&W(at.prev)}function w(){at.hasNext()&&W(at.next)}function C(){W(at.top)}function k(){W(at.end)}function T(){return 0==ht.length&&Z?void Z():void(dt!=ht.length&&(ht=B(ht,dt,dt+1),I()))}function j(){G&&G()}function A(){ct.append(ht.substr(dt)),ht=ht.substr(0,dt),I()}function E(){if(0!=ht.length&&dt!=ht.length){var t=M();if(t==ht.length-1)return A();ct.append(ht.substring(dt,t)),ht=B(ht,dt,t),I()}}function S(){if(0!=dt){var t=dt;dt=F(),ct.prepend(ht.substring(dt,t)),ht=B(ht,dt,t),I()}}function N(){var t=ct.yank();t&&(ht=z(ht,dt,t),R(dt+t.length))}function D(){var t=ct.lastyanklength();if(t){var e=ct.rotate();if(e){var n=dt;dt-=t,ht=B(ht,dt,n),ht=z(ht,dt,e),R(dt+e.length)}}}function O(){Q?Q():I()}function L(){pt?(rt||(rt={term:""}),P()):(pt=!0,tt&&tt(),nt&&nt({}))}function R(t){dt=t,I()}function q(t){ht=z(ht,dt,t),++dt,I()}function H(t){rt||(rt={term:""}),rt.term+=t,P()}function P(){ut.log("searchtext: "+rt.term);var t=at.search(rt.term);null!=t&&(rt=t,ut.log("match: "+t),nt&&nt(t))}function I(){Y&&Y(bt.getLine())}function W(t){at.update(ht),ht=t(),R(ht.length)}function F(){var t=dt-1;if(t<0)return 0;for(var e=!1,n=t;n>0;n--){var r=$(ht[n]);if(e&&!r)return n+1;e=r}return 0}function M(){if(0==ht.length)return 0;var t=dt+1;if(t>=ht.length)return ht.length-1;for(var e=!1,n=t;n<ht.length;n++){var r=$(ht[n]);if(e&&!r)return n;e=r}return ht.length-1}function $(t){if(void 0==t)return!1;var e=t.charCodeAt(0);return e>=48&&e<=57||e>=65&&e<=90||e>=97&&e<=122}function B(t,e,n){if(t.length<=1||t.length<=n-e)return"";if(0==e)return t.substr(n);var r=t.substr(0,e),i=t.substr(n);return r+i}function z(t,e,n){if(0==e)return n+t;if(e>=t.length)return t+n;var r=t.substr(0,e),i=t.substr(e);return r+n+i}function J(){lt.onkeydown=function(t){if(t=t||window.event,!ft||16==t.keyCode||17==t.keyCode||18==t.keyCode||91==t.keyCode)return!0;ut.log("key: "+t.keyCode);var e,n=yt["default"][t.keyCode];return!t.ctrlKey||t.shiftKey||t.altKey||t.metaKey?!t.altKey&&!t.metaKey||t.ctrlKey||t.shiftKey||(e=yt.meta[t.keyCode],e&&(n=e)):(e=yt.control[t.keyCode],e&&(n=e)),!n||(u(n),t.preventDefault(),t.stopPropagation(),t.cancelBubble=!0,!1)},lt.onkeypress=function(t){if(!ft)return!0;var e=i(t);return!(0==e.code||t.defaultPrevented||t.metaKey||t.altKey||t.ctrlKey)&&(u(function(){pt?H(e.character):q(e.character)}),t.preventDefault(),t.stopPropagation(),t.cancelBubble=!0,!1)}}e=e||{};var U,K,X,V,Y,G,Z,Q,tt,et,nt,rt,it,ot,ut=e.console||(Josh.Debug&&t.console?t.console:{log:function(){}}),at=e.history||new Josh.History,ct=e.killring||new Josh.KillRing,st=!!e.element,lt=e.element||t,ft=!1,pt=!1,ht="",dt=0,gt=[],vt=!1,mt={complete:h,done:d,noop:l,history_top:C,history_end:k,history_next:w,history_previous:_,end:g,home:v,left:m,right:y,cancel:j,"delete":T,backspace:p,kill_eof:A,kill_wordback:S,kill_wordforward:E,yank:N,clear:O,search:L,wordback:b,wordforward:x,yank_rotate:D},yt={"default":{8:p,9:h,13:d,27:f,33:C,34:k,35:g,36:v,37:m,38:_,39:y,40:w,46:T,10:l,19:l,45:l},control:{65:v,66:m,67:j,68:T,69:g,70:y,80:_,78:w,75:A,89:N,76:O,82:L},meta:{8:S,66:b,68:E,70:x,89:D}},bt={isActive:function(){return ft},activate:function(){ft=!0,U&&U()},deactivate:function(){ft=!1,K&&K()},bind:function(t,e){var n=o(t),r=mt[e];r&&yt[n.modifier][n.code]},unbind:function(t){var e=o(t);delete yt[e.modifier][e.code]},attach:function(t){lt&&bt.detach(),ut.log("attaching"),ut.log(t),lt=t,st=!0,n(lt,"focus",bt.activate),n(lt,"blur",bt.deactivate),J()},detach:function(){r(lt,"focus",bt.activate),r(lt,"blur",bt.deactivate),lt=null,st=!1},onActivate:function(t){U=t},onDeactivate:function(t){K=t},onChange:function(t){Y=t},onClear:function(t){Q=t},onEnter:function(t){V=t},onCompletion:function(t){X=t},onCancel:function(t){G=t},onEOT:function(t){Z=t},onSearchStart:function(t){tt=t},onSearchEnd:function(t){et=t},onSearchChange:function(t){nt=t},getLine:function(){return{text:ht,cursor:dt}},setLine:function(t){ht=t.text,dt=t.cursor,I()}};return st?bt.attach(lt):J(),bt}}(this);var Josh=Josh||{};!function(t){Josh.History=function(e){function n(){s&&s.setItem(l,JSON.stringify(o))}function r(){return a=u,c="",o[u]}e=e||{};var i=Josh.Debug&&t.console?t.console:{log:function(){}},o=e.history||[""],u=e.cursor||0,a=u,c="",s=e.storage||t.localStorage,l=e.key||"josh.history";if(s){var f=s.getItem(l);f?(o=JSON.parse(f),a=u=o.length-1):n()}return{update:function(t){i.log("updating history to "+t),o[u]=t,n()},accept:function(t){i.log("accepting history "+t);var e=o.length-1;t&&(u==e?(i.log("we're at the end already, update last position"),o[u]=t):o[e]?(i.log("appending to end"),o.push(t)):(i.log("we're not at the end, but the end was blank, so update last position"),o[e]=t),o.push("")),a=u=o.length-1,n()},items:function(){return o.slice(0,o.length-1)},clear:function(){o=[o[o.length-1]],n()},hasNext:function(){return u<o.length-1},hasPrev:function(){return u>0},prev:function(){return--u,r()},next:function(){return++u,r()},top:function(){return u=0,r()},end:function(){return u=o.length-1,r()},search:function(t){if(!t&&!c)return null;var e=o.length;t==c&&(a--,e--),t||(t=c),c=t;for(var n=0;n<e;n++){a<0&&(a=o.length-1);var r=o[a].indexOf(t);if(r!=-1)return{text:o[a],cursoridx:r,term:t};a--}return null},applySearch:function(){return c?(i.log("setting history to position"+a+"("+u+"): "+o[a]),u=a,o[u]):null}}}}(this);var Josh=Josh||{};!function(t){Josh.KillRing=function(e){e=e||{};var n=Josh.Debug&&t.console?t.console:{log:function(){}},r=e.ring||[],i=e.cursor||0,o=!1,u=!1;0==r.length?i=-1:i>=r.length&&(i=r.length-1);var a={isinkill:function(){return o},lastyanklength:function(){return u?r[i].length:0},append:function(t){u=!1,t&&(0!=r.length&&o||r.push(""),i=r.length-1,n.log("appending: "+t),o=!0,r[i]+=t)},prepend:function(t){u=!1,t&&(0!=r.length&&o||r.push(""),i=r.length-1,n.log("prepending: "+t),o=!0,r[i]=t+r[i])},commit:function(){n.log("committing"),u=!1,o=!1},yank:function(){return a.commit(),0==r.length?null:(u=!0,r[i])},rotate:function(){return u&&0!=r.length?(--i,i<0&&(i=r.length-1),a.yank()):null},items:function(){return r.slice(0)},clear:function(){r=[],i=-1,u=!1,_uncommited=!1}};return a}}(this);var Josh=Josh||{};!function(t,e,n){e.fn.josh_caretTo=function(t){return this.queue(function(e){if(this.createTextRange){var n=this.createTextRange();n.move("character",t),n.select()}else null!==this.selectionStart&&this.setSelectionRange(t,t);e()})},e.fn.josh_caretPosition=function(){var t=this.get(0);if(t.createTextRange){var e=t.createTextRange();return e.moveStart("character",-t.value.length),e.text.length}return null!==t.selectionStart?t.selectionStart:0};var r=Josh.History(),i=new Josh.KillRing;Josh.Input=function(o){o=o||{};var u,a=o.console||(Josh.Debug&&t.console?t.console:{log:function(){}}),c="#"+o.id,s=o.blinktime||500,l=!1,f=!1,p=!1,h=o.history||r,d=o.killring||i,g={templates:{span:n.template('<span class="input"><span class="left"/><span class="cursor"/><span class="right"/></span>')},history:h,killring:d};return e(document).ready(function(){function r(t){var e=t?t.text:"";u=e,v.val(e),v.josh_caretTo(t.cursor)}function i(t){var e=t.text||"";u=e;var r=t.cursor||0,i=n.escape(e.substr(0,r)).replace(/ /g," "),o=e.substr(r,1),a=n.escape(e.substr(r+1)).replace(/ /g," ");x.html(i),o?w.text(o).css("textDecoration","underline"):w.html(" ").css("textDecoration","underline"),_.html(a)}function o(){l&&t.setTimeout(function(){l&&(f=!f,f?w.css("textDecoration","underline"):w.css("textDecoration",""),o())},s)}var v=e(c),m=v.get(0),y=new Josh.ReadLine({history:h,killring:d,console:a});g.readline=y,y.attach(m);var b=null;if(p=v.is("input"))a.log(c+" is an input"),y.onChange(r),v.click(function(){var t=y.getLine();t.cursor=v.josh_caretPosition(),y.setLine(t)}),b=function(){setTimeout(function(){r(y.getLine())},0)};else{a.log(c+" is a non-input element"),v.html(g.templates.span()),"undefined"==typeof v.attr("tabindex")&&v.attr("tabindex",0);var x=v.find(".left"),_=v.find(".right"),w=v.find(".cursor");b=function(){o()},y.onChange(i)}y.unbind({keyCode:Josh.Keys.Special.Tab}),y.unbind({"char":"R",ctrlKey:!0}),y.onActivate(function(){l=!0,b()}),y.onDeactivate(function(){l=!1,u&&h.accept(u)})}),g}}(this,$,_);var Josh=Josh||{};!function(t,e,n){Josh.PathHandler=function(e,r){
+function i(t,e,n,r){return f.log("calling command and path completion handler w/ cmd: '"+t+"', arg: '"+e+"'"),e||(e=t),"."==e[0]||"/"==e[0]?o(t,e,n,r):h.completion(t,e,n,r)}function o(t,e,n,r){if(f.log("completing '"+e+"'"),!e)return f.log("completing on current"),u(d.current,"",r);if("/"==e[e.length-1])return f.log("completing children w/o partial"),d.getNode(e,function(t){return t?u(t,"",r):(f.log("no node for path"),r())});var i="",o=e.lastIndexOf("/"),a=e.substr(0,o+1);return i=e.substr(o+1),".."===i||"."===i?r({completion:"/",suggestions:[]}):(f.log("completing children via parent '"+a+"' w/ partial '"+i+"'"),d.getNode(a,function(t){return t?u(t,i,function(t){return r(t&&""==t.completion&&1==t.suggestions.length?{completion:"/",suggestions:[]}:t)}):(f.log("no node for parent path"),r())}))}function u(t,e,r){d.getChildNodes(t,function(t){r(p.bestMatch(e,n.map(t,function(t){return t.name})))})}function a(t,e,n){d.getNode(e[0],function(t){return t?(d.current=t,n()):n(p.templates.not_found({cmd:"cd",path:e[0]}))})}function c(t,e,n){n(p.templates.pwd({node:d.current}))}function s(t,e,n){return f.log("ls"),e&&e[0]?d.getNode(e[0],function(t){l(t,e[0],n)}):l(d.current,d.current.path,n)}function l(t,e,n){return t?d.getChildNodes(t,function(e){f.log("finish render: "+t.name),n(p.templates.ls({nodes:e}))}):n(p.templates.not_found({cmd:"ls",path:e}))}r=r||{};var f=r.console||(Josh.Debug&&t.console?t.console:{log:function(){}}),p=e;p.templates.not_found=n.template("<div><%=cmd%>: <%=path%>: No such file or directory</div>"),p.templates.ls=n.template("<div><% _.each(nodes, function(node) { %><span><%=node.name%> </span><% }); %></div>"),p.templates.pwd=n.template("<div><%=node.path %> </div>"),p.templates.prompt=n.template("<%= node.path %> $");var h=p.getCommandHandler("_default"),d={current:null,pathCompletionHandler:o,commandAndPathCompletionHandler:i,getNode:function(t,e){e()},getChildNodes:function(t,e){e([])},getPrompt:function(){return p.templates.prompt({node:d.current})}};return p.setCommandHandler("ls",{exec:s,completion:o}),p.setCommandHandler("pwd",{exec:c,completion:o}),p.setCommandHandler("cd",{exec:a,completion:o}),p.setCommandHandler("_default",{exec:h.exec,completion:i}),p.onNewPrompt(function(t){t(d.getPrompt())}),d}}(this,$,_);var Josh=Josh||{};!function(t,e,n){Josh.Shell=function(r){function i(t){return"#"+t}function o(){return n.chain(E).keys().filter(function(t){return"_"!=t[0]}).value()}function u(){j&&t.setTimeout(function(){j&&(A=!A,A?e(i(w)+" .input .cursor").css("textDecoration","underline"):e(i(w)+" .input .cursor").css("textDecoration",""),u())},C)}function a(t){return n.filter(t.split(/\s+/),function(t){return t})}function c(t){return E[t]||E._default}function s(t,n){return t&&e(i(w)).after(t),e(i(w)+" .input .cursor").css("textDecoration",""),e(i(w)).removeAttr("id"),e(i(x)).append(D.templates.input_cmd({id:w})),g?g(function(t){return D.setPrompt(t),n()}):n()}function l(){y.log("activating shell"),h||(h=e(i(x))),d||(d=e(i(_))),0==e(i(w)).length&&h.append(D.templates.input_cmd({id:w})),D.refresh(),j=!0,u(),g&&g(function(t){D.setPrompt(t)}),f&&f()}r=r||{};var f,p,h,d,g,v,m,y=r.console||(Josh.Debug&&t.console?t.console:{log:function(){}}),b=r.prompt||"jsh$",x=r.shell_view_id||"shell-view",_=r.shell_panel_id||"shell-panel",w=r.input_id||"shell-cli",C=r.blinktime||500,k=r.history||new Josh.History,T=r.readline||new Josh.ReadLine({history:k,console:y}),j=!1,A=!1,E={clear:{exec:function(t,n,r){e(i(w)).parent().empty(),r()}},help:{exec:function(t,e,n){n(D.templates.help({commands:o()}))}},history:{exec:function(t,e,n){return"-c"==e[0]?(k.clear(),void n()):void n(D.templates.history({items:k.items()}))}},_default:{exec:function(t,e,n){n(D.templates.bad_command({cmd:t}))},completion:function(t,e,n,r){return e||(e=t),r(D.bestMatch(e,D.commands()))}}},S={text:"",cursor:0},N="",D={commands:o,templates:{history:n.template("<div><% _.each(items, function(cmd, i) { %><div><%- i %> <%- cmd %></div><% }); %></div>"),help:n.template("<div><div><strong>Commands:</strong></div><% _.each(commands, function(cmd) { %><div> <%- cmd %></div><% }); %></div>"),bad_command:n.template("<div><strong>Unrecognized command: </strong><%=cmd%></div>"),input_cmd:n.template('<div id="<%- id %>"><span class="prompt"></span> <span class="input"><span class="left"/><span class="cursor"/><span class="right"/></span></div>'),input_search:n.template('<div id="<%- id %>">(reverse-i-search)`<span class="searchterm"></span>\': <span class="input"><span class="left"/><span class="cursor"/><span class="right"/></span></div>'),suggest:n.template("<div><% _.each(suggestions, function(suggestion) { %><div><%- suggestion %></div><% }); %></div>")},isActive:function(){return T.isActive()},activate:function(){return 0==e(i(x)).length?void(j=!1):void T.activate()},deactivate:function(){y.log("deactivating"),j=!1,T.deactivate()},setCommandHandler:function(t,e){E[t]=e},getCommandHandler:function(t){return E[t]},setPrompt:function(t){b=t,j&&D.refresh()},onEOT:function(t){T.onEOT(t)},onCancel:function(t){T.onCancel(t)},onInitialize:function(t){v=t},onActivate:function(t){f=t},onDeactivate:function(t){p=t},onNewPrompt:function(t){g=t},render:function(){var t=S.text||"",r=S.cursor||0;N&&(r=N.cursoridx||0,t=N.text||"",e(i(w)+" .searchterm").text(N.term));var o=n.escape(t.substr(0,r)).replace(/ /g," "),u=t.substr(r,1),a=n.escape(t.substr(r+1)).replace(/ /g," ");e(i(w)+" .prompt").html(b),e(i(w)+" .input .left").html(o),u?e(i(w)+" .input .cursor").text(u).css("textDecoration","underline"):e(i(w)+" .input .cursor").html(" ").css("textDecoration","underline"),e(i(w)+" .input .right").html(a),A=!0,D.scrollToBottom(),y.log('rendered "'+t+'" w/ cursor at '+r)},refresh:function(){e(i(w)).replaceWith(D.templates.input_cmd({id:w})),D.render(),y.log("refreshed "+w)},scrollToBottom:function(){d.animate({scrollTop:h.height()},0)},bestMatch:function(t,e){y.log("bestMatch on partial '"+t+"'");var r={completion:null,suggestions:[]};if(!e||0==e.length)return r;var i="";if(!t){if(1==e.length)return r.completion=e[0],r.suggestions=e,r;if(!n.every(e,function(t){return e[0][0]==t[0]}))return r.suggestions=e,r}for(var o=0;o<e.length;o++){var u=e[o];if(u.slice(0,t.length)==t)if(r.suggestions.push(u),i){if(u.slice(0,i.length)!=i){y.log("find common stem for '"+i+"' and '"+u+"'");for(var a=t.length;a<i.length&&a<u.length;){if(i[a]!=u[a]){i=i.substr(0,a);break}a++}}}else i=u,y.log("initial common:"+i)}return r.completion=i.substr(t.length),r}};return T.onActivate(function(){return!m&&(m=!0,v)?v(l):l()}),T.onDeactivate(function(){p&&p()}),T.onChange(function(t){S=t,D.render()}),T.onClear(function(){E.clear.exec(null,null,function(){s(null,function(){})})}),T.onSearchStart(function(){e(i(w)).replaceWith(D.templates.input_search({id:w})),y.log("started search")}),T.onSearchEnd(function(){e(i(w)).replaceWith(D.templates.input_cmd({id:w})),N=null,D.render(),y.log("ended search")}),T.onSearchChange(function(t){N=t,D.render()}),T.onEnter(function(t,e){y.log("got command: "+t);var n=a(t),r=n[0],i=n.slice(1),o=c(r);return o.exec(r,i,function(t,n){s(t,function(){e(n)})})}),T.onCompletion(function(t,e){if(!t)return e();var n=t.text.substr(0,t.cursor),r=a(n),i=r.shift()||"",o=r.pop()||"";y.log("getting completion handler for "+i);var u=c(i);return u!=E._default&&i&&i==n?(y.log("valid cmd, no args: append space"),e(" ")):u.completion?(y.log("calling completion handler for "+i),u.completion(i,o,t,function(t){return y.log("completion: "+JSON.stringify(t)),t?t.suggestions&&t.suggestions.length>1?s(D.templates.suggest({suggestions:t.suggestions}),function(){e(t.completion)}):e(t.completion):e()})):e()}),D}}(this,$,_);
\ No newline at end of file
diff --git a/xos/tests/ui/karma.conf.views.js b/xos/tests/ui/karma.conf.views.js
index 876c533..2a4d8ad 100644
--- a/xos/tests/ui/karma.conf.views.js
+++ b/xos/tests/ui/karma.conf.views.js
@@ -15,9 +15,8 @@
let viewFiles = fs.readdirSync(viewDir);
let vendorFiles = fs.readdirSync(vendorDir);
-viewFiles = viewFiles.filter(f => f.indexOf('js') >= 0).filter(f => f.match(/^xos[A-Z][a-z]+/)).map(f => `${viewDir}${f}`);
-
-vendorFiles = vendorFiles.filter(f => f.indexOf('js') >= 0).filter(f => f.match(/^xos[A-Z][a-z]+/)).map(f => `${vendorDir}${f}`);
+viewFiles = viewFiles.filter(f => f.indexOf('js') >= 0).filter(f => f.match(/^xos[A-Z]+[a-z]+/)).map(f => `${viewDir}${f}`);
+vendorFiles = vendorFiles.filter(f => f.indexOf('js') >= 0).filter(f => f.match(/^xos[A-Z]+[a-z]+/)).map(f => `${vendorDir}${f}`);
/*eslint-disable*/
@@ -125,7 +124,7 @@
// available browser launchers: https://npmjs.org/browse/keyword/karma-launcher
browsers: [
'PhantomJS',
- //'Chrome'
+ // 'Chrome'
],