163 lines
490 KiB
JavaScript
163 lines
490 KiB
JavaScript
/**
|
||
* almond 0.2.7 Copyright (c) 2011-2012, The Dojo Foundation All Rights Reserved.
|
||
* Available via the MIT or new BSD license.
|
||
* see: http://github.com/jrburke/almond for details
|
||
*/
|
||
|
||
/*!
|
||
* jQuery JavaScript Library v1.8.3
|
||
* http://jquery.com/
|
||
*
|
||
* Includes Sizzle.js
|
||
* http://sizzlejs.com/
|
||
*
|
||
* Copyright 2012 jQuery Foundation and other contributors
|
||
* Released under the MIT license
|
||
* http://jquery.org/license
|
||
*
|
||
* Date: Tue Nov 13 2012 08:20:33 GMT-0500 (Eastern Standard Time)
|
||
*/
|
||
|
||
/*!
|
||
* Sizzle CSS Selector Engine
|
||
* Copyright 2012 jQuery Foundation and other contributors
|
||
* Released under the MIT license
|
||
* http://sizzlejs.com/
|
||
*/
|
||
|
||
/*
|
||
CryptoJS v3.1.2
|
||
code.google.com/p/crypto-js
|
||
(c) 2009-2013 by Jeff Mott. All rights reserved.
|
||
code.google.com/p/crypto-js/wiki/License
|
||
*/
|
||
|
||
/*!
|
||
* EventEmitter v4.2.3 - git.io/ee
|
||
* Oliver Caldwell
|
||
* MIT license
|
||
* @preserve
|
||
*/
|
||
|
||
/*!
|
||
|
||
otr.js v0.2.7 - 2013-10-12
|
||
(c) 2013 - Arlo Breault <arlolra@gmail.com>
|
||
Freely distributed under the MPL v2.0 license.
|
||
|
||
This file is concatenated for the browser.
|
||
Please see: https://github.com/arlolra/otr
|
||
|
||
*/
|
||
|
||
/*
|
||
jed.js
|
||
v0.5.0beta
|
||
|
||
https://github.com/SlexAxton/Jed
|
||
-----------
|
||
A gettext compatible i18n library for modern JavaScript Applications
|
||
|
||
by Alex Sexton - AlexSexton [at] gmail - @SlexAxton
|
||
WTFPL license for use
|
||
Dojo CLA for contributions
|
||
|
||
Jed offers the entire applicable GNU gettext spec'd set of
|
||
functions, but also offers some nicer wrappers around them.
|
||
The api for gettext was written for a language with no function
|
||
overloading, so Jed allows a little more of that.
|
||
|
||
Many thanks to Joshua I. Miller - unrtst@cpan.org - who wrote
|
||
gettext.js back in 2008. I was able to vet a lot of my ideas
|
||
against his. I also made sure Jed passed against his tests
|
||
in order to offer easy upgrades -- jsgettext.berlios.de
|
||
*/
|
||
|
||
// Underscore 1.3.0 was used to port and is licensed
|
||
|
||
/**
|
||
sprintf() for JavaScript 0.7-beta1
|
||
http://www.diveintojavascript.com/projects/javascript-sprintf
|
||
|
||
Copyright (c) Alexandru Marasteanu <alexaholic [at) gmail (dot] com>
|
||
All rights reserved.
|
||
|
||
Redistribution and use in source and binary forms, with or without
|
||
modification, are permitted provided that the following conditions are met:
|
||
* Redistributions of source code must retain the above copyright
|
||
notice, this list of conditions and the following disclaimer.
|
||
* Redistributions in binary form must reproduce the above copyright
|
||
notice, this list of conditions and the following disclaimer in the
|
||
documentation and/or other materials provided with the distribution.
|
||
* Neither the name of sprintf() for JavaScript nor the
|
||
names of its contributors may be used to endorse or promote products
|
||
derived from this software without specific prior written permission.
|
||
|
||
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
|
||
ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
|
||
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
|
||
DISCLAIMED. IN NO EVENT SHALL Alexandru Marasteanu BE LIABLE FOR ANY
|
||
DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
|
||
(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
|
||
LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
|
||
ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
|
||
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||
*/
|
||
|
||
// Underscore.js 1.5.1
|
||
// http://underscorejs.org
|
||
// (c) 2009-2013 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
|
||
// Underscore may be freely distributed under the MIT license.
|
||
|
||
// (c) 2010-2013 Jeremy Ashkenas, DocumentCloud Inc.
|
||
// Backbone may be freely distributed under the MIT license.
|
||
// For all details and documentation:
|
||
// http://backbonejs.org
|
||
|
||
/*! TinySort
|
||
* Copyright (c) 2008-2013 Ron Valstar http://tinysort.sjeiti.com/
|
||
*
|
||
* Dual licensed under the MIT and GPL licenses:
|
||
* http://www.opensource.org/licenses/mit-license.php
|
||
* http://www.gnu.org/licenses/gpl.html
|
||
*/
|
||
|
||
/*
|
||
* A JavaScript implementation of the Secure Hash Algorithm, SHA-1, as defined
|
||
* in FIPS PUB 180-1
|
||
* Version 2.1a Copyright Paul Johnston 2000 - 2002.
|
||
* Other contributors: Greg Holt, Andrew Kepert, Ydnar, Lostinet
|
||
* Distributed under the BSD License
|
||
* See http://pajhome.org.uk/crypt/md5 for details.
|
||
*/
|
||
|
||
/*
|
||
* A JavaScript implementation of the RSA Data Security, Inc. MD5 Message
|
||
* Digest Algorithm, as defined in RFC 1321.
|
||
* Version 2.1 Copyright (C) Paul Johnston 1999 - 2002.
|
||
* Other contributors: Greg Holt, Andrew Kepert, Ydnar, Lostinet
|
||
* Distributed under the BSD License
|
||
* See http://pajhome.org.uk/crypt/md5 for more info.
|
||
*/
|
||
|
||
/*
|
||
This program is distributed under the terms of the MIT license.
|
||
Please see the LICENSE file for details.
|
||
|
||
Copyright 2006-2008, OGG, LLC
|
||
*/
|
||
|
||
/*
|
||
Copyright 2010, François de Metz <francois@2metz.fr>
|
||
*/
|
||
|
||
/*!
|
||
* Converse.js (Web-based XMPP instant messaging client)
|
||
* http://conversejs.org
|
||
*
|
||
* Copyright (c) 2012, Jan-Carel Brand <jc@opkode.com>
|
||
* Dual licensed under the MIT and GPL Licenses
|
||
*/
|
||
|
||
function hex_sha1(e){return binb2hex(core_sha1(str2binb(e),e.length*chrsz))}function b64_sha1(e){return binb2b64(core_sha1(str2binb(e),e.length*chrsz))}function str_sha1(e){return binb2str(core_sha1(str2binb(e),e.length*chrsz))}function hex_hmac_sha1(e,t){return binb2hex(core_hmac_sha1(e,t))}function b64_hmac_sha1(e,t){return binb2b64(core_hmac_sha1(e,t))}function str_hmac_sha1(e,t){return binb2str(core_hmac_sha1(e,t))}function sha1_vm_test(){return hex_sha1("abc")=="a9993e364706816aba3e25717850c26c9cd0d89d"}function core_sha1(e,t){e[t>>5]|=128<<24-t%32,e[(t+64>>9<<4)+15]=t;var n=new Array(80),r=1732584193,i=-271733879,s=-1732584194,o=271733878,u=-1009589776,a,f,l,c,h,p,d,v;for(a=0;a<e.length;a+=16){c=r,h=i,p=s,d=o,v=u;for(f=0;f<80;f++)f<16?n[f]=e[a+f]:n[f]=rol(n[f-3]^n[f-8]^n[f-14]^n[f-16],1),l=safe_add(safe_add(rol(r,5),sha1_ft(f,i,s,o)),safe_add(safe_add(u,n[f]),sha1_kt(f))),u=o,o=s,s=rol(i,30),i=r,r=l;r=safe_add(r,c),i=safe_add(i,h),s=safe_add(s,p),o=safe_add(o,d),u=safe_add(u,v)}return[r,i,s,o,u]}function sha1_ft(e,t,n,r){return e<20?t&n|~t&r:e<40?t^n^r:e<60?t&n|t&r|n&r:t^n^r}function sha1_kt(e){return e<20?1518500249:e<40?1859775393:e<60?-1894007588:-899497514}function core_hmac_sha1(e,t){var n=str2binb(e);n.length>16&&(n=core_sha1(n,e.length*chrsz));var r=new Array(16),i=new Array(16);for(var s=0;s<16;s++)r[s]=n[s]^909522486,i[s]=n[s]^1549556828;var o=core_sha1(r.concat(str2binb(t)),512+t.length*chrsz);return core_sha1(i.concat(o),672)}function safe_add(e,t){var n=(e&65535)+(t&65535),r=(e>>16)+(t>>16)+(n>>16);return r<<16|n&65535}function rol(e,t){return e<<t|e>>>32-t}function str2binb(e){var t=[],n=(1<<chrsz)-1;for(var r=0;r<e.length*chrsz;r+=chrsz)t[r>>5]|=(e.charCodeAt(r/chrsz)&n)<<32-chrsz-r%32;return t}function binb2str(e){var t="",n=(1<<chrsz)-1;for(var r=0;r<e.length*32;r+=chrsz)t+=String.fromCharCode(e[r>>5]>>>32-chrsz-r%32&n);return t}function binb2hex(e){var t=hexcase?"0123456789ABCDEF":"0123456789abcdef",n="";for(var r=0;r<e.length*4;r++)n+=t.charAt(e[r>>2]>>(3-r%4)*8+4&15)+t.charAt(e[r>>2]>>(3-r%4)*8&15);return n}function binb2b64(e){var t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",n="",r,i;for(var s=0;s<e.length*4;s+=3){r=(e[s>>2]>>8*(3-s%4)&255)<<16|(e[s+1>>2]>>8*(3-(s+1)%4)&255)<<8|e[s+2>>2]>>8*(3-(s+2)%4)&255;for(i=0;i<4;i++)s*8+i*6>e.length*32?n+=b64pad:n+=t.charAt(r>>6*(3-i)&63)}return n}var requirejs,require,define;(function(e){function c(e,t){return f.call(e,t)}function h(e,t){var n,r,i,s,o,a,f,l,c,h,p=t&&t.split("/"),d=u.map,v=d&&d["*"]||{};if(e&&e.charAt(0)===".")if(t){p=p.slice(0,p.length-1),e=p.concat(e.split("/"));for(l=0;l<e.length;l+=1){h=e[l];if(h===".")e.splice(l,1),l-=1;else if(h===".."){if(l===1&&(e[2]===".."||e[0]===".."))break;l>0&&(e.splice(l-1,2),l-=2)}}e=e.join("/")}else e.indexOf("./")===0&&(e=e.substring(2));if((p||v)&&d){n=e.split("/");for(l=n.length;l>0;l-=1){r=n.slice(0,l).join("/");if(p)for(c=p.length;c>0;c-=1){i=d[p.slice(0,c).join("/")];if(i){i=i[r];if(i){s=i,o=l;break}}}if(s)break;!a&&v&&v[r]&&(a=v[r],f=l)}!s&&a&&(s=a,o=f),s&&(n.splice(0,o,s),e=n.join("/"))}return e}function p(t,r){return function(){return n.apply(e,l.call(arguments,0).concat([t,r]))}}function d(e){return function(t){return h(t,e)}}function v(e){return function(t){s[e]=t}}function m(n){if(c(o,n)){var r=o[n];delete o[n],a[n]=!0,t.apply(e,r)}if(!c(s,n)&&!c(a,n))throw new Error("No "+n);return s[n]}function g(e){var t,n=e?e.indexOf("!"):-1;return n>-1&&(t=e.substring(0,n),e=e.substring(n+1,e.length)),[t,e]}function y(e){return function(){return u&&u.config&&u.config[e]||{}}}var t,n,r,i,s={},o={},u={},a={},f=Object.prototype.hasOwnProperty,l=[].slice;r=function(e,t){var n,r=g(e),i=r[0];return e=r[1],i&&(i=h(i,t),n=m(i)),i?n&&n.normalize?e=n.normalize(e,d(t)):e=h(e,t):(e=h(e,t),r=g(e),i=r[0],e=r[1],i&&(n=m(i))),{f:i?i+"!"+e:e,n:e,pr:i,p:n}},i={require:function(e){return p(e)},exports:function(e){var t=s[e];return typeof t!="undefined"?t:s[e]={}},module:function(e){return{id:e,uri:"",exports:s[e],config:y(e)}}},t=function(t,n,u,f){var l,h,d,g,y,b=[],w=typeof u,E;f=f||t;if(w==="undefined"||w==="function"){n=!n.length&&u.length?["require","exports","module"]:n;for(y=0;y<n.length;y+=1){g=r(n[y],f),h=g.f;if(h==="require")b[y]=i.require(t);else if(h==="exports")b[y]=i.exports(t),E=!0;else if(h==="module")l=b[y]=i.module(t);else if(c(s,h)||c(o,h)||c(a,h))b[y]=m(h);else{if(!g.p)throw new Error(t+" missing "+h);g.p.load(g.n,p(f,!0),v(h),{}),b[y]=s[h]}}d=u?u.apply(s[t],b):undefined;if(t)if(l&&l.exports!==e&&l.exports!==s[t])s[t]=l.exports;else if(d!==e||!E)s[t]=d}else t&&(s[t]=u)},requirejs=require=n=function(s,o,a,f,l){return typeof s=="string"?i[s]?i[s](o):m(r(s,o).f):(s.splice||(u=s,o.splice?(s=o,o=a,a=null):s=e),o=o||function(){},typeof a=="function"&&(a=f,f=l),f?t(e,s,o,a):setTimeout(function(){t(e,s,o,a)},4),n)},n.config=function(e){return u=e,u.deps&&n(u.deps,u.callback),n},requirejs._defined=s,define=function(e,t,n){t.splice||(n=t,t=[]),!c(s,e)&&!c(o,e)&&(o[e]=[e,t,n])},define.amd={jQuery:!0}})(),define("components/almond/almond.js",function(){}),function(e,t){function _(e){var t=M[e]={};return v.each(e.split(y),function(e,n){t[n]=!0}),t}function H(e,n,r){if(r===t&&e.nodeType===1){var i="data-"+n.replace(P,"-$1").toLowerCase();r=e.getAttribute(i);if(typeof r=="string"){try{r=r==="true"?!0:r==="false"?!1:r==="null"?null:+r+""===r?+r:D.test(r)?v.parseJSON(r):r}catch(s){}v.data(e,n,r)}else r=t}return r}function B(e){var t;for(t in e){if(t==="data"&&v.isEmptyObject(e[t]))continue;if(t!=="toJSON")return!1}return!0}function et(){return!1}function tt(){return!0}function ut(e){return!e||!e.parentNode||e.parentNode.nodeType===11}function at(e,t){do e=e[t];while(e&&e.nodeType!==1);return e}function ft(e,t,n){t=t||0;if(v.isFunction(t))return v.grep(e,function(e,r){var i=!!t.call(e,r,e);return i===n});if(t.nodeType)return v.grep(e,function(e,r){return e===t===n});if(typeof t=="string"){var r=v.grep(e,function(e){return e.nodeType===1});if(it.test(t))return v.filter(t,r,!n);t=v.filter(t,r)}return v.grep(e,function(e,r){return v.inArray(e,t)>=0===n})}function lt(e){var t=ct.split("|"),n=e.createDocumentFragment();if(n.createElement)while(t.length)n.createElement(t.pop());return n}function Lt(e,t){return e.getElementsByTagName(t)[0]||e.appendChild(e.ownerDocument.createElement(t))}function At(e,t){if(t.nodeType!==1||!v.hasData(e))return;var n,r,i,s=v._data(e),o=v._data(t,s),u=s.events;if(u){delete o.handle,o.events={};for(n in u)for(r=0,i=u[n].length;r<i;r++)v.event.add(t,n,u[n][r])}o.data&&(o.data=v.extend({},o.data))}function Ot(e,t){var n;if(t.nodeType!==1)return;t.clearAttributes&&t.clearAttributes(),t.mergeAttributes&&t.mergeAttributes(e),n=t.nodeName.toLowerCase(),n==="object"?(t.parentNode&&(t.outerHTML=e.outerHTML),v.support.html5Clone&&e.innerHTML&&!v.trim(t.innerHTML)&&(t.innerHTML=e.innerHTML)):n==="input"&&Et.test(e.type)?(t.defaultChecked=t.checked=e.checked,t.value!==e.value&&(t.value=e.value)):n==="option"?t.selected=e.defaultSelected:n==="input"||n==="textarea"?t.defaultValue=e.defaultValue:n==="script"&&t.text!==e.text&&(t.text=e.text),t.removeAttribute(v.expando)}function Mt(e){return typeof e.getElementsByTagName!="undefined"?e.getElementsByTagName("*"):typeof e.querySelectorAll!="undefined"?e.querySelectorAll("*"):[]}function _t(e){Et.test(e.type)&&(e.defaultChecked=e.checked)}function Qt(e,t){if(t in e)return t;var n=t.charAt(0).toUpperCase()+t.slice(1),r=t,i=Jt.length;while(i--){t=Jt[i]+n;if(t in e)return t}return r}function Gt(e,t){return e=t||e,v.css(e,"display")==="none"||!v.contains(e.ownerDocument,e)}function Yt(e,t){var n,r,i=[],s=0,o=e.length;for(;s<o;s++){n=e[s];if(!n.style)continue;i[s]=v._data(n,"olddisplay"),t?(!i[s]&&n.style.display==="none"&&(n.style.display=""),n.style.display===""&&Gt(n)&&(i[s]=v._data(n,"olddisplay",nn(n.nodeName)))):(r=Dt(n,"display"),!i[s]&&r!=="none"&&v._data(n,"olddisplay",r))}for(s=0;s<o;s++){n=e[s];if(!n.style)continue;if(!t||n.style.display==="none"||n.style.display==="")n.style.display=t?i[s]||"":"none"}return e}function Zt(e,t,n){var r=Rt.exec(t);return r?Math.max(0,r[1]-(n||0))+(r[2]||"px"):t}function en(e,t,n,r){var i=n===(r?"border":"content")?4:t==="width"?1:0,s=0;for(;i<4;i+=2)n==="margin"&&(s+=v.css(e,n+$t[i],!0)),r?(n==="content"&&(s-=parseFloat(Dt(e,"padding"+$t[i]))||0),n!=="margin"&&(s-=parseFloat(Dt(e,"border"+$t[i]+"Width"))||0)):(s+=parseFloat(Dt(e,"padding"+$t[i]))||0,n!=="padding"&&(s+=parseFloat(Dt(e,"border"+$t[i]+"Width"))||0));return s}function tn(e,t,n){var r=t==="width"?e.offsetWidth:e.offsetHeight,i=!0,s=v.support.boxSizing&&v.css(e,"boxSizing")==="border-box";if(r<=0||r==null){r=Dt(e,t);if(r<0||r==null)r=e.style[t];if(Ut.test(r))return r;i=s&&(v.support.boxSizingReliable||r===e.style[t]),r=parseFloat(r)||0}return r+en(e,t,n||(s?"border":"content"),i)+"px"}function nn(e){if(Wt[e])return Wt[e];var t=v("<"+e+">").appendTo(i.body),n=t.css("display");t.remove();if(n==="none"||n===""){Pt=i.body.appendChild(Pt||v.extend(i.createElement("iframe"),{frameBorder:0,width:0,height:0}));if(!Ht||!Pt.createElement)Ht=(Pt.contentWindow||Pt.contentDocument).document,Ht.write("<!doctype html><html><body>"),Ht.close();t=Ht.body.appendChild(Ht.createElement(e)),n=Dt(t,"display"),i.body.removeChild(Pt)}return Wt[e]=n,n}function fn(e,t,n,r){var i;if(v.isArray(t))v.each(t,function(t,i){n||sn.test(e)?r(e,i):fn(e+"["+(typeof i=="object"?t:"")+"]",i,n,r)});else if(!n&&v.type(t)==="object")for(i in t)fn(e+"["+i+"]",t[i],n,r);else r(e,t)}function Cn(e){return function(t,n){typeof t!="string"&&(n=t,t="*");var r,i,s,o=t.toLowerCase().split(y),u=0,a=o.length;if(v.isFunction(n))for(;u<a;u++)r=o[u],s=/^\+/.test(r),s&&(r=r.substr(1)||"*"),i=e[r]=e[r]||[],i[s?"unshift":"push"](n)}}function kn(e,n,r,i,s,o){s=s||n.dataTypes[0],o=o||{},o[s]=!0;var u,a=e[s],f=0,l=a?a.length:0,c=e===Sn;for(;f<l&&(c||!u);f++)u=a[f](n,r,i),typeof u=="string"&&(!c||o[u]?u=t:(n.dataTypes.unshift(u),u=kn(e,n,r,i,u,o)));return(c||!u)&&!o["*"]&&(u=kn(e,n,r,i,"*",o)),u}function Ln(e,n){var r,i,s=v.ajaxSettings.flatOptions||{};for(r in n)n[r]!==t&&((s[r]?e:i||(i={}))[r]=n[r]);i&&v.extend(!0,e,i)}function An(e,n,r){var i,s,o,u,a=e.contents,f=e.dataTypes,l=e.responseFields;for(s in l)s in r&&(n[l[s]]=r[s]);while(f[0]==="*")f.shift(),i===t&&(i=e.mimeType||n.getResponseHeader("content-type"));if(i)for(s in a)if(a[s]&&a[s].test(i)){f.unshift(s);break}if(f[0]in r)o=f[0];else{for(s in r){if(!f[0]||e.converters[s+" "+f[0]]){o=s;break}u||(u=s)}o=o||u}if(o)return o!==f[0]&&f.unshift(o),r[o]}function On(e,t){var n,r,i,s,o=e.dataTypes.slice(),u=o[0],a={},f=0;e.dataFilter&&(t=e.dataFilter(t,e.dataType));if(o[1])for(n in e.converters)a[n.toLowerCase()]=e.converters[n];for(;i=o[++f];)if(i!=="*"){if(u!=="*"&&u!==i){n=a[u+" "+i]||a["* "+i];if(!n)for(r in a){s=r.split(" ");if(s[1]===i){n=a[u+" "+s[0]]||a["* "+s[0]];if(n){n===!0?n=a[r]:a[r]!==!0&&(i=s[0],o.splice(f--,0,i));break}}}if(n!==!0)if(n&&e["throws"])t=n(t);else try{t=n(t)}catch(l){return{state:"parsererror",error:n?l:"No conversion from "+u+" to "+i}}}u=i}return{state:"success",data:t}}function Fn(){try{return new e.XMLHttpRequest}catch(t){}}function In(){try{return new e.ActiveXObject("Microsoft.XMLHTTP")}catch(t){}}function $n(){return setTimeout(function(){qn=t},0),qn=v.now()}function Jn(e,t){v.each(t,function(t,n){var r=(Vn[t]||[]).concat(Vn["*"]),i=0,s=r.length;for(;i<s;i++)if(r[i].call(e,t,n))return})}function Kn(e,t,n){var r,i=0,s=0,o=Xn.length,u=v.Deferred().always(function(){delete a.elem}),a=function(){var t=qn||$n(),n=Math.max(0,f.startTime+f.duration-t),r=n/f.duration||0,i=1-r,s=0,o=f.tweens.length;for(;s<o;s++)f.tweens[s].run(i);return u.notifyWith(e,[f,i,n]),i<1&&o?n:(u.resolveWith(e,[f]),!1)},f=u.promise({elem:e,props:v.extend({},t),opts:v.extend(!0,{specialEasing:{}},n),originalProperties:t,originalOptions:n,startTime:qn||$n(),duration:n.duration,tweens:[],createTween:function(t,n,r){var i=v.Tween(e,f.opts,t,n,f.opts.specialEasing[t]||f.opts.easing);return f.tweens.push(i),i},stop:function(t){var n=0,r=t?f.tweens.length:0;for(;n<r;n++)f.tweens[n].run(1);return t?u.resolveWith(e,[f,t]):u.rejectWith(e,[f,t]),this}}),l=f.props;Qn(l,f.opts.specialEasing);for(;i<o;i++){r=Xn[i].call(f,e,l,f.opts);if(r)return r}return Jn(f,l),v.isFunction(f.opts.start)&&f.opts.start.call(e,f),v.fx.timer(v.extend(a,{anim:f,queue:f.opts.queue,elem:e})),f.progress(f.opts.progress).done(f.opts.done,f.opts.complete).fail(f.opts.fail).always(f.opts.always)}function Qn(e,t){var n,r,i,s,o;for(n in e){r=v.camelCase(n),i=t[r],s=e[n],v.isArray(s)&&(i=s[1],s=e[n]=s[0]),n!==r&&(e[r]=s,delete e[n]),o=v.cssHooks[r];if(o&&"expand"in o){s=o.expand(s),delete e[r];for(n in s)n in e||(e[n]=s[n],t[n]=i)}else t[r]=i}}function Gn(e,t,n){var r,i,s,o,u,a,f,l,c,h=this,p=e.style,d={},m=[],g=e.nodeType&&Gt(e);n.queue||(l=v._queueHooks(e,"fx"),l.unqueued==null&&(l.unqueued=0,c=l.empty.fire,l.empty.fire=function(){l.unqueued||c()}),l.unqueued++,h.always(function(){h.always(function(){l.unqueued--,v.queue(e,"fx").length||l.empty.fire()})})),e.nodeType===1&&("height"in t||"width"in t)&&(n.overflow=[p.overflow,p.overflowX,p.overflowY],v.css(e,"display")==="inline"&&v.css(e,"float")==="none"&&(!v.support.inlineBlockNeedsLayout||nn(e.nodeName)==="inline"?p.display="inline-block":p.zoom=1)),n.overflow&&(p.overflow="hidden",v.support.shrinkWrapBlocks||h.done(function(){p.overflow=n.overflow[0],p.overflowX=n.overflow[1],p.overflowY=n.overflow[2]}));for(r in t){s=t[r];if(Un.exec(s)){delete t[r],a=a||s==="toggle";if(s===(g?"hide":"show"))continue;m.push(r)}}o=m.length;if(o){u=v._data(e,"fxshow")||v._data(e,"fxshow",{}),"hidden"in u&&(g=u.hidden),a&&(u.hidden=!g),g?v(e).show():h.done(function(){v(e).hide()}),h.done(function(){var t;v.removeData(e,"fxshow",!0);for(t in d)v.style(e,t,d[t])});for(r=0;r<o;r++)i=m[r],f=h.createTween(i,g?u[i]:0),d[i]=u[i]||v.style(e,i),i in u||(u[i]=f.start,g&&(f.end=f.start,f.start=i==="width"||i==="height"?1:0))}}function Yn(e,t,n,r,i){return new Yn.prototype.init(e,t,n,r,i)}function Zn(e,t){var n,r={height:e},i=0;t=t?1:0;for(;i<4;i+=2-t)n=$t[i],r["margin"+n]=r["padding"+n]=e;return t&&(r.opacity=r.width=e),r}function tr(e){return v.isWindow(e)?e:e.nodeType===9?e.defaultView||e.parentWindow:!1}var n,r,i=e.document,s=e.location,o=e.navigator,u=e.jQuery,a=e.$,f=Array.prototype.push,l=Array.prototype.slice,c=Array.prototype.indexOf,h=Object.prototype.toString,p=Object.prototype.hasOwnProperty,d=String.prototype.trim,v=function(e,t){return new v.fn.init(e,t,n)},m=/[\-+]?(?:\d*\.|)\d+(?:[eE][\-+]?\d+|)/.source,g=/\S/,y=/\s+/,b=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,w=/^(?:[^#<]*(<[\w\W]+>)[^>]*$|#([\w\-]*)$)/,E=/^<(\w+)\s*\/?>(?:<\/\1>|)$/,S=/^[\],:{}\s]*$/,x=/(?:^|:|,)(?:\s*\[)+/g,T=/\\(?:["\\\/bfnrt]|u[\da-fA-F]{4})/g,N=/"[^"\\\r\n]*"|true|false|null|-?(?:\d\d*\.|)\d+(?:[eE][\-+]?\d+|)/g,C=/^-ms-/,k=/-([\da-z])/gi,L=function(e,t){return(t+"").toUpperCase()},A=function(){i.addEventListener?(i.removeEventListener("DOMContentLoaded",A,!1),v.ready()):i.readyState==="complete"&&(i.detachEvent("onreadystatechange",A),v.ready())},O={};v.fn=v.prototype={constructor:v,init:function(e,n,r){var s,o,u,a;if(!e)return this;if(e.nodeType)return this.context=this[0]=e,this.length=1,this;if(typeof e=="string"){e.charAt(0)==="<"&&e.charAt(e.length-1)===">"&&e.length>=3?s=[null,e,null]:s=w.exec(e);if(s&&(s[1]||!n)){if(s[1])return n=n instanceof v?n[0]:n,a=n&&n.nodeType?n.ownerDocument||n:i,e=v.parseHTML(s[1],a,!0),E.test(s[1])&&v.isPlainObject(n)&&this.attr.call(e,n,!0),v.merge(this,e);o=i.getElementById(s[2]);if(o&&o.parentNode){if(o.id!==s[2])return r.find(e);this.length=1,this[0]=o}return this.context=i,this.selector=e,this}return!n||n.jquery?(n||r).find(e):this.constructor(n).find(e)}return v.isFunction(e)?r.ready(e):(e.selector!==t&&(this.selector=e.selector,this.context=e.context),v.makeArray(e,this))},selector:"",jquery:"1.8.3",length:0,size:function(){return this.length},toArray:function(){return l.call(this)},get:function(e){return e==null?this.toArray():e<0?this[this.length+e]:this[e]},pushStack:function(e,t,n){var r=v.merge(this.constructor(),e);return r.prevObject=this,r.context=this.context,t==="find"?r.selector=this.selector+(this.selector?" ":"")+n:t&&(r.selector=this.selector+"."+t+"("+n+")"),r},each:function(e,t){return v.each(this,e,t)},ready:function(e){return v.ready.promise().done(e),this},eq:function(e){return e=+e,e===-1?this.slice(e):this.slice(e,e+1)},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},slice:function(){return this.pushStack(l.apply(this,arguments),"slice",l.call(arguments).join(","))},map:function(e){return this.pushStack(v.map(this,function(t,n){return e.call(t,n,t)}))},end:function(){return this.prevObject||this.constructor(null)},push:f,sort:[].sort,splice:[].splice},v.fn.init.prototype=v.fn,v.extend=v.fn.extend=function(){var e,n,r,i,s,o,u=arguments[0]||{},a=1,f=arguments.length,l=!1;typeof u=="boolean"&&(l=u,u=arguments[1]||{},a=2),typeof u!="object"&&!v.isFunction(u)&&(u={}),f===a&&(u=this,--a);for(;a<f;a++)if((e=arguments[a])!=null)for(n in e){r=u[n],i=e[n];if(u===i)continue;l&&i&&(v.isPlainObject(i)||(s=v.isArray(i)))?(s?(s=!1,o=r&&v.isArray(r)?r:[]):o=r&&v.isPlainObject(r)?r:{},u[n]=v.extend(l,o,i)):i!==t&&(u[n]=i)}return u},v.extend({noConflict:function(t){return e.$===v&&(e.$=a),t&&e.jQuery===v&&(e.jQuery=u),v},isReady:!1,readyWait:1,holdReady:function(e){e?v.readyWait++:v.ready(!0)},ready:function(e){if(e===!0?--v.readyWait:v.isReady)return;if(!i.body)return setTimeout(v.ready,1);v.isReady=!0;if(e!==!0&&--v.readyWait>0)return;r.resolveWith(i,[v]),v.fn.trigger&&v(i).trigger("ready").off("ready")},isFunction:function(e){return v.type(e)==="function"},isArray:Array.isArray||function(e){return v.type(e)==="array"},isWindow:function(e){return e!=null&&e==e.window},isNumeric:function(e){return!isNaN(parseFloat(e))&&isFinite(e)},type:function(e){return e==null?String(e):O[h.call(e)]||"object"},isPlainObject:function(e){if(!e||v.type(e)!=="object"||e.nodeType||v.isWindow(e))return!1;try{if(e.constructor&&!p.call(e,"constructor")&&!p.call(e.constructor.prototype,"isPrototypeOf"))return!1}catch(n){return!1}var r;for(r in e);return r===t||p.call(e,r)},isEmptyObject:function(e){var t;for(t in e)return!1;return!0},error:function(e){throw new Error(e)},parseHTML:function(e,t,n){var r;return!e||typeof e!="string"?null:(typeof t=="boolean"&&(n=t,t=0),t=t||i,(r=E.exec(e))?[t.createElement(r[1])]:(r=v.buildFragment([e],t,n?null:[]),v.merge([],(r.cacheable?v.clone(r.fragment):r.fragment).childNodes)))},parseJSON:function(t){if(!t||typeof t!="string")return null;t=v.trim(t);if(e.JSON&&e.JSON.parse)return e.JSON.parse(t);if(S.test(t.replace(T,"@").replace(N,"]").replace(x,"")))return(new Function("return "+t))();v.error("Invalid JSON: "+t)},parseXML:function(n){var r,i;if(!n||typeof n!="string")return null;try{e.DOMParser?(i=new DOMParser,r=i.parseFromString(n,"text/xml")):(r=new ActiveXObject("Microsoft.XMLDOM"),r.async="false",r.loadXML(n))}catch(s){r=t}return(!r||!r.documentElement||r.getElementsByTagName("parsererror").length)&&v.error("Invalid XML: "+n),r},noop:function(){},globalEval:function(t){t&&g.test(t)&&(e.execScript||function(t){e.eval.call(e,t)})(t)},camelCase:function(e){return e.replace(C,"ms-").replace(k,L)},nodeName:function(e,t){return e.nodeName&&e.nodeName.toLowerCase()===t.toLowerCase()},each:function(e,n,r){var i,s=0,o=e.length,u=o===t||v.isFunction(e);if(r){if(u){for(i in e)if(n.apply(e[i],r)===!1)break}else for(;s<o;)if(n.apply(e[s++],r)===!1)break}else if(u){for(i in e)if(n.call(e[i],i,e[i])===!1)break}else for(;s<o;)if(n.call(e[s],s,e[s++])===!1)break;return e},trim:d&&!d.call(" ")?function(e){return e==null?"":d.call(e)}:function(e){return e==null?"":(e+"").replace(b,"")},makeArray:function(e,t){var n,r=t||[];return e!=null&&(n=v.type(e),e.length==null||n==="string"||n==="function"||n==="regexp"||v.isWindow(e)?f.call(r,e):v.merge(r,e)),r},inArray:function(e,t,n){var r;if(t){if(c)return c.call(t,e,n);r=t.length,n=n?n<0?Math.max(0,r+n):n:0;for(;n<r;n++)if(n in t&&t[n]===e)return n}return-1},merge:function(e,n){var r=n.length,i=e.length,s=0;if(typeof r=="number")for(;s<r;s++)e[i++]=n[s];else while(n[s]!==t)e[i++]=n[s++];return e.length=i,e},grep:function(e,t,n){var r,i=[],s=0,o=e.length;n=!!n;for(;s<o;s++)r=!!t(e[s],s),n!==r&&i.push(e[s]);return i},map:function(e,n,r){var i,s,o=[],u=0,a=e.length,f=e instanceof v||a!==t&&typeof a=="number"&&(a>0&&e[0]&&e[a-1]||a===0||v.isArray(e));if(f)for(;u<a;u++)i=n(e[u],u,r),i!=null&&(o[o.length]=i);else for(s in e)i=n(e[s],s,r),i!=null&&(o[o.length]=i);return o.concat.apply([],o)},guid:1,proxy:function(e,n){var r,i,s;return typeof n=="string"&&(r=e[n],n=e,e=r),v.isFunction(e)?(i=l.call(arguments,2),s=function(){return e.apply(n,i.concat(l.call(arguments)))},s.guid=e.guid=e.guid||v.guid++,s):t},access:function(e,n,r,i,s,o,u){var a,f=r==null,l=0,c=e.length;if(r&&typeof r=="object"){for(l in r)v.access(e,n,l,r[l],1,o,i);s=1}else if(i!==t){a=u===t&&v.isFunction(i),f&&(a?(a=n,n=function(e,t,n){return a.call(v(e),n)}):(n.call(e,i),n=null));if(n)for(;l<c;l++)n(e[l],r,a?i.call(e[l],l,n(e[l],r)):i,u);s=1}return s?e:f?n.call(e):c?n(e[0],r):o},now:function(){return(new Date).getTime()}}),v.ready.promise=function(t){if(!r){r=v.Deferred();if(i.readyState==="complete")setTimeout(v.ready,1);else if(i.addEventListener)i.addEventListener("DOMContentLoaded",A,!1),e.addEventListener("load",v.ready,!1);else{i.attachEvent("onreadystatechange",A),e.attachEvent("onload",v.ready);var n=!1;try{n=e.frameElement==null&&i.documentElement}catch(s){}n&&n.doScroll&&function o(){if(!v.isReady){try{n.doScroll("left")}catch(e){return setTimeout(o,50)}v.ready()}}()}}return r.promise(t)},v.each("Boolean Number String Function Array Date RegExp Object".split(" "),function(e,t){O["[object "+t+"]"]=t.toLowerCase()}),n=v(i);var M={};v.Callbacks=function(e){e=typeof e=="string"?M[e]||_(e):v.extend({},e);var n,r,i,s,o,u,a=[],f=!e.once&&[],l=function(t){n=e.memory&&t,r=!0,u=s||0,s=0,o=a.length,i=!0;for(;a&&u<o;u++)if(a[u].apply(t[0],t[1])===!1&&e.stopOnFalse){n=!1;break}i=!1,a&&(f?f.length&&l(f.shift()):n?a=[]:c.disable())},c={add:function(){if(a){var t=a.length;(function r(t){v.each(t,function(t,n){var i=v.type(n);i==="function"?(!e.unique||!c.has(n))&&a.push(n):n&&n.length&&i!=="string"&&r(n)})})(arguments),i?o=a.length:n&&(s=t,l(n))}return this},remove:function(){return a&&v.each(arguments,function(e,t){var n;while((n=v.inArray(t,a,n))>-1)a.splice(n,1),i&&(n<=o&&o--,n<=u&&u--)}),this},has:function(e){return v.inArray(e,a)>-1},empty:function(){return a=[],this},disable:function(){return a=f=n=t,this},disabled:function(){return!a},lock:function(){return f=t,n||c.disable(),this},locked:function(){return!f},fireWith:function(e,t){return t=t||[],t=[e,t.slice?t.slice():t],a&&(!r||f)&&(i?f.push(t):l(t)),this},fire:function(){return c.fireWith(this,arguments),this},fired:function(){return!!r}};return c},v.extend({Deferred:function(e){var t=[["resolve","done",v.Callbacks("once memory"),"resolved"],["reject","fail",v.Callbacks("once memory"),"rejected"],["notify","progress",v.Callbacks("memory")]],n="pending",r={state:function(){return n},always:function(){return i.done(arguments).fail(arguments),this},then:function(){var e=arguments;return v.Deferred(function(n){v.each(t,function(t,r){var s=r[0],o=e[t];i[r[1]](v.isFunction(o)?function(){var e=o.apply(this,arguments);e&&v.isFunction(e.promise)?e.promise().done(n.resolve).fail(n.reject).progress(n.notify):n[s+"With"](this===i?n:this,[e])}:n[s])}),e=null}).promise()},promise:function(e){return e!=null?v.extend(e,r):r}},i={};return r.pipe=r.then,v.each(t,function(e,s){var o=s[2],u=s[3];r[s[1]]=o.add,u&&o.add(function(){n=u},t[e^1][2].disable,t[2][2].lock),i[s[0]]=o.fire,i[s[0]+"With"]=o.fireWith}),r.promise(i),e&&e.call(i,i),i},when:function(e){var t=0,n=l.call(arguments),r=n.length,i=r!==1||e&&v.isFunction(e.promise)?r:0,s=i===1?e:v.Deferred(),o=function(e,t,n){return function(r){t[e]=this,n[e]=arguments.length>1?l.call(arguments):r,n===u?s.notifyWith(t,n):--i||s.resolveWith(t,n)}},u,a,f;if(r>1){u=new Array(r),a=new Array(r),f=new Array(r);for(;t<r;t++)n[t]&&v.isFunction(n[t].promise)?n[t].promise().done(o(t,f,n)).fail(s.reject).progress(o(t,a,u)):--i}return i||s.resolveWith(f,n),s.promise()}}),v.support=function(){var t,n,r,s,o,u,a,f,l,c,h,p=i.createElement("div");p.setAttribute("className","t"),p.innerHTML=" <link/><table></table><a href='/a'>a</a><input type='checkbox'/>",n=p.getElementsByTagName("*"),r=p.getElementsByTagName("a")[0];if(!n||!r||!n.length)return{};s=i.createElement("select"),o=s.appendChild(i.createElement("option")),u=p.getElementsByTagName("input")[0],r.style.cssText="top:1px;float:left;opacity:.5",t={leadingWhitespace:p.firstChild.nodeType===3,tbody:!p.getElementsByTagName("tbody").length,htmlSerialize:!!p.getElementsByTagName("link").length,style:/top/.test(r.getAttribute("style")),hrefNormalized:r.getAttribute("href")==="/a",opacity:/^0.5/.test(r.style.opacity),cssFloat:!!r.style.cssFloat,checkOn:u.value==="on",optSelected:o.selected,getSetAttribute:p.className!=="t",enctype:!!i.createElement("form").enctype,html5Clone:i.createElement("nav").cloneNode(!0).outerHTML!=="<:nav></:nav>",boxModel:i.compatMode==="CSS1Compat",submitBubbles:!0,changeBubbles:!0,focusinBubbles:!1,deleteExpando:!0,noCloneEvent:!0,inlineBlockNeedsLayout:!1,shrinkWrapBlocks:!1,reliableMarginRight:!0,boxSizingReliable:!0,pixelPosition:!1},u.checked=!0,t.noCloneChecked=u.cloneNode(!0).checked,s.disabled=!0,t.optDisabled=!o.disabled;try{delete p.test}catch(d){t.deleteExpando=!1}!p.addEventListener&&p.attachEvent&&p.fireEvent&&(p.attachEvent("onclick",h=function(){t.noCloneEvent=!1}),p.cloneNode(!0).fireEvent("onclick"),p.detachEvent("onclick",h)),u=i.createElement("input"),u.value="t",u.setAttribute("type","radio"),t.radioValue=u.value==="t",u.setAttribute("checked","checked"),u.setAttribute("name","t"),p.appendChild(u),a=i.createDocumentFragment(),a.appendChild(p.lastChild),t.checkClone=a.cloneNode(!0).cloneNode(!0).lastChild.checked,t.appendChecked=u.checked,a.removeChild(u),a.appendChild(p);if(p.attachEvent)for(l in{submit:!0,change:!0,focusin:!0})f="on"+l,c=f in p,c||(p.setAttribute(f,"return;"),c=typeof p[f]=="function"),t[l+"Bubbles"]=c;return v(function(){var n,r,s,o,u="padding:0;margin:0;border:0;display:block;overflow:hidden;",a=i.getElementsByTagName("body")[0];if(!a)return;n=i.createElement("div"),n.style.cssText="visibility:hidden;border:0;width:0;height:0;position:static;top:0;margin-top:1px",a.insertBefore(n,a.firstChild),r=i.createElement("div"),n.appendChild(r),r.innerHTML="<table><tr><td></td><td>t</td></tr></table>",s=r.getElementsByTagName("td"),s[0].style.cssText="padding:0;margin:0;border:0;display:none",c=s[0].offsetHeight===0,s[0].style.display="",s[1].style.display="none",t.reliableHiddenOffsets=c&&s[0].offsetHeight===0,r.innerHTML="",r.style.cssText="box-sizing:border-box;-moz-box-sizing:border-box;-webkit-box-sizing:border-box;padding:1px;border:1px;display:block;width:4px;margin-top:1%;position:absolute;top:1%;",t.boxSizing=r.offsetWidth===4,t.doesNotIncludeMarginInBodyOffset=a.offsetTop!==1,e.getComputedStyle&&(t.pixelPosition=(e.getComputedStyle(r,null)||{}).top!=="1%",t.boxSizingReliable=(e.getComputedStyle(r,null)||{width:"4px"}).width==="4px",o=i.createElement("div"),o.style.cssText=r.style.cssText=u,o.style.marginRight=o.style.width="0",r.style.width="1px",r.appendChild(o),t.reliableMarginRight=!parseFloat((e.getComputedStyle(o,null)||{}).marginRight)),typeof r.style.zoom!="undefined"&&(r.innerHTML="",r.style.cssText=u+"width:1px;padding:1px;display:inline;zoom:1",t.inlineBlockNeedsLayout=r.offsetWidth===3,r.style.display="block",r.style.overflow="visible",r.innerHTML="<div></div>",r.firstChild.style.width="5px",t.shrinkWrapBlocks=r.offsetWidth!==3,n.style.zoom=1),a.removeChild(n),n=r=s=o=null}),a.removeChild(p),n=r=s=o=u=a=p=null,t}();var D=/(?:\{[\s\S]*\}|\[[\s\S]*\])$/,P=/([A-Z])/g;v.extend({cache:{},deletedIds:[],uuid:0,expando:"jQuery"+(v.fn.jquery+Math.random()).replace(/\D/g,""),noData:{embed:!0,object:"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000",applet:!0},hasData:function(e){return e=e.nodeType?v.cache[e[v.expando]]:e[v.expando],!!e&&!B(e)},data:function(e,n,r,i){if(!v.acceptData(e))return;var s,o,u=v.expando,a=typeof n=="string",f=e.nodeType,l=f?v.cache:e,c=f?e[u]:e[u]&&u;if((!c||!l[c]||!i&&!l[c].data)&&a&&r===t)return;c||(f?e[u]=c=v.deletedIds.pop()||v.guid++:c=u),l[c]||(l[c]={},f||(l[c].toJSON=v.noop));if(typeof n=="object"||typeof n=="function")i?l[c]=v.extend(l[c],n):l[c].data=v.extend(l[c].data,n);return s=l[c],i||(s.data||(s.data={}),s=s.data),r!==t&&(s[v.camelCase(n)]=r),a?(o=s[n],o==null&&(o=s[v.camelCase(n)])):o=s,o},removeData:function(e,t,n){if(!v.acceptData(e))return;var r,i,s,o=e.nodeType,u=o?v.cache:e,a=o?e[v.expando]:v.expando;if(!u[a])return;if(t){r=n?u[a]:u[a].data;if(r){v.isArray(t)||(t in r?t=[t]:(t=v.camelCase(t),t in r?t=[t]:t=t.split(" ")));for(i=0,s=t.length;i<s;i++)delete r[t[i]];if(!(n?B:v.isEmptyObject)(r))return}}if(!n){delete u[a].data;if(!B(u[a]))return}o?v.cleanData([e],!0):v.support.deleteExpando||u!=u.window?delete u[a]:u[a]=null},_data:function(e,t,n){return v.data(e,t,n,!0)},acceptData:function(e){var t=e.nodeName&&v.noData[e.nodeName.toLowerCase()];return!t||t!==!0&&e.getAttribute("classid")===t}}),v.fn.extend({data:function(e,n){var r,i,s,o,u,a=this[0],f=0,l=null;if(e===t){if(this.length){l=v.data(a);if(a.nodeType===1&&!v._data(a,"parsedAttrs")){s=a.attributes;for(u=s.length;f<u;f++)o=s[f].name,o.indexOf("data-")||(o=v.camelCase(o.substring(5)),H(a,o,l[o]));v._data(a,"parsedAttrs",!0)}}return l}return typeof e=="object"?this.each(function(){v.data(this,e)}):(r=e.split(".",2),r[1]=r[1]?"."+r[1]:"",i=r[1]+"!",v.access(this,function(n){if(n===t)return l=this.triggerHandler("getData"+i,[r[0]]),l===t&&a&&(l=v.data(a,e),l=H(a,e,l)),l===t&&r[1]?this.data(r[0]):l;r[1]=n,this.each(function(){var t=v(this);t.triggerHandler("setData"+i,r),v.data(this,e,n),t.triggerHandler("changeData"+i,r)})},null,n,arguments.length>1,null,!1))},removeData:function(e){return this.each(function(){v.removeData(this,e)})}}),v.extend({queue:function(e,t,n){var r;if(e)return t=(t||"fx")+"queue",r=v._data(e,t),n&&(!r||v.isArray(n)?r=v._data(e,t,v.makeArray(n)):r.push(n)),r||[]},dequeue:function(e,t){t=t||"fx";var n=v.queue(e,t),r=n.length,i=n.shift(),s=v._queueHooks(e,t),o=function(){v.dequeue(e,t)};i==="inprogress"&&(i=n.shift(),r--),i&&(t==="fx"&&n.unshift("inprogress"),delete s.stop,i.call(e,o,s)),!r&&s&&s.empty.fire()},_queueHooks:function(e,t){var n=t+"queueHooks";return v._data(e,n)||v._data(e,n,{empty:v.Callbacks("once memory").add(function(){v.removeData(e,t+"queue",!0),v.removeData(e,n,!0)})})}}),v.fn.extend({queue:function(e,n){var r=2;return typeof e!="string"&&(n=e,e="fx",r--),arguments.length<r?v.queue(this[0],e):n===t?this:this.each(function(){var t=v.queue(this,e,n);v._queueHooks(this,e),e==="fx"&&t[0]!=="inprogress"&&v.dequeue(this,e)})},dequeue:function(e){return this.each(function(){v.dequeue(this,e)})},delay:function(e,t){return e=v.fx?v.fx.speeds[e]||e:e,t=t||"fx",this.queue(t,function(t,n){var r=setTimeout(t,e);n.stop=function(){clearTimeout(r)}})},clearQueue:function(e){return this.queue(e||"fx",[])},promise:function(e,n){var r,i=1,s=v.Deferred(),o=this,u=this.length,a=function(){--i||s.resolveWith(o,[o])};typeof e!="string"&&(n=e,e=t),e=e||"fx";while(u--)r=v._data(o[u],e+"queueHooks"),r&&r.empty&&(i++,r.empty.add(a));return a(),s.promise(n)}});var j,F,I,q=/[\t\r\n]/g,R=/\r/g,U=/^(?:button|input)$/i,z=/^(?:button|input|object|select|textarea)$/i,W=/^a(?:rea|)$/i,X=/^(?:autofocus|autoplay|async|checked|controls|defer|disabled|hidden|loop|multiple|open|readonly|required|scoped|selected)$/i,V=v.support.getSetAttribute;v.fn.extend({attr:function(e,t){return v.access(this,v.attr,e,t,arguments.length>1)},removeAttr:function(e){return this.each(function(){v.removeAttr(this,e)})},prop:function(e,t){return v.access(this,v.prop,e,t,arguments.length>1)},removeProp:function(e){return e=v.propFix[e]||e,this.each(function(){try{this[e]=t,delete this[e]}catch(n){}})},addClass:function(e){var t,n,r,i,s,o,u;if(v.isFunction(e))return this.each(function(t){v(this).addClass(e.call(this,t,this.className))});if(e&&typeof e=="string"){t=e.split(y);for(n=0,r=this.length;n<r;n++){i=this[n];if(i.nodeType===1)if(!i.className&&t.length===1)i.className=e;else{s=" "+i.className+" ";for(o=0,u=t.length;o<u;o++)s.indexOf(" "+t[o]+" ")<0&&(s+=t[o]+" ");i.className=v.trim(s)}}}return this},removeClass:function(e){var n,r,i,s,o,u,a;if(v.isFunction(e))return this.each(function(t){v(this).removeClass(e.call(this,t,this.className))});if(e&&typeof e=="string"||e===t){n=(e||"").split(y);for(u=0,a=this.length;u<a;u++){i=this[u];if(i.nodeType===1&&i.className){r=(" "+i.className+" ").replace(q," ");for(s=0,o=n.length;s<o;s++)while(r.indexOf(" "+n[s]+" ")>=0)r=r.replace(" "+n[s]+" "," ");i.className=e?v.trim(r):""}}}return this},toggleClass:function(e,t){var n=typeof e,r=typeof t=="boolean";return v.isFunction(e)?this.each(function(n){v(this).toggleClass(e.call(this,n,this.className,t),t)}):this.each(function(){if(n==="string"){var i,s=0,o=v(this),u=t,a=e.split(y);while(i=a[s++])u=r?u:!o.hasClass(i),o[u?"addClass":"removeClass"](i)}else if(n==="undefined"||n==="boolean")this.className&&v._data(this,"__className__",this.className),this.className=this.className||e===!1?"":v._data(this,"__className__")||""})},hasClass:function(e){var t=" "+e+" ",n=0,r=this.length;for(;n<r;n++)if(this[n].nodeType===1&&(" "+this[n].className+" ").replace(q," ").indexOf(t)>=0)return!0;return!1},val:function(e){var n,r,i,s=this[0];if(!arguments.length){if(s)return n=v.valHooks[s.type]||v.valHooks[s.nodeName.toLowerCase()],n&&"get"in n&&(r=n.get(s,"value"))!==t?r:(r=s.value,typeof r=="string"?r.replace(R,""):r==null?"":r);return}return i=v.isFunction(e),this.each(function(r){var s,o=v(this);if(this.nodeType!==1)return;i?s=e.call(this,r,o.val()):s=e,s==null?s="":typeof s=="number"?s+="":v.isArray(s)&&(s=v.map(s,function(e){return e==null?"":e+""})),n=v.valHooks[this.type]||v.valHooks[this.nodeName.toLowerCase()];if(!n||!("set"in n)||n.set(this,s,"value")===t)this.value=s})}}),v.extend({valHooks:{option:{get:function(e){var t=e.attributes.value;return!t||t.specified?e.value:e.text}},select:{get:function(e){var t,n,r=e.options,i=e.selectedIndex,s=e.type==="select-one"||i<0,o=s?null:[],u=s?i+1:r.length,a=i<0?u:s?i:0;for(;a<u;a++){n=r[a];if((n.selected||a===i)&&(v.support.optDisabled?!n.disabled:n.getAttribute("disabled")===null)&&(!n.parentNode.disabled||!v.nodeName(n.parentNode,"optgroup"))){t=v(n).val();if(s)return t;o.push(t)}}return o},set:function(e,t){var n=v.makeArray(t);return v(e).find("option").each(function(){this.selected=v.inArray(v(this).val(),n)>=0}),n.length||(e.selectedIndex=-1),n}}},attrFn:{},attr:function(e,n,r,i){var s,o,u,a=e.nodeType;if(!e||a===3||a===8||a===2)return;if(i&&v.isFunction(v.fn[n]))return v(e)[n](r);if(typeof e.getAttribute=="undefined")return v.prop(e,n,r);u=a!==1||!v.isXMLDoc(e),u&&(n=n.toLowerCase(),o=v.attrHooks[n]||(X.test(n)?F:j));if(r!==t){if(r===null){v.removeAttr(e,n);return}return o&&"set"in o&&u&&(s=o.set(e,r,n))!==t?s:(e.setAttribute(n,r+""),r)}return o&&"get"in o&&u&&(s=o.get(e,n))!==null?s:(s=e.getAttribute(n),s===null?t:s)},removeAttr:function(e,t){var n,r,i,s,o=0;if(t&&e.nodeType===1){r=t.split(y);for(;o<r.length;o++)i=r[o],i&&(n=v.propFix[i]||i,s=X.test(i),s||v.attr(e,i,""),e.removeAttribute(V?i:n),s&&n in e&&(e[n]=!1))}},attrHooks:{type:{set:function(e,t){if(U.test(e.nodeName)&&e.parentNode)v.error("type property can't be changed");else if(!v.support.radioValue&&t==="radio"&&v.nodeName(e,"input")){var n=e.value;return e.setAttribute("type",t),n&&(e.value=n),t}}},value:{get:function(e,t){return j&&v.nodeName(e,"button")?j.get(e,t):t in e?e.value:null},set:function(e,t,n){if(j&&v.nodeName(e,"button"))return j.set(e,t,n);e.value=t}}},propFix:{tabindex:"tabIndex",readonly:"readOnly","for":"htmlFor","class":"className",maxlength:"maxLength",cellspacing:"cellSpacing",cellpadding:"cellPadding",rowspan:"rowSpan",colspan:"colSpan",usemap:"useMap",frameborder:"frameBorder",contenteditable:"contentEditable"},prop:function(e,n,r){var i,s,o,u=e.nodeType;if(!e||u===3||u===8||u===2)return;return o=u!==1||!v.isXMLDoc(e),o&&(n=v.propFix[n]||n,s=v.propHooks[n]),r!==t?s&&"set"in s&&(i=s.set(e,r,n))!==t?i:e[n]=r:s&&"get"in s&&(i=s.get(e,n))!==null?i:e[n]},propHooks:{tabIndex:{get:function(e){var n=e.getAttributeNode("tabindex");return n&&n.specified?parseInt(n.value,10):z.test(e.nodeName)||W.test(e.nodeName)&&e.href?0:t}}}}),F={get:function(e,n){var r,i=v.prop(e,n);return i===!0||typeof i!="boolean"&&(r=e.getAttributeNode(n))&&r.nodeValue!==!1?n.toLowerCase():t},set:function(e,t,n){var r;return t===!1?v.removeAttr(e,n):(r=v.propFix[n]||n,r in e&&(e[r]=!0),e.setAttribute(n,n.toLowerCase())),n}},V||(I={name:!0,id:!0,coords:!0},j=v.valHooks.button={get:function(e,n){var r;return r=e.getAttributeNode(n),r&&(I[n]?r.value!=="":r.specified)?r.value:t},set:function(e,t,n){var r=e.getAttributeNode(n);return r||(r=i.createAttribute(n),e.setAttributeNode(r)),r.value=t+""}},v.each(["width","height"],function(e,t){v.attrHooks[t]=v.extend(v.attrHooks[t],{set:function(e,n){if(n==="")return e.setAttribute(t,"auto"),n}})}),v.attrHooks.contenteditable={get:j.get,set:function(e,t,n){t===""&&(t="false"),j.set(e,t,n)}}),v.support.hrefNormalized||v.each(["href","src","width","height"],function(e,n){v.attrHooks[n]=v.extend(v.attrHooks[n],{get:function(e){var r=e.getAttribute(n,2);return r===null?t:r}})}),v.support.style||(v.attrHooks.style={get:function(e){return e.style.cssText.toLowerCase()||t},set:function(e,t){return e.style.cssText=t+""}}),v.support.optSelected||(v.propHooks.selected=v.extend(v.propHooks.selected,{get:function(e){var t=e.parentNode;return t&&(t.selectedIndex,t.parentNode&&t.parentNode.selectedIndex),null}})),v.support.enctype||(v.propFix.enctype="encoding"),v.support.checkOn||v.each(["radio","checkbox"],function(){v.valHooks[this]={get:function(e){return e.getAttribute("value")===null?"on":e.value}}}),v.each(["radio","checkbox"],function(){v.valHooks[this]=v.extend(v.valHooks[this],{set:function(e,t){if(v.isArray(t))return e.checked=v.inArray(v(e).val(),t)>=0}})});var $=/^(?:textarea|input|select)$/i,J=/^([^\.]*|)(?:\.(.+)|)$/,K=/(?:^|\s)hover(\.\S+|)\b/,Q=/^key/,G=/^(?:mouse|contextmenu)|click/,Y=/^(?:focusinfocus|focusoutblur)$/,Z=function(e){return v.event.special.hover?e:e.replace(K,"mouseenter$1 mouseleave$1")};v.event={add:function(e,n,r,i,s){var o,u,a,f,l,c,h,p,d,m,g;if(e.nodeType===3||e.nodeType===8||!n||!r||!(o=v._data(e)))return;r.handler&&(d=r,r=d.handler,s=d.selector),r.guid||(r.guid=v.guid++),a=o.events,a||(o.events=a={}),u=o.handle,u||(o.handle=u=function(e){return typeof v=="undefined"||!!e&&v.event.triggered===e.type?t:v.event.dispatch.apply(u.elem,arguments)},u.elem=e),n=v.trim(Z(n)).split(" ");for(f=0;f<n.length;f++){l=J.exec(n[f])||[],c=l[1],h=(l[2]||"").split(".").sort(),g=v.event.special[c]||{},c=(s?g.delegateType:g.bindType)||c,g=v.event.special[c]||{},p=v.extend({type:c,origType:l[1],data:i,handler:r,guid:r.guid,selector:s,needsContext:s&&v.expr.match.needsContext.test(s),namespace:h.join(".")},d),m=a[c];if(!m){m=a[c]=[],m.delegateCount=0;if(!g.setup||g.setup.call(e,i,h,u)===!1)e.addEventListener?e.addEventListener(c,u,!1):e.attachEvent&&e.attachEvent("on"+c,u)}g.add&&(g.add.call(e,p),p.handler.guid||(p.handler.guid=r.guid)),s?m.splice(m.delegateCount++,0,p):m.push(p),v.event.global[c]=!0}e=null},global:{},remove:function(e,t,n,r,i){var s,o,u,a,f,l,c,h,p,d,m,g=v.hasData(e)&&v._data(e);if(!g||!(h=g.events))return;t=v.trim(Z(t||"")).split(" ");for(s=0;s<t.length;s++){o=J.exec(t[s])||[],u=a=o[1],f=o[2];if(!u){for(u in h)v.event.remove(e,u+t[s],n,r,!0);continue}p=v.event.special[u]||{},u=(r?p.delegateType:p.bindType)||u,d=h[u]||[],l=d.length,f=f?new RegExp("(^|\\.)"+f.split(".").sort().join("\\.(?:.*\\.|)")+"(\\.|$)"):null;for(c=0;c<d.length;c++)m=d[c],(i||a===m.origType)&&(!n||n.guid===m.guid)&&(!f||f.test(m.namespace))&&(!r||r===m.selector||r==="**"&&m.selector)&&(d.splice(c--,1),m.selector&&d.delegateCount--,p.remove&&p.remove.call(e,m));d.length===0&&l!==d.length&&((!p.teardown||p.teardown.call(e,f,g.handle)===!1)&&v.removeEvent(e,u,g.handle),delete h[u])}v.isEmptyObject(h)&&(delete g.handle,v.removeData(e,"events",!0))},customEvent:{getData:!0,setData:!0,changeData:!0},trigger:function(n,r,s,o){if(!s||s.nodeType!==3&&s.nodeType!==8){var u,a,f,l,c,h,p,d,m,g,y=n.type||n,b=[];if(Y.test(y+v.event.triggered))return;y.indexOf("!")>=0&&(y=y.slice(0,-1),a=!0),y.indexOf(".")>=0&&(b=y.split("."),y=b.shift(),b.sort());if((!s||v.event.customEvent[y])&&!v.event.global[y])return;n=typeof n=="object"?n[v.expando]?n:new v.Event(y,n):new v.Event(y),n.type=y,n.isTrigger=!0,n.exclusive=a,n.namespace=b.join("."),n.namespace_re=n.namespace?new RegExp("(^|\\.)"+b.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,h=y.indexOf(":")<0?"on"+y:"";if(!s){u=v.cache;for(f in u)u[f].events&&u[f].events[y]&&v.event.trigger(n,r,u[f].handle.elem,!0);return}n.result=t,n.target||(n.target=s),r=r!=null?v.makeArray(r):[],r.unshift(n),p=v.event.special[y]||{};if(p.trigger&&p.trigger.apply(s,r)===!1)return;m=[[s,p.bindType||y]];if(!o&&!p.noBubble&&!v.isWindow(s)){g=p.delegateType||y,l=Y.test(g+y)?s:s.parentNode;for(c=s;l;l=l.parentNode)m.push([l,g]),c=l;c===(s.ownerDocument||i)&&m.push([c.defaultView||c.parentWindow||e,g])}for(f=0;f<m.length&&!n.isPropagationStopped();f++)l=m[f][0],n.type=m[f][1],d=(v._data(l,"events")||{})[n.type]&&v._data(l,"handle"),d&&d.apply(l,r),d=h&&l[h],d&&v.acceptData(l)&&d.apply&&d.apply(l,r)===!1&&n.preventDefault();return n.type=y,!o&&!n.isDefaultPrevented()&&(!p._default||p._default.apply(s.ownerDocument,r)===!1)&&(y!=="click"||!v.nodeName(s,"a"))&&v.acceptData(s)&&h&&s[y]&&(y!=="focus"&&y!=="blur"||n.target.offsetWidth!==0)&&!v.isWindow(s)&&(c=s[h],c&&(s[h]=null),v.event.triggered=y,s[y](),v.event.triggered=t,c&&(s[h]=c)),n.result}return},dispatch:function(n){n=v.event.fix(n||e.event);var r,i,s,o,u,a,f,c,h,p,d=(v._data(this,"events")||{})[n.type]||[],m=d.delegateCount,g=l.call(arguments),y=!n.exclusive&&!n.namespace,b=v.event.special[n.type]||{},w=[];g[0]=n,n.delegateTarget=this;if(b.preDispatch&&b.preDispatch.call(this,n)===!1)return;if(m&&(!n.button||n.type!=="click"))for(s=n.target;s!=this;s=s.parentNode||this)if(s.disabled!==!0||n.type!=="click"){u={},f=[];for(r=0;r<m;r++)c=d[r],h=c.selector,u[h]===t&&(u[h]=c.needsContext?v(h,this).index(s)>=0:v.find(h,this,null,[s]).length),u[h]&&f.push(c);f.length&&w.push({elem:s,matches:f})}d.length>m&&w.push({elem:this,matches:d.slice(m)});for(r=0;r<w.length&&!n.isPropagationStopped();r++){a=w[r],n.currentTarget=a.elem;for(i=0;i<a.matches.length&&!n.isImmediatePropagationStopped();i++){c=a.matches[i];if(y||!n.namespace&&!c.namespace||n.namespace_re&&n.namespace_re.test(c.namespace))n.data=c.data,n.handleObj=c,o=((v.event.special[c.origType]||{}).handle||c.handler).apply(a.elem,g),o!==t&&(n.result=o,o===!1&&(n.preventDefault(),n.stopPropagation()))}}return b.postDispatch&&b.postDispatch.call(this,n),n.result},props:"attrChange attrName relatedNode srcElement altKey bubbles cancelable ctrlKey currentTarget eventPhase metaKey relatedTarget shiftKey target timeStamp view which".split(" "),fixHooks:{},keyHooks:{props:"char charCode key keyCode".split(" "),filter:function(e,t){return e.which==null&&(e.which=t.charCode!=null?t.charCode:t.keyCode),e}},mouseHooks:{props:"button buttons clientX clientY fromElement offsetX offsetY pageX pageY screenX screenY toElement".split(" "),filter:function(e,n){var r,s,o,u=n.button,a=n.fromElement;return e.pageX==null&&n.clientX!=null&&(r=e.target.ownerDocument||i,s=r.documentElement,o=r.body,e.pageX=n.clientX+(s&&s.scrollLeft||o&&o.scrollLeft||0)-(s&&s.clientLeft||o&&o.clientLeft||0),e.pageY=n.clientY+(s&&s.scrollTop||o&&o.scrollTop||0)-(s&&s.clientTop||o&&o.clientTop||0)),!e.relatedTarget&&a&&(e.relatedTarget=a===e.target?n.toElement:a),!e.which&&u!==t&&(e.which=u&1?1:u&2?3:u&4?2:0),e}},fix:function(e){if(e[v.expando])return e;var t,n,r=e,s=v.event.fixHooks[e.type]||{},o=s.props?this.props.concat(s.props):this.props;e=v.Event(r);for(t=o.length;t;)n=o[--t],e[n]=r[n];return e.target||(e.target=r.srcElement||i),e.target.nodeType===3&&(e.target=e.target.parentNode),e.metaKey=!!e.metaKey,s.filter?s.filter(e,r):e},special:{load:{noBubble:!0},focus:{delegateType:"focusin"},blur:{delegateType:"focusout"},beforeunload:{setup:function(e,t,n){v.isWindow(this)&&(this.onbeforeunload=n)},teardown:function(e,t){this.onbeforeunload===t&&(this.onbeforeunload=null)}}},simulate:function(e,t,n,r){var i=v.extend(new v.Event,n,{type:e,isSimulated:!0,originalEvent:{}});r?v.event.trigger(i,null,t):v.event.dispatch.call(t,i),i.isDefaultPrevented()&&n.preventDefault()}},v.event.handle=v.event.dispatch,v.removeEvent=i.removeEventListener?function(e,t,n){e.removeEventListener&&e.removeEventListener(t,n,!1)}:function(e,t,n){var r="on"+t;e.detachEvent&&(typeof e[r]=="undefined"&&(e[r]=null),e.detachEvent(r,n))},v.Event=function(e,t){if(!(this instanceof v.Event))return new v.Event(e,t);e&&e.type?(this.originalEvent=e,this.type=e.type,this.isDefaultPrevented=e.defaultPrevented||e.returnValue===!1||e.getPreventDefault&&e.getPreventDefault()?tt:et):this.type=e,t&&v.extend(this,t),this.timeStamp=e&&e.timeStamp||v.now(),this[v.expando]=!0},v.Event.prototype={preventDefault:function(){this.isDefaultPrevented=tt;var e=this.originalEvent;if(!e)return;e.preventDefault?e.preventDefault():e.returnValue=!1},stopPropagation:function(){this.isPropagationStopped=tt;var e=this.originalEvent;if(!e)return;e.stopPropagation&&e.stopPropagation(),e.cancelBubble=!0},stopImmediatePropagation:function(){this.isImmediatePropagationStopped=tt,this.stopPropagation()},isDefaultPrevented:et,isPropagationStopped:et,isImmediatePropagationStopped:et},v.each({mouseenter:"mouseover",mouseleave:"mouseout"},function(e,t){v.event.special[e]={delegateType:t,bindType:t,handle:function(e){var n,r=this,i=e.relatedTarget,s=e.handleObj,o=s.selector;if(!i||i!==r&&!v.contains(r,i))e.type=s.origType,n=s.handler.apply(this,arguments),e.type=t;return n}}}),v.support.submitBubbles||(v.event.special.submit={setup:function(){if(v.nodeName(this,"form"))return!1;v.event.add(this,"click._submit keypress._submit",function(e){var n=e.target,r=v.nodeName(n,"input")||v.nodeName(n,"button")?n.form:t;r&&!v._data(r,"_submit_attached")&&(v.event.add(r,"submit._submit",function(e){e._submit_bubble=!0}),v._data(r,"_submit_attached",!0))})},postDispatch:function(e){e._submit_bubble&&(delete e._submit_bubble,this.parentNode&&!e.isTrigger&&v.event.simulate("submit",this.parentNode,e,!0))},teardown:function(){if(v.nodeName(this,"form"))return!1;v.event.remove(this,"._submit")}}),v.support.changeBubbles||(v.event.special.change={setup:function(){if($.test(this.nodeName)){if(this.type==="checkbox"||this.type==="radio")v.event.add(this,"propertychange._change",function(e){e.originalEvent.propertyName==="checked"&&(this._just_changed=!0)}),v.event.add(this,"click._change",function(e){this._just_changed&&!e.isTrigger&&(this._just_changed=!1),v.event.simulate("change",this,e,!0)});return!1}v.event.add(this,"beforeactivate._change",function(e){var t=e.target;$.test(t.nodeName)&&!v._data(t,"_change_attached")&&(v.event.add(t,"change._change",function(e){this.parentNode&&!e.isSimulated&&!e.isTrigger&&v.event.simulate("change",this.parentNode,e,!0)}),v._data(t,"_change_attached",!0))})},handle:function(e){var t=e.target;if(this!==t||e.isSimulated||e.isTrigger||t.type!=="radio"&&t.type!=="checkbox")return e.handleObj.handler.apply(this,arguments)},teardown:function(){return v.event.remove(this,"._change"),!$.test(this.nodeName)}}),v.support.focusinBubbles||v.each({focus:"focusin",blur:"focusout"},function(e,t){var n=0,r=function(e){v.event.simulate(t,e.target,v.event.fix(e),!0)};v.event.special[t]={setup:function(){n++===0&&i.addEventListener(e,r,!0)},teardown:function(){--n===0&&i.removeEventListener(e,r,!0)}}}),v.fn.extend({on:function(e,n,r,i,s){var o,u;if(typeof e=="object"){typeof n!="string"&&(r=r||n,n=t);for(u in e)this.on(u,n,r,e[u],s);return this}r==null&&i==null?(i=n,r=n=t):i==null&&(typeof n=="string"?(i=r,r=t):(i=r,r=n,n=t));if(i===!1)i=et;else if(!i)return this;return s===1&&(o=i,i=function(e){return v().off(e),o.apply(this,arguments)},i.guid=o.guid||(o.guid=v.guid++)),this.each(function(){v.event.add(this,e,i,r,n)})},one:function(e,t,n,r){return this.on(e,t,n,r,1)},off:function(e,n,r){var i,s;if(e&&e.preventDefault&&e.handleObj)return i=e.handleObj,v(e.delegateTarget).off(i.namespace?i.origType+"."+i.namespace:i.origType,i.selector,i.handler),this;if(typeof e=="object"){for(s in e)this.off(s,n,e[s]);return this}if(n===!1||typeof n=="function")r=n,n=t;return r===!1&&(r=et),this.each(function(){v.event.remove(this,e,r,n)})},bind:function(e,t,n){return this.on(e,null,t,n)},unbind:function(e,t){return this.off(e,null,t)},live:function(e,t,n){return v(this.context).on(e,this.selector,t,n),this},die:function(e,t){return v(this.context).off(e,this.selector||"**",t),this},delegate:function(e,t,n,r){return this.on(t,e,n,r)},undelegate:function(e,t,n){return arguments.length===1?this.off(e,"**"):this.off(t,e||"**",n)},trigger:function(e,t){return this.each(function(){v.event.trigger(e,t,this)})},triggerHandler:function(e,t){if(this[0])return v.event.trigger(e,t,this[0],!0)},toggle:function(e){var t=arguments,n=e.guid||v.guid++,r=0,i=function(n){var i=(v._data(this,"lastToggle"+e.guid)||0)%r;return v._data(this,"lastToggle"+e.guid,i+1),n.preventDefault(),t[i].apply(this,arguments)||!1};i.guid=n;while(r<t.length)t[r++].guid=n;return this.click(i)},hover:function(e,t){return this.mouseenter(e).mouseleave(t||e)}}),v.each("blur focus focusin focusout load resize scroll unload click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup error contextmenu".split(" "),function(e,t){v.fn[t]=function(e,n){return n==null&&(n=e,e=null),arguments.length>0?this.on(t,null,e,n):this.trigger(t)},Q.test(t)&&(v.event.fixHooks[t]=v.event.keyHooks),G.test(t)&&(v.event.fixHooks[t]=v.event.mouseHooks)}),function(e,t){function nt(e,t,n,r){n=n||[],t=t||g;var i,s,a,f,l=t.nodeType;if(!e||typeof e!="string")return n;if(l!==1&&l!==9)return[];a=o(t);if(!a&&!r)if(i=R.exec(e))if(f=i[1]){if(l===9){s=t.getElementById(f);if(!s||!s.parentNode)return n;if(s.id===f)return n.push(s),n}else if(t.ownerDocument&&(s=t.ownerDocument.getElementById(f))&&u(t,s)&&s.id===f)return n.push(s),n}else{if(i[2])return S.apply(n,x.call(t.getElementsByTagName(e),0)),n;if((f=i[3])&&Z&&t.getElementsByClassName)return S.apply(n,x.call(t.getElementsByClassName(f),0)),n}return vt(e.replace(j,"$1"),t,n,r,a)}function rt(e){return function(t){var n=t.nodeName.toLowerCase();return n==="input"&&t.type===e}}function it(e){return function(t){var n=t.nodeName.toLowerCase();return(n==="input"||n==="button")&&t.type===e}}function st(e){return N(function(t){return t=+t,N(function(n,r){var i,s=e([],n.length,t),o=s.length;while(o--)n[i=s[o]]&&(n[i]=!(r[i]=n[i]))})})}function ot(e,t,n){if(e===t)return n;var r=e.nextSibling;while(r){if(r===t)return-1;r=r.nextSibling}return 1}function ut(e,t){var n,r,s,o,u,a,f,l=L[d][e+" "];if(l)return t?0:l.slice(0);u=e,a=[],f=i.preFilter;while(u){if(!n||(r=F.exec(u)))r&&(u=u.slice(r[0].length)||u),a.push(s=[]);n=!1;if(r=I.exec(u))s.push(n=new m(r.shift())),u=u.slice(n.length),n.type=r[0].replace(j," ");for(o in i.filter)(r=J[o].exec(u))&&(!f[o]||(r=f[o](r)))&&(s.push(n=new m(r.shift())),u=u.slice(n.length),n.type=o,n.matches=r);if(!n)break}return t?u.length:u?nt.error(e):L(e,a).slice(0)}function at(e,t,r){var i=t.dir,s=r&&t.dir==="parentNode",o=w++;return t.first?function(t,n,r){while(t=t[i])if(s||t.nodeType===1)return e(t,n,r)}:function(t,r,u){if(!u){var a,f=b+" "+o+" ",l=f+n;while(t=t[i])if(s||t.nodeType===1){if((a=t[d])===l)return t.sizset;if(typeof a=="string"&&a.indexOf(f)===0){if(t.sizset)return t}else{t[d]=l;if(e(t,r,u))return t.sizset=!0,t;t.sizset=!1}}}else while(t=t[i])if(s||t.nodeType===1)if(e(t,r,u))return t}}function ft(e){return e.length>1?function(t,n,r){var i=e.length;while(i--)if(!e[i](t,n,r))return!1;return!0}:e[0]}function lt(e,t,n,r,i){var s,o=[],u=0,a=e.length,f=t!=null;for(;u<a;u++)if(s=e[u])if(!n||n(s,r,i))o.push(s),f&&t.push(u);return o}function ct(e,t,n,r,i,s){return r&&!r[d]&&(r=ct(r)),i&&!i[d]&&(i=ct(i,s)),N(function(s,o,u,a){var f,l,c,h=[],p=[],d=o.length,v=s||dt(t||"*",u.nodeType?[u]:u,[]),m=e&&(s||!t)?lt(v,h,e,u,a):v,g=n?i||(s?e:d||r)?[]:o:m;n&&n(m,g,u,a);if(r){f=lt(g,p),r(f,[],u,a),l=f.length;while(l--)if(c=f[l])g[p[l]]=!(m[p[l]]=c)}if(s){if(i||e){if(i){f=[],l=g.length;while(l--)(c=g[l])&&f.push(m[l]=c);i(null,g=[],f,a)}l=g.length;while(l--)(c=g[l])&&(f=i?T.call(s,c):h[l])>-1&&(s[f]=!(o[f]=c))}}else g=lt(g===o?g.splice(d,g.length):g),i?i(null,o,g,a):S.apply(o,g)})}function ht(e){var t,n,r,s=e.length,o=i.relative[e[0].type],u=o||i.relative[" "],a=o?1:0,f=at(function(e){return e===t},u,!0),l=at(function(e){return T.call(t,e)>-1},u,!0),h=[function(e,n,r){return!o&&(r||n!==c)||((t=n).nodeType?f(e,n,r):l(e,n,r))}];for(;a<s;a++)if(n=i.relative[e[a].type])h=[at(ft(h),n)];else{n=i.filter[e[a].type].apply(null,e[a].matches);if(n[d]){r=++a;for(;r<s;r++)if(i.relative[e[r].type])break;return ct(a>1&&ft(h),a>1&&e.slice(0,a-1).join("").replace(j,"$1"),n,a<r&&ht(e.slice(a,r)),r<s&&ht(e=e.slice(r)),r<s&&e.join(""))}h.push(n)}return ft(h)}function pt(e,t){var r=t.length>0,s=e.length>0,o=function(u,a,f,l,h){var p,d,v,m=[],y=0,w="0",x=u&&[],T=h!=null,N=c,C=u||s&&i.find.TAG("*",h&&a.parentNode||a),k=b+=N==null?1:Math.E;T&&(c=a!==g&&a,n=o.el);for(;(p=C[w])!=null;w++){if(s&&p){for(d=0;v=e[d];d++)if(v(p,a,f)){l.push(p);break}T&&(b=k,n=++o.el)}r&&((p=!v&&p)&&y--,u&&x.push(p))}y+=w;if(r&&w!==y){for(d=0;v=t[d];d++)v(x,m,a,f);if(u){if(y>0)while(w--)!x[w]&&!m[w]&&(m[w]=E.call(l));m=lt(m)}S.apply(l,m),T&&!u&&m.length>0&&y+t.length>1&&nt.uniqueSort(l)}return T&&(b=k,c=N),x};return o.el=0,r?N(o):o}function dt(e,t,n){var r=0,i=t.length;for(;r<i;r++)nt(e,t[r],n);return n}function vt(e,t,n,r,s){var o,u,f,l,c,h=ut(e),p=h.length;if(!r&&h.length===1){u=h[0]=h[0].slice(0);if(u.length>2&&(f=u[0]).type==="ID"&&t.nodeType===9&&!s&&i.relative[u[1].type]){t=i.find.ID(f.matches[0].replace($,""),t,s)[0];if(!t)return n;e=e.slice(u.shift().length)}for(o=J.POS.test(e)?-1:u.length-1;o>=0;o--){f=u[o];if(i.relative[l=f.type])break;if(c=i.find[l])if(r=c(f.matches[0].replace($,""),z.test(u[0].type)&&t.parentNode||t,s)){u.splice(o,1),e=r.length&&u.join("");if(!e)return S.apply(n,x.call(r,0)),n;break}}}return a(e,h)(r,t,s,n,z.test(e)),n}function mt(){}var n,r,i,s,o,u,a,f,l,c,h=!0,p="undefined",d=("sizcache"+Math.random()).replace(".",""),m=String,g=e.document,y=g.documentElement,b=0,w=0,E=[].pop,S=[].push,x=[].slice,T=[].indexOf||function(e){var t=0,n=this.length;for(;t<n;t++)if(this[t]===e)return t;return-1},N=function(e,t){return e[d]=t==null||t,e},C=function(){var e={},t=[];return N(function(n,r){return t.push(n)>i.cacheLength&&delete e[t.shift()],e[n+" "]=r},e)},k=C(),L=C(),A=C(),O="[\\x20\\t\\r\\n\\f]",M="(?:\\\\.|[-\\w]|[^\\x00-\\xa0])+",_=M.replace("w","w#"),D="([*^$|!~]?=)",P="\\["+O+"*("+M+")"+O+"*(?:"+D+O+"*(?:(['\"])((?:\\\\.|[^\\\\])*?)\\3|("+_+")|)|)"+O+"*\\]",H=":("+M+")(?:\\((?:(['\"])((?:\\\\.|[^\\\\])*?)\\2|([^()[\\]]*|(?:(?:"+P+")|[^:]|\\\\.)*|.*))\\)|)",B=":(even|odd|eq|gt|lt|nth|first|last)(?:\\("+O+"*((?:-\\d)?\\d*)"+O+"*\\)|)(?=[^-]|$)",j=new RegExp("^"+O+"+|((?:^|[^\\\\])(?:\\\\.)*)"+O+"+$","g"),F=new RegExp("^"+O+"*,"+O+"*"),I=new RegExp("^"+O+"*([\\x20\\t\\r\\n\\f>+~])"+O+"*"),q=new RegExp(H),R=/^(?:#([\w\-]+)|(\w+)|\.([\w\-]+))$/,U=/^:not/,z=/[\x20\t\r\n\f]*[+~]/,W=/:not\($/,X=/h\d/i,V=/input|select|textarea|button/i,$=/\\(?!\\)/g,J={ID:new RegExp("^#("+M+")"),CLASS:new RegExp("^\\.("+M+")"),NAME:new RegExp("^\\[name=['\"]?("+M+")['\"]?\\]"),TAG:new RegExp("^("+M.replace("w","w*")+")"),ATTR:new RegExp("^"+P),PSEUDO:new RegExp("^"+H),POS:new RegExp(B,"i"),CHILD:new RegExp("^:(only|nth|first|last)-child(?:\\("+O+"*(even|odd|(([+-]|)(\\d*)n|)"+O+"*(?:([+-]|)"+O+"*(\\d+)|))"+O+"*\\)|)","i"),needsContext:new RegExp("^"+O+"*[>+~]|"+B,"i")},K=function(e){var t=g.createElement("div");try{return e(t)}catch(n){return!1}finally{t=null}},Q=K(function(e){return e.appendChild(g.createComment("")),!e.getElementsByTagName("*").length}),G=K(function(e){return e.innerHTML="<a href='#'></a>",e.firstChild&&typeof e.firstChild.getAttribute!==p&&e.firstChild.getAttribute("href")==="#"}),Y=K(function(e){e.innerHTML="<select></select>";var t=typeof e.lastChild.getAttribute("multiple");return t!=="boolean"&&t!=="string"}),Z=K(function(e){return e.innerHTML="<div class='hidden e'></div><div class='hidden'></div>",!e.getElementsByClassName||!e.getElementsByClassName("e").length?!1:(e.lastChild.className="e",e.getElementsByClassName("e").length===2)}),et=K(function(e){e.id=d+0,e.innerHTML="<a name='"+d+"'></a><div name='"+d+"'></div>",y.insertBefore(e,y.firstChild);var t=g.getElementsByName&&g.getElementsByName(d).length===2+g.getElementsByName(d+0).length;return r=!g.getElementById(d),y.removeChild(e),t});try{x.call(y.childNodes,0)[0].nodeType}catch(tt){x=function(e){var t,n=[];for(;t=this[e];e++)n.push(t);return n}}nt.matches=function(e,t){return nt(e,null,null,t)},nt.matchesSelector=function(e,t){return nt(t,null,null,[e]).length>0},s=nt.getText=function(e){var t,n="",r=0,i=e.nodeType;if(i){if(i===1||i===9||i===11){if(typeof e.textContent=="string")return e.textContent;for(e=e.firstChild;e;e=e.nextSibling)n+=s(e)}else if(i===3||i===4)return e.nodeValue}else for(;t=e[r];r++)n+=s(t);return n},o=nt.isXML=function(e){var t=e&&(e.ownerDocument||e).documentElement;return t?t.nodeName!=="HTML":!1},u=nt.contains=y.contains?function(e,t){var n=e.nodeType===9?e.documentElement:e,r=t&&t.parentNode;return e===r||!!(r&&r.nodeType===1&&n.contains&&n.contains(r))}:y.compareDocumentPosition?function(e,t){return t&&!!(e.compareDocumentPosition(t)&16)}:function(e,t){while(t=t.parentNode)if(t===e)return!0;return!1},nt.attr=function(e,t){var n,r=o(e);return r||(t=t.toLowerCase()),(n=i.attrHandle[t])?n(e):r||Y?e.getAttribute(t):(n=e.getAttributeNode(t),n?typeof e[t]=="boolean"?e[t]?t:null:n.specified?n.value:null:null)},i=nt.selectors={cacheLength:50,createPseudo:N,match:J,attrHandle:G?{}:{href:function(e){return e.getAttribute("href",2)},type:function(e){return e.getAttribute("type")}},find:{ID:r?function(e,t,n){if(typeof t.getElementById!==p&&!n){var r=t.getElementById(e);return r&&r.parentNode?[r]:[]}}:function(e,n,r){if(typeof n.getElementById!==p&&!r){var i=n.getElementById(e);return i?i.id===e||typeof i.getAttributeNode!==p&&i.getAttributeNode("id").value===e?[i]:t:[]}},TAG:Q?function(e,t){if(typeof t.getElementsByTagName!==p)return t.getElementsByTagName(e)}:function(e,t){var n=t.getElementsByTagName(e);if(e==="*"){var r,i=[],s=0;for(;r=n[s];s++)r.nodeType===1&&i.push(r);return i}return n},NAME:et&&function(e,t){if(typeof t.getElementsByName!==p)return t.getElementsByName(name)},CLASS:Z&&function(e,t,n){if(typeof t.getElementsByClassName!==p&&!n)return t.getElementsByClassName(e)}},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(e){return e[1]=e[1].replace($,""),e[3]=(e[4]||e[5]||"").replace($,""),e[2]==="~="&&(e[3]=" "+e[3]+" "),e.slice(0,4)},CHILD:function(e){return e[1]=e[1].toLowerCase(),e[1]==="nth"?(e[2]||nt.error(e[0]),e[3]=+(e[3]?e[4]+(e[5]||1):2*(e[2]==="even"||e[2]==="odd")),e[4]=+(e[6]+e[7]||e[2]==="odd")):e[2]&&nt.error(e[0]),e},PSEUDO:function(e){var t,n;if(J.CHILD.test(e[0]))return null;if(e[3])e[2]=e[3];else if(t=e[4])q.test(t)&&(n=ut(t,!0))&&(n=t.indexOf(")",t.length-n)-t.length)&&(t=t.slice(0,n),e[0]=e[0].slice(0,n)),e[2]=t;return e.slice(0,3)}},filter:{ID:r?function(e){return e=e.replace($,""),function(t){return t.getAttribute("id")===e}}:function(e){return e=e.replace($,""),function(t){var n=typeof t.getAttributeNode!==p&&t.getAttributeNode("id");return n&&n.value===e}},TAG:function(e){return e==="*"?function(){return!0}:(e=e.replace($,"").toLowerCase(),function(t){return t.nodeName&&t.nodeName.toLowerCase()===e})},CLASS:function(e){var t=k[d][e+" "];return t||(t=new RegExp("(^|"+O+")"+e+"("+O+"|$)"))&&k(e,function(e){return t.test(e.className||typeof e.getAttribute!==p&&e.getAttribute("class")||"")})},ATTR:function(e,t,n){return function(r,i){var s=nt.attr(r,e);return s==null?t==="!=":t?(s+="",t==="="?s===n:t==="!="?s!==n:t==="^="?n&&s.indexOf(n)===0:t==="*="?n&&s.indexOf(n)>-1:t==="$="?n&&s.substr(s.length-n.length)===n:t==="~="?(" "+s+" ").indexOf(n)>-1:t==="|="?s===n||s.substr(0,n.length+1)===n+"-":!1):!0}},CHILD:function(e,t,n,r){return e==="nth"?function(e){var t,i,s=e.parentNode;if(n===1&&r===0)return!0;if(s){i=0;for(t=s.firstChild;t;t=t.nextSibling)if(t.nodeType===1){i++;if(e===t)break}}return i-=r,i===n||i%n===0&&i/n>=0}:function(t){var n=t;switch(e){case"only":case"first":while(n=n.previousSibling)if(n.nodeType===1)return!1;if(e==="first")return!0;n=t;case"last":while(n=n.nextSibling)if(n.nodeType===1)return!1;return!0}}},PSEUDO:function(e,t){var n,r=i.pseudos[e]||i.setFilters[e.toLowerCase()]||nt.error("unsupported pseudo: "+e);return r[d]?r(t):r.length>1?(n=[e,e,"",t],i.setFilters.hasOwnProperty(e.toLowerCase())?N(function(e,n){var i,s=r(e,t),o=s.length;while(o--)i=T.call(e,s[o]),e[i]=!(n[i]=s[o])}):function(e){return r(e,0,n)}):r}},pseudos:{not:N(function(e){var t=[],n=[],r=a(e.replace(j,"$1"));return r[d]?N(function(e,t,n,i){var s,o=r(e,null,i,[]),u=e.length;while(u--)if(s=o[u])e[u]=!(t[u]=s)}):function(e,i,s){return t[0]=e,r(t,null,s,n),!n.pop()}}),has:N(function(e){return function(t){return nt(e,t).length>0}}),contains:N(function(e){return function(t){return(t.textContent||t.innerText||s(t)).indexOf(e)>-1}}),enabled:function(e){return e.disabled===!1},disabled:function(e){return e.disabled===!0},checked:function(e){var t=e.nodeName.toLowerCase();return t==="input"&&!!e.checked||t==="option"&&!!e.selected},selected:function(e){return e.parentNode&&e.parentNode.selectedIndex,e.selected===!0},parent:function(e){return!i.pseudos.empty(e)},empty:function(e){var t;e=e.firstChild;while(e){if(e.nodeName>"@"||(t=e.nodeType)===3||t===4)return!1;e=e.nextSibling}return!0},header:function(e){return X.test(e.nodeName)},text:function(e){var t,n;return e.nodeName.toLowerCase()==="input"&&(t=e.type)==="text"&&((n=e.getAttribute("type"))==null||n.toLowerCase()===t)},radio:rt("radio"),checkbox:rt("checkbox"),file:rt("file"),password:rt("password"),image:rt("image"),submit:it("submit"),reset:it("reset"),button:function(e){var t=e.nodeName.toLowerCase();return t==="input"&&e.type==="button"||t==="button"},input:function(e){return V.test(e.nodeName)},focus:function(e){var t=e.ownerDocument;return e===t.activeElement&&(!t.hasFocus||t.hasFocus())&&!!(e.type||e.href||~e.tabIndex)},active:function(e){return e===e.ownerDocument.activeElement},first:st(function(){return[0]}),last:st(function(e,t){return[t-1]}),eq:st(function(e,t,n){return[n<0?n+t:n]}),even:st(function(e,t){for(var n=0;n<t;n+=2)e.push(n);return e}),odd:st(function(e,t){for(var n=1;n<t;n+=2)e.push(n);return e}),lt:st(function(e,t,n){for(var r=n<0?n+t:n;--r>=0;)e.push(r);return e}),gt:st(function(e,t,n){for(var r=n<0?n+t:n;++r<t;)e.push(r);return e})}},f=y.compareDocumentPosition?function(e,t){return e===t?(l=!0,0):(!e.compareDocumentPosition||!t.compareDocumentPosition?e.compareDocumentPosition:e.compareDocumentPosition(t)&4)?-1:1}:function(e,t){if(e===t)return l=!0,0;if(e.sourceIndex&&t.sourceIndex)return e.sourceIndex-t.sourceIndex;var n,r,i=[],s=[],o=e.parentNode,u=t.parentNode,a=o;if(o===u)return ot(e,t);if(!o)return-1;if(!u)return 1;while(a)i.unshift(a),a=a.parentNode;a=u;while(a)s.unshift(a),a=a.parentNode;n=i.length,r=s.length;for(var f=0;f<n&&f<r;f++)if(i[f]!==s[f])return ot(i[f],s[f]);return f===n?ot(e,s[f],-1):ot(i[f],t,1)},[0,0].sort(f),h=!l,nt.uniqueSort=function(e){var t,n=[],r=1,i=0;l=h,e.sort(f);if(l){for(;t=e[r];r++)t===e[r-1]&&(i=n.push(r));while(i--)e.splice(n[i],1)}return e},nt.error=function(e){throw new Error("Syntax error, unrecognized expression: "+e)},a=nt.compile=function(e,t){var n,r=[],i=[],s=A[d][e+" "];if(!s){t||(t=ut(e)),n=t.length;while(n--)s=ht(t[n]),s[d]?r.push(s):i.push(s);s=A(e,pt(i,r))}return s},g.querySelectorAll&&function(){var e,t=vt,n=/'|\\/g,r=/\=[\x20\t\r\n\f]*([^'"\]]*)[\x20\t\r\n\f]*\]/g,i=[":focus"],s=[":active"],u=y.matchesSelector||y.mozMatchesSelector||y.webkitMatchesSelector||y.oMatchesSelector||y.msMatchesSelector;K(function(e){e.innerHTML="<select><option selected=''></option></select>",e.querySelectorAll("[selected]").length||i.push("\\["+O+"*(?:checked|disabled|ismap|multiple|readonly|selected|value)"),e.querySelectorAll(":checked").length||i.push(":checked")}),K(function(e){e.innerHTML="<p test=''></p>",e.querySelectorAll("[test^='']").length&&i.push("[*^$]="+O+"*(?:\"\"|'')"),e.innerHTML="<input type='hidden'/>",e.querySelectorAll(":enabled").length||i.push(":enabled",":disabled")}),i=new RegExp(i.join("|")),vt=function(e,r,s,o,u){if(!o&&!u&&!i.test(e)){var a,f,l=!0,c=d,h=r,p=r.nodeType===9&&e;if(r.nodeType===1&&r.nodeName.toLowerCase()!=="object"){a=ut(e),(l=r.getAttribute("id"))?c=l.replace(n,"\\$&"):r.setAttribute("id",c),c="[id='"+c+"'] ",f=a.length;while(f--)a[f]=c+a[f].join("");h=z.test(e)&&r.parentNode||r,p=a.join(",")}if(p)try{return S.apply(s,x.call(h.querySelectorAll(p),0)),s}catch(v){}finally{l||r.removeAttribute("id")}}return t(e,r,s,o,u)},u&&(K(function(t){e=u.call(t,"div");try{u.call(t,"[test!='']:sizzle"),s.push("!=",H)}catch(n){}}),s=new RegExp(s.join("|")),nt.matchesSelector=function(t,n){n=n.replace(r,"='$1']");if(!o(t)&&!s.test(n)&&!i.test(n))try{var a=u.call(t,n);if(a||e||t.document&&t.document.nodeType!==11)return a}catch(f){}return nt(n,null,null,[t]).length>0})}(),i.pseudos.nth=i.pseudos.eq,i.filters=mt.prototype=i.pseudos,i.setFilters=new mt,nt.attr=v.attr,v.find=nt,v.expr=nt.selectors,v.expr[":"]=v.expr.pseudos,v.unique=nt.uniqueSort,v.text=nt.getText,v.isXMLDoc=nt.isXML,v.contains=nt.contains}(e);var nt=/Until$/,rt=/^(?:parents|prev(?:Until|All))/,it=/^.[^:#\[\.,]*$/,st=v.expr.match.needsContext,ot={children:!0,contents:!0,next:!0,prev:!0};v.fn.extend({find:function(e){var t,n,r,i,s,o,u=this;if(typeof e!="string")return v(e).filter(function(){for(t=0,n=u.length;t<n;t++)if(v.contains(u[t],this))return!0});o=this.pushStack("","find",e);for(t=0,n=this.length;t<n;t++){r=o.length,v.find(e,this[t],o);if(t>0)for(i=r;i<o.length;i++)for(s=0;s<r;s++)if(o[s]===o[i]){o.splice(i--,1);break}}return o},has:function(e){var t,n=v(e,this),r=n.length;return this.filter(function(){for(t=0;t<r;t++)if(v.contains(this,n[t]))return!0})},not:function(e){return this.pushStack(ft(this,e,!1),"not",e)},filter:function(e){return this.pushStack(ft(this,e,!0),"filter",e)},is:function(e){return!!e&&(typeof e=="string"?st.test(e)?v(e,this.context).index(this[0])>=0:v.filter(e,this).length>0:this.filter(e).length>0)},closest:function(e,t){var n,r=0,i=this.length,s=[],o=st.test(e)||typeof e!="string"?v(e,t||this.context):0;for(;r<i;r++){n=this[r];while(n&&n.ownerDocument&&n!==t&&n.nodeType!==11){if(o?o.index(n)>-1:v.find.matchesSelector(n,e)){s.push(n);break}n=n.parentNode}}return s=s.length>1?v.unique(s):s,this.pushStack(s,"closest",e)},index:function(e){return e?typeof e=="string"?v.inArray(this[0],v(e)):v.inArray(e.jquery?e[0]:e,this):this[0]&&this[0].parentNode?this.prevAll().length:-1},add:function(e,t){var n=typeof e=="string"?v(e,t):v.makeArray(e&&e.nodeType?[e]:e),r=v.merge(this.get(),n);return this.pushStack(ut(n[0])||ut(r[0])?r:v.unique(r))},addBack:function(e){return this.add(e==null?this.prevObject:this.prevObject.filter(e))}}),v.fn.andSelf=v.fn.addBack,v.each({parent:function(e){var t=e.parentNode;return t&&t.nodeType!==11?t:null},parents:function(e){return v.dir(e,"parentNode")},parentsUntil:function(e,t,n){return v.dir(e,"parentNode",n)},next:function(e){return at(e,"nextSibling")},prev:function(e){return at(e,"previousSibling")},nextAll:function(e){return v.dir(e,"nextSibling")},prevAll:function(e){return v.dir(e,"previousSibling")},nextUntil:function(e,t,n){return v.dir(e,"nextSibling",n)},prevUntil:function(e,t,n){return v.dir(e,"previousSibling",n)},siblings:function(e){return v.sibling((e.parentNode||{}).firstChild,e)},children:function(e){return v.sibling(e.firstChild)},contents:function(e){return v.nodeName(e,"iframe")?e.contentDocument||e.contentWindow.document:v.merge([],e.childNodes)}},function(e,t){v.fn[e]=function(n,r){var i=v.map(this,t,n);return nt.test(e)||(r=n),r&&typeof r=="string"&&(i=v.filter(r,i)),i=this.length>1&&!ot[e]?v.unique(i):i,this.length>1&&rt.test(e)&&(i=i.reverse()),this.pushStack(i,e,l.call(arguments).join(","))}}),v.extend({filter:function(e,t,n){return n&&(e=":not("+e+")"),t.length===1?v.find.matchesSelector(t[0],e)?[t[0]]:[]:v.find.matches(e,t)},dir:function(e,n,r){var i=[],s=e[n];while(s&&s.nodeType!==9&&(r===t||s.nodeType!==1||!v(s).is(r)))s.nodeType===1&&i.push(s),s=s[n];return i},sibling:function(e,t){var n=[];for(;e;e=e.nextSibling)e.nodeType===1&&e!==t&&n.push(e);return n}});var ct="abbr|article|aside|audio|bdi|canvas|data|datalist|details|figcaption|figure|footer|header|hgroup|mark|meter|nav|output|progress|section|summary|time|video",ht=/ jQuery\d+="(?:null|\d+)"/g,pt=/^\s+/,dt=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/gi,vt=/<([\w:]+)/,mt=/<tbody/i,gt=/<|&#?\w+;/,yt=/<(?:script|style|link)/i,bt=/<(?:script|object|embed|option|style)/i,wt=new RegExp("<(?:"+ct+")[\\s/>]","i"),Et=/^(?:checkbox|radio)$/,St=/checked\s*(?:[^=]|=\s*.checked.)/i,xt=/\/(java|ecma)script/i,Tt=/^\s*<!(?:\[CDATA\[|\-\-)|[\]\-]{2}>\s*$/g,Nt={option:[1,"<select multiple='multiple'>","</select>"],legend:[1,"<fieldset>","</fieldset>"],thead:[1,"<table>","</table>"],tr:[2,"<table><tbody>","</tbody></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],col:[2,"<table><tbody></tbody><colgroup>","</colgroup></table>"],area:[1,"<map>","</map>"],_default:[0,"",""]},Ct=lt(i),kt=Ct.appendChild(i.createElement("div"));Nt.optgroup=Nt.option,Nt.tbody=Nt.tfoot=Nt.colgroup=Nt.caption=Nt.thead,Nt.th=Nt.td,v.support.htmlSerialize||(Nt._default=[1,"X<div>","</div>"]),v.fn.extend({text:function(e){return v.access(this,function(e){return e===t?v.text(this):this.empty().append((this[0]&&this[0].ownerDocument||i).createTextNode(e))},null,e,arguments.length)},wrapAll:function(e){if(v.isFunction(e))return this.each(function(t){v(this).wrapAll(e.call(this,t))});if(this[0]){var t=v(e,this[0].ownerDocument).eq(0).clone(!0);this[0].parentNode&&t.insertBefore(this[0]),t.map(function(){var e=this;while(e.firstChild&&e.firstChild.nodeType===1)e=e.firstChild;return e}).append(this)}return this},wrapInner:function(e){return v.isFunction(e)?this.each(function(t){v(this).wrapInner(e.call(this,t))}):this.each(function(){var t=v(this),n=t.contents();n.length?n.wrapAll(e):t.append(e)})},wrap:function(e){var t=v.isFunction(e);return this.each(function(n){v(this).wrapAll(t?e.call(this,n):e)})},unwrap:function(){return this.parent().each(function(){v.nodeName(this,"body")||v(this).replaceWith(this.childNodes)}).end()},append:function(){return this.domManip(arguments,!0,function(e){(this.nodeType===1||this.nodeType===11)&&this.appendChild(e)})},prepend:function(){return this.domManip(arguments,!0,function(e){(this.nodeType===1||this.nodeType===11)&&this.insertBefore(e,this.firstChild)})},before:function(){if(!ut(this[0]))return this.domManip(arguments,!1,function(e){this.parentNode.insertBefore(e,this)});if(arguments.length){var e=v.clean(arguments);return this.pushStack(v.merge(e,this),"before",this.selector)}},after:function(){if(!ut(this[0]))return this.domManip(arguments,!1,function(e){this.parentNode.insertBefore(e,this.nextSibling)});if(arguments.length){var e=v.clean(arguments);return this.pushStack(v.merge(this,e),"after",this.selector)}},remove:function(e,t){var n,r=0;for(;(n=this[r])!=null;r++)if(!e||v.filter(e,[n]).length)!t&&n.nodeType===1&&(v.cleanData(n.getElementsByTagName("*")),v.cleanData([n])),n.parentNode&&n.parentNode.removeChild(n);return this},empty:function(){var e,t=0;for(;(e=this[t])!=null;t++){e.nodeType===1&&v.cleanData(e.getElementsByTagName("*"));while(e.firstChild)e.removeChild(e.firstChild)}return this},clone:function(e,t){return e=e==null?!1:e,t=t==null?e:t,this.map(function(){return v.clone(this,e,t)})},html:function(e){return v.access(this,function(e){var n=this[0]||{},r=0,i=this.length;if(e===t)return n.nodeType===1?n.innerHTML.replace(ht,""):t;if(typeof e=="string"&&!yt.test(e)&&(v.support.htmlSerialize||!wt.test(e))&&(v.support.leadingWhitespace||!pt.test(e))&&!Nt[(vt.exec(e)||["",""])[1].toLowerCase()]){e=e.replace(dt,"<$1></$2>");try{for(;r<i;r++)n=this[r]||{},n.nodeType===1&&(v.cleanData(n.getElementsByTagName("*")),n.innerHTML=e);n=0}catch(s){}}n&&this.empty().append(e)},null,e,arguments.length)},replaceWith:function(e){return ut(this[0])?this.length?this.pushStack(v(v.isFunction(e)?e():e),"replaceWith",e):this:v.isFunction(e)?this.each(function(t){var n=v(this),r=n.html();n.replaceWith(e.call(this,t,r))}):(typeof e!="string"&&(e=v(e).detach()),this.each(function(){var t=this.nextSibling,n=this.parentNode;v(this).remove(),t?v(t).before(e):v(n).append(e)}))},detach:function(e){return this.remove(e,!0)},domManip:function(e,n,r){e=[].concat.apply([],e);var i,s,o,u,a=0,f=e[0],l=[],c=this.length;if(!v.support.checkClone&&c>1&&typeof f=="string"&&St.test(f))return this.each(function(){v(this).domManip(e,n,r)});if(v.isFunction(f))return this.each(function(i){var s=v(this);e[0]=f.call(this,i,n?s.html():t),s.domManip(e,n,r)});if(this[0]){i=v.buildFragment(e,this,l),o=i.fragment,s=o.firstChild,o.childNodes.length===1&&(o=s);if(s){n=n&&v.nodeName(s,"tr");for(u=i.cacheable||c-1;a<c;a++)r.call(n&&v.nodeName(this[a],"table")?Lt(this[a],"tbody"):this[a],a===u?o:v.clone(o,!0,!0))}o=s=null,l.length&&v.each(l,function(e,t){t.src?v.ajax?v.ajax({url:t.src,type:"GET",dataType:"script",async:!1,global:!1,"throws":!0}):v.error("no ajax"):v.globalEval((t.text||t.textContent||t.innerHTML||"").replace(Tt,"")),t.parentNode&&t.parentNode.removeChild(t)})}return this}}),v.buildFragment=function(e,n,r){var s,o,u,a=e[0];return n=n||i,n=!n.nodeType&&n[0]||n,n=n.ownerDocument||n,e.length===1&&typeof a=="string"&&a.length<512&&n===i&&a.charAt(0)==="<"&&!bt.test(a)&&(v.support.checkClone||!St.test(a))&&(v.support.html5Clone||!wt.test(a))&&(o=!0,s=v.fragments[a],u=s!==t),s||(s=n.createDocumentFragment(),v.clean(e,n,s,r),o&&(v.fragments[a]=u&&s)),{fragment:s,cacheable:o}},v.fragments={},v.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(e,t){v.fn[e]=function(n){var r,i=0,s=[],o=v(n),u=o.length,a=this.length===1&&this[0].parentNode;if((a==null||a&&a.nodeType===11&&a.childNodes.length===1)&&u===1)return o[t](this[0]),this;for(;i<u;i++)r=(i>0?this.clone(!0):this).get(),v(o[i])[t](r),s=s.concat(r);return this.pushStack(s,e,o.selector)}}),v.extend({clone:function(e,t,n){var r,i,s,o;v.support.html5Clone||v.isXMLDoc(e)||!wt.test("<"+e.nodeName+">")?o=e.cloneNode(!0):(kt.innerHTML=e.outerHTML,kt.removeChild(o=kt.firstChild));if((!v.support.noCloneEvent||!v.support.noCloneChecked)&&(e.nodeType===1||e.nodeType===11)&&!v.isXMLDoc(e)){Ot(e,o),r=Mt(e),i=Mt(o);for(s=0;r[s];++s)i[s]&&Ot(r[s],i[s])}if(t){At(e,o);if(n){r=Mt(e),i=Mt(o);for(s=0;r[s];++s)At(r[s],i[s])}}return r=i=null,o},clean:function(e,t,n,r){var s,o,u,a,f,l,c,h,p,d,m,g,y=t===i&&Ct,b=[];if(!t||typeof t.createDocumentFragment=="undefined")t=i;for(s=0;(u=e[s])!=null;s++){typeof u=="number"&&(u+="");if(!u)continue;if(typeof u=="string")if(!gt.test(u))u=t.createTextNode(u);else{y=y||lt(t),c=t.createElement("div"),y.appendChild(c),u=u.replace(dt,"<$1></$2>"),a=(vt.exec(u)||["",""])[1].toLowerCase(),f=Nt[a]||Nt._default,l=f[0],c.innerHTML=f[1]+u+f[2];while(l--)c=c.lastChild;if(!v.support.tbody){h=mt.test(u),p=a==="table"&&!h?c.firstChild&&c.firstChild.childNodes:f[1]==="<table>"&&!h?c.childNodes:[];for(o=p.length-1;o>=0;--o)v.nodeName(p[o],"tbody")&&!p[o].childNodes.length&&p[o].parentNode.removeChild(p[o])}!v.support.leadingWhitespace&&pt.test(u)&&c.insertBefore(t.createTextNode(pt.exec(u)[0]),c.firstChild),u=c.childNodes,c.parentNode.removeChild(c)}u.nodeType?b.push(u):v.merge(b,u)}c&&(u=c=y=null);if(!v.support.appendChecked)for(s=0;(u=b[s])!=null;s++)v.nodeName(u,"input")?_t(u):typeof u.getElementsByTagName!="undefined"&&v.grep(u.getElementsByTagName("input"),_t);if(n){m=function(e){if(!e.type||xt.test(e.type))return r?r.push(e.parentNode?e.parentNode.removeChild(e):e):n.appendChild(e)};for(s=0;(u=b[s])!=null;s++)if(!v.nodeName(u,"script")||!m(u))n.appendChild(u),typeof u.getElementsByTagName!="undefined"&&(g=v.grep(v.merge([],u.getElementsByTagName("script")),m),b.splice.apply(b,[s+1,0].concat(g)),s+=g.length)}return b},cleanData:function(e,t){var n,r,i,s,o=0,u=v.expando,a=v.cache,f=v.support.deleteExpando,l=v.event.special;for(;(i=e[o])!=null;o++)if(t||v.acceptData(i)){r=i[u],n=r&&a[r];if(n){if(n.events)for(s in n.events)l[s]?v.event.remove(i,s):v.removeEvent(i,s,n.handle);a[r]&&(delete a[r],f?delete i[u]:i.removeAttribute?i.removeAttribute(u):i[u]=null,v.deletedIds.push(r))}}}}),function(){var e,t;v.uaMatch=function(e){e=e.toLowerCase();var t=/(chrome)[ \/]([\w.]+)/.exec(e)||/(webkit)[ \/]([\w.]+)/.exec(e)||/(opera)(?:.*version|)[ \/]([\w.]+)/.exec(e)||/(msie) ([\w.]+)/.exec(e)||e.indexOf("compatible")<0&&/(mozilla)(?:.*? rv:([\w.]+)|)/.exec(e)||[];return{browser:t[1]||"",version:t[2]||"0"}},e=v.uaMatch(o.userAgent),t={},e.browser&&(t[e.browser]=!0,t.version=e.version),t.chrome?t.webkit=!0:t.webkit&&(t.safari=!0),v.browser=t,v.sub=function(){function e(t,n){return new e.fn.init(t,n)}v.extend(!0,e,this),e.superclass=this,e.fn=e.prototype=this(),e.fn.constructor=e,e.sub=this.sub,e.fn.init=function(r,i){return i&&i instanceof v&&!(i instanceof e)&&(i=e(i)),v.fn.init.call(this,r,i,t)},e.fn.init.prototype=e.fn;var t=e(i);return e}}();var Dt,Pt,Ht,Bt=/alpha\([^)]*\)/i,jt=/opacity=([^)]*)/,Ft=/^(top|right|bottom|left)$/,It=/^(none|table(?!-c[ea]).+)/,qt=/^margin/,Rt=new RegExp("^("+m+")(.*)$","i"),Ut=new RegExp("^("+m+")(?!px)[a-z%]+$","i"),zt=new RegExp("^([-+])=("+m+")","i"),Wt={BODY:"block"},Xt={position:"absolute",visibility:"hidden",display:"block"},Vt={letterSpacing:0,fontWeight:400},$t=["Top","Right","Bottom","Left"],Jt=["Webkit","O","Moz","ms"],Kt=v.fn.toggle;v.fn.extend({css:function(e,n){return v.access(this,function(e,n,r){return r!==t?v.style(e,n,r):v.css(e,n)},e,n,arguments.length>1)},show:function(){return Yt(this,!0)},hide:function(){return Yt(this)},toggle:function(e,t){var n=typeof e=="boolean";return v.isFunction(e)&&v.isFunction(t)?Kt.apply(this,arguments):this.each(function(){(n?e:Gt(this))?v(this).show():v(this).hide()})}}),v.extend({cssHooks:{opacity:{get:function(e,t){if(t){var n=Dt(e,"opacity");return n===""?"1":n}}}},cssNumber:{fillOpacity:!0,fontWeight:!0,lineHeight:!0,opacity:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{"float":v.support.cssFloat?"cssFloat":"styleFloat"},style:function(e,n,r,i){if(!e||e.nodeType===3||e.nodeType===8||!e.style)return;var s,o,u,a=v.camelCase(n),f=e.style;n=v.cssProps[a]||(v.cssProps[a]=Qt(f,a)),u=v.cssHooks[n]||v.cssHooks[a];if(r===t)return u&&"get"in u&&(s=u.get(e,!1,i))!==t?s:f[n];o=typeof r,o==="string"&&(s=zt.exec(r))&&(r=(s[1]+1)*s[2]+parseFloat(v.css(e,n)),o="number");if(r==null||o==="number"&&isNaN(r))return;o==="number"&&!v.cssNumber[a]&&(r+="px");if(!u||!("set"in u)||(r=u.set(e,r,i))!==t)try{f[n]=r}catch(l){}},css:function(e,n,r,i){var s,o,u,a=v.camelCase(n);return n=v.cssProps[a]||(v.cssProps[a]=Qt(e.style,a)),u=v.cssHooks[n]||v.cssHooks[a],u&&"get"in u&&(s=u.get(e,!0,i)),s===t&&(s=Dt(e,n)),s==="normal"&&n in Vt&&(s=Vt[n]),r||i!==t?(o=parseFloat(s),r||v.isNumeric(o)?o||0:s):s},swap:function(e,t,n){var r,i,s={};for(i in t)s[i]=e.style[i],e.style[i]=t[i];r=n.call(e);for(i in t)e.style[i]=s[i];return r}}),e.getComputedStyle?Dt=function(t,n){var r,i,s,o,u=e.getComputedStyle(t,null),a=t.style;return u&&(r=u.getPropertyValue(n)||u[n],r===""&&!v.contains(t.ownerDocument,t)&&(r=v.style(t,n)),Ut.test(r)&&qt.test(n)&&(i=a.width,s=a.minWidth,o=a.maxWidth,a.minWidth=a.maxWidth=a.width=r,r=u.width,a.width=i,a.minWidth=s,a.maxWidth=o)),r}:i.documentElement.currentStyle&&(Dt=function(e,t){var n,r,i=e.currentStyle&&e.currentStyle[t],s=e.style;return i==null&&s&&s[t]&&(i=s[t]),Ut.test(i)&&!Ft.test(t)&&(n=s.left,r=e.runtimeStyle&&e.runtimeStyle.left,r&&(e.runtimeStyle.left=e.currentStyle.left),s.left=t==="fontSize"?"1em":i,i=s.pixelLeft+"px",s.left=n,r&&(e.runtimeStyle.left=r)),i===""?"auto":i}),v.each(["height","width"],function(e,t){v.cssHooks[t]={get:function(e,n,r){if(n)return e.offsetWidth===0&&It.test(Dt(e,"display"))?v.swap(e,Xt,function(){return tn(e,t,r)}):tn(e,t,r)},set:function(e,n,r){return Zt(e,n,r?en(e,t,r,v.support.boxSizing&&v.css(e,"boxSizing")==="border-box"):0)}}}),v.support.opacity||(v.cssHooks.opacity={get:function(e,t){return jt.test((t&&e.currentStyle?e.currentStyle.filter:e.style.filter)||"")?.01*parseFloat(RegExp.$1)+"":t?"1":""},set:function(e,t){var n=e.style,r=e.currentStyle,i=v.isNumeric(t)?"alpha(opacity="+t*100+")":"",s=r&&r.filter||n.filter||"";n.zoom=1;if(t>=1&&v.trim(s.replace(Bt,""))===""&&n.removeAttribute){n.removeAttribute("filter");if(r&&!r.filter)return}n.filter=Bt.test(s)?s.replace(Bt,i):s+" "+i}}),v(function(){v.support.reliableMarginRight||(v.cssHooks.marginRight={get:function(e,t){return v.swap(e,{display:"inline-block"},function(){if(t)return Dt(e,"marginRight")})}}),!v.support.pixelPosition&&v.fn.position&&v.each(["top","left"],function(e,t){v.cssHooks[t]={get:function(e,n){if(n){var r=Dt(e,t);return Ut.test(r)?v(e).position()[t]+"px":r}}}})}),v.expr&&v.expr.filters&&(v.expr.filters.hidden=function(e){return e.offsetWidth===0&&e.offsetHeight===0||!v.support.reliableHiddenOffsets&&(e.style&&e.style.display||Dt(e,"display"))==="none"},v.expr.filters.visible=function(e){return!v.expr.filters.hidden(e)}),v.each({margin:"",padding:"",border:"Width"},function(e,t){v.cssHooks[e+t]={expand:function(n){var r,i=typeof n=="string"?n.split(" "):[n],s={};for(r=0;r<4;r++)s[e+$t[r]+t]=i[r]||i[r-2]||i[0];return s}},qt.test(e)||(v.cssHooks[e+t].set=Zt)});var rn=/%20/g,sn=/\[\]$/,on=/\r?\n/g,un=/^(?:color|date|datetime|datetime-local|email|hidden|month|number|password|range|search|tel|text|time|url|week)$/i,an=/^(?:select|textarea)/i;v.fn.extend({serialize:function(){return v.param(this.serializeArray())},serializeArray:function(){return this.map(function(){return this.elements?v.makeArray(this.elements):this}).filter(function(){return this.name&&!this.disabled&&(this.checked||an.test(this.nodeName)||un.test(this.type))}).map(function(e,t){var n=v(this).val();return n==null?null:v.isArray(n)?v.map(n,function(e,n){return{name:t.name,value:e.replace(on,"\r\n")}}):{name:t.name,value:n.replace(on,"\r\n")}}).get()}}),v.param=function(e,n){var r,i=[],s=function(e,t){t=v.isFunction(t)?t():t==null?"":t,i[i.length]=encodeURIComponent(e)+"="+encodeURIComponent(t)};n===t&&(n=v.ajaxSettings&&v.ajaxSettings.traditional);if(v.isArray(e)||e.jquery&&!v.isPlainObject(e))v.each(e,function(){s(this.name,this.value)});else for(r in e)fn(r,e[r],n,s);return i.join("&").replace(rn,"+")};var ln,cn,hn=/#.*$/,pn=/^(.*?):[ \t]*([^\r\n]*)\r?$/mg,dn=/^(?:about|app|app\-storage|.+\-extension|file|res|widget):$/,vn=/^(?:GET|HEAD)$/,mn=/^\/\//,gn=/\?/,yn=/<script\b[^<]*(?:(?!<\/script>)<[^<]*)*<\/script>/gi,bn=/([?&])_=[^&]*/,wn=/^([\w\+\.\-]+:)(?:\/\/([^\/?#:]*)(?::(\d+)|)|)/,En=v.fn.load,Sn={},xn={},Tn=["*/"]+["*"];try{cn=s.href}catch(Nn){cn=i.createElement("a"),cn.href="",cn=cn.href}ln=wn.exec(cn.toLowerCase())||[],v.fn.load=function(e,n,r){if(typeof e!="string"&&En)return En.apply(this,arguments);if(!this.length)return this;var i,s,o,u=this,a=e.indexOf(" ");return a>=0&&(i=e.slice(a,e.length),e=e.slice(0,a)),v.isFunction(n)?(r=n,n=t):n&&typeof n=="object"&&(s="POST"),v.ajax({url:e,type:s,dataType:"html",data:n,complete:function(e,t){r&&u.each(r,o||[e.responseText,t,e])}}).done(function(e){o=arguments,u.html(i?v("<div>").append(e.replace(yn,"")).find(i):e)}),this},v.each("ajaxStart ajaxStop ajaxComplete ajaxError ajaxSuccess ajaxSend".split(" "),function(e,t){v.fn[t]=function(e){return this.on(t,e)}}),v.each(["get","post"],function(e,n){v[n]=function(e,r,i,s){return v.isFunction(r)&&(s=s||i,i=r,r=t),v.ajax({type:n,url:e,data:r,success:i,dataType:s})}}),v.extend({getScript:function(e,n){return v.get(e,t,n,"script")},getJSON:function(e,t,n){return v.get(e,t,n,"json")},ajaxSetup:function(e,t){return t?Ln(e,v.ajaxSettings):(t=e,e=v.ajaxSettings),Ln(e,t),e},ajaxSettings:{url:cn,isLocal:dn.test(ln[1]),global:!0,type:"GET",contentType:"application/x-www-form-urlencoded; charset=UTF-8",processData:!0,async:!0,accepts:{xml:"application/xml, text/xml",html:"text/html",text:"text/plain",json:"application/json, text/javascript","*":Tn},contents:{xml:/xml/,html:/html/,json:/json/},responseFields:{xml:"responseXML",text:"responseText"},converters:{"* text":e.String,"text html":!0,"text json":v.parseJSON,"text xml":v.parseXML},flatOptions:{context:!0,url:!0}},ajaxPrefilter:Cn(Sn),ajaxTransport:Cn(xn),ajax:function(e,n){function T(e,n,s,a){var l,y,b,w,S,T=n;if(E===2)return;E=2,u&&clearTimeout(u),o=t,i=a||"",x.readyState=e>0?4:0,s&&(w=An(c,x,s));if(e>=200&&e<300||e===304)c.ifModified&&(S=x.getResponseHeader("Last-Modified"),S&&(v.lastModified[r]=S),S=x.getResponseHeader("Etag"),S&&(v.etag[r]=S)),e===304?(T="notmodified",l=!0):(l=On(c,w),T=l.state,y=l.data,b=l.error,l=!b);else{b=T;if(!T||e)T="error",e<0&&(e=0)}x.status=e,x.statusText=(n||T)+"",l?d.resolveWith(h,[y,T,x]):d.rejectWith(h,[x,T,b]),x.statusCode(g),g=t,f&&p.trigger("ajax"+(l?"Success":"Error"),[x,c,l?y:b]),m.fireWith(h,[x,T]),f&&(p.trigger("ajaxComplete",[x,c]),--v.active||v.event.trigger("ajaxStop"))}typeof e=="object"&&(n=e,e=t),n=n||{};var r,i,s,o,u,a,f,l,c=v.ajaxSetup({},n),h=c.context||c,p=h!==c&&(h.nodeType||h instanceof v)?v(h):v.event,d=v.Deferred(),m=v.Callbacks("once memory"),g=c.statusCode||{},b={},w={},E=0,S="canceled",x={readyState:0,setRequestHeader:function(e,t){if(!E){var n=e.toLowerCase();e=w[n]=w[n]||e,b[e]=t}return this},getAllResponseHeaders:function(){return E===2?i:null},getResponseHeader:function(e){var n;if(E===2){if(!s){s={};while(n=pn.exec(i))s[n[1].toLowerCase()]=n[2]}n=s[e.toLowerCase()]}return n===t?null:n},overrideMimeType:function(e){return E||(c.mimeType=e),this},abort:function(e){return e=e||S,o&&o.abort(e),T(0,e),this}};d.promise(x),x.success=x.done,x.error=x.fail,x.complete=m.add,x.statusCode=function(e){if(e){var t;if(E<2)for(t in e)g[t]=[g[t],e[t]];else t=e[x.status],x.always(t)}return this},c.url=((e||c.url)+"").replace(hn,"").replace(mn,ln[1]+"//"),c.dataTypes=v.trim(c.dataType||"*").toLowerCase().split(y),c.crossDomain==null&&(a=wn.exec(c.url.toLowerCase()),c.crossDomain=!(!a||a[1]===ln[1]&&a[2]===ln[2]&&(a[3]||(a[1]==="http:"?80:443))==(ln[3]||(ln[1]==="http:"?80:443)))),c.data&&c.processData&&typeof c.data!="string"&&(c.data=v.param(c.data,c.traditional)),kn(Sn,c,n,x);if(E===2)return x;f=c.global,c.type=c.type.toUpperCase(),c.hasContent=!vn.test(c.type),f&&v.active++===0&&v.event.trigger("ajaxStart");if(!c.hasContent){c.data&&(c.url+=(gn.test(c.url)?"&":"?")+c.data,delete c.data),r=c.url;if(c.cache===!1){var N=v.now(),C=c.url.replace(bn,"$1_="+N);c.url=C+(C===c.url?(gn.test(c.url)?"&":"?")+"_="+N:"")}}(c.data&&c.hasContent&&c.contentType!==!1||n.contentType)&&x.setRequestHeader("Content-Type",c.contentType),c.ifModified&&(r=r||c.url,v.lastModified[r]&&x.setRequestHeader("If-Modified-Since",v.lastModified[r]),v.etag[r]&&x.setRequestHeader("If-None-Match",v.etag[r])),x.setRequestHeader("Accept",c.dataTypes[0]&&c.accepts[c.dataTypes[0]]?c.accepts[c.dataTypes[0]]+(c.dataTypes[0]!=="*"?", "+Tn+"; q=0.01":""):c.accepts["*"]);for(l in c.headers)x.setRequestHeader(l,c.headers[l]);if(!c.beforeSend||c.beforeSend.call(h,x,c)!==!1&&E!==2){S="abort";for(l in{success:1,error:1,complete:1})x[l](c[l]);o=kn(xn,c,n,x);if(!o)T(-1,"No Transport");else{x.readyState=1,f&&p.trigger("ajaxSend",[x,c]),c.async&&c.timeout>0&&(u=setTimeout(function(){x.abort("timeout")},c.timeout));try{E=1,o.send(b,T)}catch(k){if(!(E<2))throw k;T(-1,k)}}return x}return x.abort()},active:0,lastModified:{},etag:{}});var Mn=[],_n=/\?/,Dn=/(=)\?(?=&|$)|\?\?/,Pn=v.now();v.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var e=Mn.pop()||v.expando+"_"+Pn++;return this[e]=!0,e}}),v.ajaxPrefilter("json jsonp",function(n,r,i){var s,o,u,a=n.data,f=n.url,l=n.jsonp!==!1,c=l&&Dn.test(f),h=l&&!c&&typeof a=="string"&&!(n.contentType||"").indexOf("application/x-www-form-urlencoded")&&Dn.test(a);if(n.dataTypes[0]==="jsonp"||c||h)return s=n.jsonpCallback=v.isFunction(n.jsonpCallback)?n.jsonpCallback():n.jsonpCallback,o=e[s],c?n.url=f.replace(Dn,"$1"+s):h?n.data=a.replace(Dn,"$1"+s):l&&(n.url+=(_n.test(f)?"&":"?")+n.jsonp+"="+s),n.converters["script json"]=function(){return u||v.error(s+" was not called"),u[0]},n.dataTypes[0]="json",e[s]=function(){u=arguments},i.always(function(){e[s]=o,n[s]&&(n.jsonpCallback=r.jsonpCallback,Mn.push(s)),u&&v.isFunction(o)&&o(u[0]),u=o=t}),"script"}),v.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/javascript|ecmascript/},converters:{"text script":function(e){return v.globalEval(e),e}}}),v.ajaxPrefilter("script",function(e){e.cache===t&&(e.cache=!1),e.crossDomain&&(e.type="GET",e.global=!1)}),v.ajaxTransport("script",function(e){if(e.crossDomain){var n,r=i.head||i.getElementsByTagName("head")[0]||i.documentElement;return{send:function(s,o){n=i.createElement("script"),n.async="async",e.scriptCharset&&(n.charset=e.scriptCharset),n.src=e.url,n.onload=n.onreadystatechange=function(e,i){if(i||!n.readyState||/loaded|complete/.test(n.readyState))n.onload=n.onreadystatechange=null,r&&n.parentNode&&r.removeChild(n),n=t,i||o(200,"success")},r.insertBefore(n,r.firstChild)},abort:function(){n&&n.onload(0,1)}}}});var Hn,Bn=e.ActiveXObject?function(){for(var e in Hn)Hn[e](0,1)}:!1,jn=0;v.ajaxSettings.xhr=e.ActiveXObject?function(){return!this.isLocal&&Fn()||In()}:Fn,function(e){v.extend(v.support,{ajax:!!e,cors:!!e&&"withCredentials"in e})}(v.ajaxSettings.xhr()),v.support.ajax&&v.ajaxTransport(function(n){if(!n.crossDomain||v.support.cors){var r;return{send:function(i,s){var o,u,a=n.xhr();n.username?a.open(n.type,n.url,n.async,n.username,n.password):a.open(n.type,n.url,n.async);if(n.xhrFields)for(u in n.xhrFields)a[u]=n.xhrFields[u];n.mimeType&&a.overrideMimeType&&a.overrideMimeType(n.mimeType),!n.crossDomain&&!i["X-Requested-With"]&&(i["X-Requested-With"]="XMLHttpRequest");try{for(u in i)a.setRequestHeader(u,i[u])}catch(f){}a.send(n.hasContent&&n.data||null),r=function(e,i){var u,f,l,c,h;try{if(r&&(i||a.readyState===4)){r=t,o&&(a.onreadystatechange=v.noop,Bn&&delete Hn[o]);if(i)a.readyState!==4&&a.abort();else{u=a.status,l=a.getAllResponseHeaders(),c={},h=a.responseXML,h&&h.documentElement&&(c.xml=h);try{c.text=a.responseText}catch(p){}try{f=a.statusText}catch(p){f=""}!u&&n.isLocal&&!n.crossDomain?u=c.text?200:404:u===1223&&(u=204)}}}catch(d){i||s(-1,d)}c&&s(u,f,c,l)},n.async?a.readyState===4?setTimeout(r,0):(o=++jn,Bn&&(Hn||(Hn={},v(e).unload(Bn)),Hn[o]=r),a.onreadystatechange=r):r()},abort:function(){r&&r(0,1)}}}});var qn,Rn,Un=/^(?:toggle|show|hide)$/,zn=new RegExp("^(?:([-+])=|)("+m+")([a-z%]*)$","i"),Wn=/queueHooks$/,Xn=[Gn],Vn={"*":[function(e,t){var n,r,i=this.createTween(e,t),s=zn.exec(t),o=i.cur(),u=+o||0,a=1,f=20;if(s){n=+s[2],r=s[3]||(v.cssNumber[e]?"":"px");if(r!=="px"&&u){u=v.css(i.elem,e,!0)||n||1;do a=a||".5",u/=a,v.style(i.elem,e,u+r);while(a!==(a=i.cur()/o)&&a!==1&&--f)}i.unit=r,i.start=u,i.end=s[1]?u+(s[1]+1)*n:n}return i}]};v.Animation=v.extend(Kn,{tweener:function(e,t){v.isFunction(e)?(t=e,e=["*"]):e=e.split(" ");var n,r=0,i=e.length;for(;r<i;r++)n=e[r],Vn[n]=Vn[n]||[],Vn[n].unshift(t)},prefilter:function(e,t){t?Xn.unshift(e):Xn.push(e)}}),v.Tween=Yn,Yn.prototype={constructor:Yn,init:function(e,t,n,r,i,s){this.elem=e,this.prop=n,this.easing=i||"swing",this.options=t,this.start=this.now=this.cur(),this.end=r,this.unit=s||(v.cssNumber[n]?"":"px")},cur:function(){var e=Yn.propHooks[this.prop];return e&&e.get?e.get(this):Yn.propHooks._default.get(this)},run:function(e){var t,n=Yn.propHooks[this.prop];return this.options.duration?this.pos=t=v.easing[this.easing](e,this.options.duration*e,0,1,this.options.duration):this.pos=t=e,this.now=(this.end-this.start)*t+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),n&&n.set?n.set(this):Yn.propHooks._default.set(this),this}},Yn.prototype.init.prototype=Yn.prototype,Yn.propHooks={_default:{get:function(e){var t;return e.elem[e.prop]==null||!!e.elem.style&&e.elem.style[e.prop]!=null?(t=v.css(e.elem,e.prop,!1,""),!t||t==="auto"?0:t):e.elem[e.prop]},set:function(e){v.fx.step[e.prop]?v.fx.step[e.prop](e):e.elem.style&&(e.elem.style[v.cssProps[e.prop]]!=null||v.cssHooks[e.prop])?v.style(e.elem,e.prop,e.now+e.unit):e.elem[e.prop]=e.now}}},Yn.propHooks.scrollTop=Yn.propHooks.scrollLeft={set:function(e){e.elem.nodeType&&e.elem.parentNode&&(e.elem[e.prop]=e.now)}},v.each(["toggle","show","hide"],function(e,t){var n=v.fn[t];v.fn[t]=function(r,i,s){return r==null||typeof r=="boolean"||!e&&v.isFunction(r)&&v.isFunction(i)?n.apply(this,arguments):this.animate(Zn(t,!0),r,i,s)}}),v.fn.extend({fadeTo:function(e,t,n,r){return this.filter(Gt).css("opacity",0).show().end().animate({opacity:t},e,n,r)},animate:function(e,t,n,r){var i=v.isEmptyObject(e),s=v.speed(t,n,r),o=function(){var t=Kn(this,v.extend({},e),s);i&&t.stop(!0)};return i||s.queue===!1?this.each(o):this.queue(s.queue,o)},stop:function(e,n,r){var i=function(e){var t=e.stop;delete e.stop,t(r)};return typeof e!="string"&&(r=n,n=e,e=t),n&&e!==!1&&this.queue(e||"fx",[]),this.each(function(){var t=!0,n=e!=null&&e+"queueHooks",s=v.timers,o=v._data(this);if(n)o[n]&&o[n].stop&&i(o[n]);else for(n in o)o[n]&&o[n].stop&&Wn.test(n)&&i(o[n]);for(n=s.length;n--;)s[n].elem===this&&(e==null||s[n].queue===e)&&(s[n].anim.stop(r),t=!1,s.splice(n,1));(t||!r)&&v.dequeue(this,e)})}}),v.each({slideDown:Zn("show"),slideUp:Zn("hide"),slideToggle:Zn("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(e,t){v.fn[e]=function(e,n,r){return this.animate(t,e,n,r)}}),v.speed=function(e,t,n){var r=e&&typeof e=="object"?v.extend({},e):{complete:n||!n&&t||v.isFunction(e)&&e,duration:e,easing:n&&t||t&&!v.isFunction(t)&&t};r.duration=v.fx.off?0:typeof r.duration=="number"?r.duration:r.duration in v.fx.speeds?v.fx.speeds[r.duration]:v.fx.speeds._default;if(r.queue==null||r.queue===!0)r.queue="fx";return r.old=r.complete,r.complete=function(){v.isFunction(r.old)&&r.old.call(this),r.queue&&v.dequeue(this,r.queue)},r},v.easing={linear:function(e){return e},swing:function(e){return.5-Math.cos(e*Math.PI)/2}},v.timers=[],v.fx=Yn.prototype.init,v.fx.tick=function(){var e,n=v.timers,r=0;qn=v.now();for(;r<n.length;r++)e=n[r],!e()&&n[r]===e&&n.splice(r--,1);n.length||v.fx.stop(),qn=t},v.fx.timer=function(e){e()&&v.timers.push(e)&&!Rn&&(Rn=setInterval(v.fx.tick,v.fx.interval))},v.fx.interval=13,v.fx.stop=function(){clearInterval(Rn),Rn=null},v.fx.speeds={slow:600,fast:200,_default:400},v.fx.step={},v.expr&&v.expr.filters&&(v.expr.filters.animated=function(e){return v.grep(v.timers,function(t){return e===t.elem}).length});var er=/^(?:body|html)$/i;v.fn.offset=function(e){if(arguments.length)return e===t?this:this.each(function(t){v.offset.setOffset(this,e,t)});var n,r,i,s,o,u,a,f={top:0,left:0},l=this[0],c=l&&l.ownerDocument;if(!c)return;return(r=c.body)===l?v.offset.bodyOffset(l):(n=c.documentElement,v.contains(n,l)?(typeof l.getBoundingClientRect!="undefined"&&(f=l.getBoundingClientRect()),i=tr(c),s=n.clientTop||r.clientTop||0,o=n.clientLeft||r.clientLeft||0,u=i.pageYOffset||n.scrollTop,a=i.pageXOffset||n.scrollLeft,{top:f.top+u-s,left:f.left+a-o}):f)},v.offset={bodyOffset:function(e){var t=e.offsetTop,n=e.offsetLeft;return v.support.doesNotIncludeMarginInBodyOffset&&(t+=parseFloat(v.css(e,"marginTop"))||0,n+=parseFloat(v.css(e,"marginLeft"))||0),{top:t,left:n}},setOffset:function(e,t,n){var r=v.css(e,"position");r==="static"&&(e.style.position="relative");var i=v(e),s=i.offset(),o=v.css(e,"top"),u=v.css(e,"left"),a=(r==="absolute"||r==="fixed")&&v.inArray("auto",[o,u])>-1,f={},l={},c,h;a?(l=i.position(),c=l.top,h=l.left):(c=parseFloat(o)||0,h=parseFloat(u)||0),v.isFunction(t)&&(t=t.call(e,n,s)),t.top!=null&&(f.top=t.top-s.top+c),t.left!=null&&(f.left=t.left-s.left+h),"using"in t?t.using.call(e,f):i.css(f)}},v.fn.extend({position:function(){if(!this[0])return;var e=this[0],t=this.offsetParent(),n=this.offset(),r=er.test(t[0].nodeName)?{top:0,left:0}:t.offset();return n.top-=parseFloat(v.css(e,"marginTop"))||0,n.left-=parseFloat(v.css(e,"marginLeft"))||0,r.top+=parseFloat(v.css(t[0],"borderTopWidth"))||0,r.left+=parseFloat(v.css(t[0],"borderLeftWidth"))||0,{top:n.top-r.top,left:n.left-r.left}},offsetParent:function(){return this.map(function(){var e=this.offsetParent||i.body;while(e&&!er.test(e.nodeName)&&v.css(e,"position")==="static")e=e.offsetParent;return e||i.body})}}),v.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(e,n){var r=/Y/.test(n);v.fn[e]=function(i){return v.access(this,function(e,i,s){var o=tr(e);if(s===t)return o?n in o?o[n]:o.document.documentElement[i]:e[i];o?o.scrollTo(r?v(o).scrollLeft():s,r?s:v(o).scrollTop()):e[i]=s},e,i,arguments.length,null)}}),v.each({Height:"height",Width:"width"},function(e,n){v.each({padding:"inner"+e,content:n,"":"outer"+e},function(r,i){v.fn[i]=function(i,s){var o=arguments.length&&(r||typeof i!="boolean"),u=r||(i===!0||s===!0?"margin":"border");return v.access(this,function(n,r,i){var s;return v.isWindow(n)?n.document.documentElement["client"+e]:n.nodeType===9?(s=n.documentElement,Math.max(n.body["scroll"+e],s["scroll"+e],n.body["offset"+e],s["offset"+e],s["client"+e])):i===t?v.css(n,r,i,u):v.style(n,r,i,u)},n,o?i:t,o,null)}})}),e.jQuery=e.$=v,typeof define=="function"&&define.amd&&define.amd.jQuery&&define("jquery",[],function(){return v})}(window),function(e,t){typeof define=="function"&&define.amd?define("salsa20",t):typeof module!="undefined"&&module.exports?module.exports=t():e.Salsa20=t()}(this,function(){function e(e,t){this.rounds=20,this.sigmaWords=[1634760805,857760878,2036477234,1797285236],this.keyWords=[],this.nonceWords=[0,0],this.counterWords=[0,0],this.block=[],this.blockUsed=64,this.setKey(e),this.setNonce(t)}return e.prototype.setKey=function(e){for(var t=0,n=0;t<8;t++,n+=4)this.keyWords[t]=e[n]&255|(e[n+1]&255)<<8|(e[n+2]&255)<<16|(e[n+3]&255)<<24;this._reset()},e.prototype.setNonce=function(e){this.nonceWords[0]=e[0]&255|(e[1]&255)<<8|(e[2]&255)<<16|(e[3]&255)<<24,this.nonceWords[1]=e[4]&255|(e[5]&255)<<8|(e[6]&255)<<16|(e[7]&255)<<24,this._reset()},e.prototype.getBytes=function(e){var t=new Array(e);for(var n=0;n<e;n++)this.blockUsed==64&&(this._generateBlock(),this._incrementCounter(),this.blockUsed=0),t[n]=this.block[this.blockUsed],this.blockUsed++;return t},e.prototype.getHexString=function(e){var t=["0","1","2","3","4","5","6","7","8","9","a","b","c","d","e","f"],n=[],r=this.getBytes(e);for(var i=0;i<r.length;i++)n.push(t[r[i]>>4&15]),n.push(t[r[i]&15]);return n.join("")},e.prototype._reset=function(){this.counterWords[0]=0,this.counterWords[1]=0,this.blockUsed=64},e.prototype._incrementCounter=function(){this.counterWords[0]=this.counterWords[0]+1&4294967295,this.counterWords[0]==0&&(this.counterWords[1]=this.counterWords[1]+1&4294967295)},e.prototype._generateBlock=function(){var e=this.sigmaWords[0],t=this.keyWords[0],n=this.keyWords[1],r=this.keyWords[2],i=this.keyWords[3],s=this.sigmaWords[1],o=this.nonceWords[0],u=this.nonceWords[1],a=this.counterWords[0],f=this.counterWords[1],l=this.sigmaWords[2],c=this.keyWords[4],h=this.keyWords[5],p=this.keyWords[6],d=this.keyWords[7],v=this.sigmaWords[3],m=e,g=t,y=n,b=r,w=i,E=s,S=o,x=u,T=a,N=f,C=l,k=c,L=h,A=p,O=d,M=v,_;for(var D=0;D<this.rounds;D+=2)_=m+L,w^=_<<7|_>>>25,_=w+m,T^=_<<9|_>>>23,_=T+w,L^=_<<13|_>>>19,_=L+T,m^=_<<18|_>>>14,_=E+g,N^=_<<7|_>>>25,_=N+E,A^=_<<9|_>>>23,_=A+N,g^=_<<13|_>>>19,_=g+A,E^=_<<18|_>>>14,_=C+S,O^=_<<7|_>>>25,_=O+C,y^=_<<9|_>>>23,_=y+O,S^=_<<13|_>>>19,_=S+y,C^=_<<18|_>>>14,_=M+k,b^=_<<7|_>>>25,_=b+M,x^=_<<9|_>>>23,_=x+b,k^=_<<13|_>>>19,_=k+x,M^=_<<18|_>>>14,_=m+b,g^=_<<7|_>>>25,_=g+m,y^=_<<9|_>>>23,_=y+g,b^=_<<13|_>>>19,_=b+y,m^=_<<18|_>>>14,_=E+w,S^=_<<7|_>>>25,_=S+E,x^=_<<9|_>>>23,_=x+S,w^=_<<13|_>>>19,_=w+x,E^=_<<18|_>>>14,_=C+N,k^=_<<7|_>>>25,_=k+C,T^=_<<9|_>>>23,_=T+k,N^=_<<13|_>>>19,_=N+T,C^=_<<18|_>>>14,_=M+O,L^=_<<7|_>>>25,_=L+M,A^=_<<9|_>>>23,_=A+L,O^=_<<13|_>>>19,_=O+A,M^=_<<18|_>>>14;m+=e,g+=t,y+=n,b+=r,w+=i,E+=s,S+=o,x+=u,T+=a,N+=f,C+=l,k+=c,L+=h,A+=p,O+=d,M+=v,this.block[0]=m>>>0&255,this.block[1]=m>>>8&255,this.block[2]=m>>>16&255,this.block[3]=m>>>24&255,this.block[4]=g>>>0&255,this.block[5]=g>>>8&255,this.block[6]=g>>>16&255,this.block[7]=g>>>24&255,this.block[8]=y>>>0&255,this.block[9]=y>>>8&255,this.block[10]=y>>>16&255,this.block[11]=y>>>24&255,this.block[12]=b>>>0&255,this.block[13]=b>>>8&255,this.block[14]=b>>>16&255,this.block[15]=b>>>24&255,this.block[16]=w>>>0&255,this.block[17]=w>>>8&255,this.block[18]=w>>>16&255,this.block[19]=w>>>24&255,this.block[20]=E>>>0&255,this.block[21]=E>>>8&255,this.block[22]=E>>>16&255,this.block[23]=E>>>24&255,this.block[24]=S>>>0&255,this.block[25]=S>>>8&255,this.block[26]=S>>>16&255,this.block[27]=S>>>24&255,this.block[28]=x>>>0&255,this.block[29]=x>>>8&255,this.block[30]=x>>>16&255,this.block[31]=x>>>24&255,this.block[32]=T>>>0&255,this.block[33]=T>>>8&255,this.block[34]=T>>>16&255,this.block[35]=T>>>24&255,this.block[36]=N>>>0&255,this.block[37]=N>>>8&255,this.block[38]=N>>>16&255,this.block[39]=N>>>24&255,this.block[40]=C>>>0&255,this.block[41]=C>>>8&255,this.block[42]=C>>>16&255,this.block[43]=C>>>24&255,this.block[44]=k>>>0&255,this.block[45]=k>>>8&255,this.block[46]=k>>>16&255,this.block[47]=k>>>24&255,this.block[48]=L>>>0&255,this.block[49]=L>>>8&255,this.block[50]=L>>>16&255,this.block[51]=L>>>24&255,this.block[52]=A>>>0&255,this.block[53]=A>>>8&255,this.block[54]=A>>>16&255,this.block[55]=A>>>24&255,this.block[56]=O>>>0&255,this.block[57]=O>>>8&255,this.block[58]=O>>>16&255,this.block[59]=O>>>24&255,this.block[60]=M>>>0&255,this.block[61]=M>>>8&255,this.block[62]=M>>>16&255,this.block[63]=M>>>24&255},e}),function(e,t){var n,r;typeof define=="function"&&define.amd?define("bigint",["salsa20"],t.bind(e,e.crypto)):typeof module!="undefined"&&module.exports?(n=require("./salsa20.js"),r=require("crypto"),module.exports=t(r,n)):e.BigInt=t(e.crypto,e.Salsa20)}(this,function(e,t){function Y(e){var t,n,r,i;n=new Array(e);for(t=0;t<e;t++)n[t]=0;n[0]=2,r=0;for(;n[r]<e;){for(t=n[r]*n[r];t<e;t+=n[r])n[t]=1;r++,n[r]=n[r-1]+1;for(;n[r]<e&&n[n[r]];n[r]++);}i=new Array(r);for(t=0;t<r;t++)i[t]=n[t];return i}function Z(e,t){return b.length!=e.length&&(b=Ht(e),w=Ht(e),E=Ht(e)),jt(E,t),et(e,E)}function et(e,t){var r,i,s,o;b.length!=e.length&&(b=Ht(e),w=Ht(e),E=Ht(e)),Bt(E,t),Bt(w,e),Bt(b,e),Ft(w,-1),Ft(b,-1);if(Dt(w))return 0;for(s=0;w[s]==0;s++);for(r=1,i=2;w[s]%i==0;i*=2,r++);o=s*n+r-1,o&&It(w,o),tn(E,w,e);if(!Mt(E,1)&&!_t(E,b)){i=1;while(i<=o-1&&!_t(E,b)){Zt(E,e);if(Mt(E,1))return 0;i++}if(!_t(E,b))return 0}return 1}function tt(e){var t,r,i;for(t=e.length-1;e[t]==0&&t>0;t--);for(r=0,i=e[t];i;i>>=1,r++);return r+=n*t,r}function nt(e,t){var r=At(0,(e.length>t?e.length:t)*n,0);return Bt(r,e),r}function rt(e){var t=At(0,e,0);return dt(t,e),en(t,1)}function it(e){return e>=600?st(e,2):e>=550?st(e,4):e>=500?st(e,5):e>=400?st(e,6):e>=350?st(e,7):e>=300?st(e,9):e>=250?st(e,12):e>=200?st(e,15):e>=150?st(e,18):e>=100?st(e,27):st(e,40)}function st(e,t){var n,r,i,s;s=3e4,n=At(0,e,0),H.length==0&&(H=Y(3e4)),G.length!=n.length&&(G=Ht(n));for(;;){mt(n,e,0),n[0]|=1,i=0;for(r=0;r<H.length&&H[r]<=s;r++)if(Lt(n,H[r])==0&&!Mt(n,H[r])){i=1;break}for(r=0;r<t&&!i;r++){mt(G,e,0);while(!Nt(n,G))mt(G,e,0);et(n,G)||(i=1)}if(!i)return n}}function ot(e,t){var n=Ht(e);return Gt(n,t),en(n,1)}function ut(e,t){var n=nt(e,e.length+1);return Ft(n,t),en(n,1)}function at(e,t){var n=nt(e,e.length+t.length);return Qt(n,t),en(n,1)}function ft(e,t,n){var r=nt(e,n.length);return tn(r,en(t,2),en(n,2),0),en(r,1)}function lt(e,t){var n=nt(e,e.length>t.length?e.length+1:t.length+1);return Jt(n,t),en(n,1)}function ct(e,t){var n=nt(e,e.length>t.length?e.length+1:t.length+1);return Kt(n,t),en(n,1)}function ht(e,t){var n=nt(e,t.length),r;return r=bt(n,t),r?en(n,1):null}function pt(e,t,n){var r=nt(e,n.length);return Yt(r,t,n),en(r,1)}function dt(e,t){var r,i,s,o,u,a,f,l,c,h,p,d,v;H.length==0&&(H=Y(3e4));if(B.length==0){B=new Array(512);for(a=0;a<512;a++)B[a]=Math.pow(2,a/511-1)}r=.1,s=20,v=20,F.length!=e.length&&(F=Ht(e),I=Ht(e),U=Ht(e),W=Ht(e),$=Ht(e),J=Ht(e),K=Ht(e),V=Ht(e),X=Ht(e),j=Ht(e),q=Ht(e),R=Ht(e),z=Ht(e),Q=Ht(e));if(t<=v){o=(1<<(t+2>>1))-1,jt(e,0);for(u=1;u;){u=0,e[0]=1|1<<t-1|sn(t);for(a=1;a<H.length&&(H[a]&o)==H[a];a++)if(0==e[0]%H[a]){u=1;break}}kt(e);return}l=r*t*t;if(t>2*s)for(f=1;t-t*f<=s;)f=B[sn(9)];else f=.5;d=Math.floor(f*t)+1,dt(R,d),jt(F,0),F[Math.floor((t-2)/n)]|=1<<(t-2)%n,Ct(F,R,j,q),h=tt(j);for(;;){for(;;){mt(I,h,0);if(Nt(j,I))break}Ft(I,1),Kt(I,j),Bt(X,R),Qt(X,I),Ut(X,2),Ft(X,1),Bt(W,I),Ut(W,2);for(c=0,a=0;a<H.length&&H[a]<l;a++)if(Lt(X,H[a])==0&&!Mt(X,H[a])){c=1;break}c||Z(X,2)||(c=1);if(!c){Ft(X,-3);for(a=X.length-1;X[a]==0&&a>0;a--);for(p=0,i=X[a];i;i>>=1,p++);p+=n*a;for(;;){mt(z,p,0);if(Nt(X,z))break}Ft(X,3),Ft(z,2),Bt(V,z),Bt(U,X),Ft(U,-1),tn(V,U,X),Ft(V,-1);if(Dt(V)){Bt(V,z),tn(V,W,X),Ft(V,-1),Bt(Q,X),Bt($,V),yt($,X);if(Mt($,1)){Bt(e,Q);return}}}}}function vt(e,t){var r,i;return r=Math.floor((e-1)/n)+2,i=At(0,0,r),mt(i,e,t),i}function mt(e,t,r){var i,s;for(i=0;i<e.length;i++)e[i]=0;s=Math.floor((t-1)/n)+1;for(i=0;i<s;i++)e[i]=sn(n);e[s-1]&=(2<<(t-1)%n)-1,r==1&&(e[s-1]|=1<<(t-1)%n)}function gt(e,t){var n,r;return n=Ht(e),r=Ht(t),yt(n,r),n}function yt(e,t){var n,r,i,s,o,a,f,l,c,h;g.length!=e.length&&(g=Ht(e)),c=1;while(c){c=0;for(n=1;n<t.length;n++)if(t[n]){c=1;break}if(!c)break;for(n=e.length;!e[n]&&n>=0;n--);r=e[n],i=t[n],s=1,o=0,a=0,f=1;while(i+a&&i+f){l=Math.floor((r+s)/(i+a)),h=Math.floor((r+o)/(i+f));if(l!=h)break;u=s-l*a,s=a,a=u,u=o-l*f,o=f,f=u,u=r-l*i,r=i,i=u}o?(Bt(g,e),Wt(e,t,s,o),Wt(t,g,f,a)):(Gt(e,t),Bt(g,e),Bt(e,t),Bt(t,g))}if(t[0]==0)return;u=Lt(e,t[0]),jt(e,t[0]),t[0]=u;while(t[0])e[0]%=t[0],u=e[0],e[0]=t[0],t[0]=u}function bt(e,t){var n=1+2*Math.max(e.length,t.length);if(!(e[0]&1)&&!(t[0]&1))return jt(e,0),0;x.length!=n&&(x=new Array(n),S=new Array(n),T=new Array(n),N=new Array(n),C=new Array(n),k=new Array(n)),Bt(x,e),Bt(S,t),jt(T,1),jt(N,0),jt(C,0),jt(k,1);for(;;){while(!(x[0]&1))qt(x),!(T[0]&1)&&!(N[0]&1)?(qt(T),qt(N)):(Kt(T,t),qt(T),Jt(N,e),qt(N));while(!(S[0]&1))qt(S),!(C[0]&1)&&!(k[0]&1)?(qt(C),qt(k)):(Kt(C,t),qt(C),Jt(k,e),qt(k));Nt(S,x)?(Jt(S,x),Jt(C,T),Jt(k,N)):(Jt(x,S),Jt(T,C),Jt(N,k));if(Mt(x,0)){while(xt(C))Kt(C,t);return Bt(e,C),Mt(S,1)?1:(jt(e,0),0)}}}function wt(e,t){var n=1,r=0,i;for(;;){if(e==1)return n;if(e==0)return 0;r-=n*Math.floor(t/e),t%=e;if(t==1)return r;if(t==0)return 0;n-=r*Math.floor(e/t),e%=t}}function Et(e,t){return wt(e,t)}function St(e,t,n,r,i){var s=0,o=Math.max(e.length,t.length);x.length!=o&&(x=new Array(o),T=new Array(o),N=new Array(o),C=new Array(o),k=new Array(o));while(!(e[0]&1)&&!(t[0]&1))qt(e),qt(t),s++;Bt(x,e),Bt(n,t),jt(T,1),jt(N,0),jt(C,0),jt(k,1);for(;;){while(!(x[0]&1))qt(x),!(T[0]&1)&&!(N[0]&1)?(qt(T),qt(N)):(Kt(T,t),qt(T),Jt(N,e),qt(N));while(!(n[0]&1))qt(n),!(C[0]&1)&&!(k[0]&1)?(qt(C),qt(k)):(Kt(C,t),qt(C),Jt(k,e),qt(k));Nt(n,x)?(Jt(n,x),Jt(C,T),Jt(k,N)):(Jt(x,n),Jt(T,C),Jt(N,k));if(Mt(x,0)){while(xt(C))Kt(C,t),Jt(k,e);Ut(k,-1),Bt(r,C),Bt(i,k),Rt(n,s);return}}}function xt(e){return e[e.length-1]>>n-1&1}function Tt(e,t,n){var r,i=e.length,s=t.length,o=i+n<s?i+n:s;for(r=s-1-n;r<i&&r>=0;r++)if(e[r]>0)return 1;for(r=i-1+n;r<s;r++)if(t[r]>0)return 0;for(r=o-1;r>=n;r--){if(e[r-n]>t[r])return 1;if(e[r-n]<t[r])return 0}return 0}function Nt(e,t){var n,r=e.length<t.length?e.length:t.length;for(n=e.length;n<t.length;n++)if(t[n])return 0;for(n=t.length;n<e.length;n++)if(e[n])return 1;for(n=r-1;n>=0;n--){if(e[n]>t[n])return 1;if(e[n]<t[n])return 0}return 0}function Ct(e,t,s,o){var u,a,f,l,c,h,p,d,v;Bt(o,e);for(a=t.length;t[a-1]==0;a--);v=t[a-1];for(d=0;v;d++)v>>=1;d=n-d,Rt(t,d),Rt(o,d);for(u=o.length;o[u-1]==0&&u>a;u--);jt(s,0);while(!Tt(t,o,u-a))$t(o,t,u-a),s[u-a]++;for(f=u-1;f>=a;f--){o[f]==t[a-1]?s[f-a]=r:s[f-a]=Math.floor((o[f]*i+o[f-1])/t[a-1]);for(;;){h=(a>1?t[a-2]:0)*s[f-a],p=h>>n,h&=r,c=p+s[f-a]*t[a-1],p=c>>n,c&=r;if(!(p==o[f]?c==o[f-1]?h>(f>1?o[f-2]:0):c>o[f-1]:p>o[f]))break;s[f-a]--}Xt(o,t,-s[f-a],f-a),xt(o)&&(Vt(o,t,f-a),s[f-a]--)}It(t,d),It(o,d)}function kt(e){var t,s,o,u;s=e.length,o=0;for(t=0;t<s;t++)o+=e[t],u=0,o<0&&(u=-(o>>n),o+=u*i),e[t]=o&r,o=(o>>n)-u}function Lt(e,t){var n,r=0;for(n=e.length-1;n>=0;n--)r=(r*i+e[n])%t;return r}function At(e,t,r){var i,s,o;return s=Math.ceil(t/n)+1,s=r>s?r:s,o=new Array(s),jt(o,e),o}function Ot(e,t,n){var r,i,o,u,a,f,l=e.length;if(t==-1){u=new Array(0);for(;;){a=new Array(u.length+1);for(i=0;i<u.length;i++)a[i+1]=u[i];a[0]=parseInt(e,10),u=a,r=e.indexOf(",",0);if(r<1)break;e=e.substring(r+1);if(e.length==0)break}return u.length<n?(a=new Array(n),Bt(a,u),a):u}var c=t,h=0,p=t==1?l:0;while(c>1)c&1&&(h=1),p+=l,c>>=1;p+=h*l,u=At(0,p,0);for(i=0;i<l;i++){r=s.indexOf(e.substring(i,i+1),0),t<=36&&r>=36&&(r-=26);if(r>=t||r<0)break;Ut(u,t),Ft(u,r)}for(l=u.length;l>0&&!u[l-1];l--);l=n>l+1?n:l+1,a=new Array(l),f=l<u.length?l:u.length;for(i=0;i<f;i++)a[i]=u[i];for(;i<l;i++)a[i]=0;return a}function Mt(e,t){var n;if(e[0]!=t)return 0;for(n=1;n<e.length;n++)if(e[n])return 0;return 1}function _t(e,t){var n,r=e.length<t.length?e.length:t.length;for(n=0;n<r;n++)if(e[n]!=t[n])return 0;if(e.length>t.length){for(;n<e.length;n++)if(e[n])return 0}else for(;n<t.length;n++)if(t[n])return 0;return 1}function Dt(e){var t;for(t=0;t<e.length;t++)if(e[t])return 0;return 1}function Pt(e,t){var n,r,i="";v.length!=e.length?v=Ht(e):Bt(v,e);if(t==-1){for(n=e.length-1;n>0;n--)i+=e[n]+",";i+=e[0]}else while(!Dt(v))r=zt(v,t),i=s.substring(r,r+1)+i;return i.length==0&&(i="0"),i}function Ht(e){var t,n;return n=new Array(e.length),Bt(n,e),n}function Bt(e,t){var n,r=e.length<t.length?e.length:t.length;for(n=0;n<r;n++)e[n]=t[n];for(n=r;n<e.length;n++)e[n]=0}function jt(e,t){var i,s;for(s=t,i=0;i<e.length;i++)e[i]=s&r,s>>=n}function Ft(e,t){var s,o,u,a;e[0]+=t,o=e.length,u=0;for(s=0;s<o;s++){u+=e[s],a=0,u<0&&(a=-(u>>n),u+=a*i),e[s]=u&r,u=(u>>n)-a;if(!u)return}}function It(e,t){var i,s=Math.floor(t/n);if(s){for(i=0;i<e.length-s;i++)e[i]=e[i+s];for(;i<e.length;i++)e[i]=0;t%=n}for(i=0;i<e.length-1;i++)e[i]=r&(e[i+1]<<n-t|e[i]>>t);e[i]>>=t}function qt(e){var t;for(t=0;t<e.length-1;t++)e[t]=r&(e[t+1]<<n-1|e[t]>>1);e[t]=e[t]>>1|e[t]&i>>1}function Rt(e,t){var i,s=Math.floor(t/n);if(s){for(i=e.length;i>=s;i--)e[i]=e[i-s];for(;i>=0;i--)e[i]=0;t%=n}if(!t)return;for(i=e.length-1;i>0;i--)e[i]=r&(e[i]<<t|e[i-1]>>n-t);e[i]=r&e[i]<<t}function Ut(e,t){var s,o,u,a;if(!t)return;o=e.length,u=0;for(s=0;s<o;s++)u+=e[s]*t,a=0,u<0&&(a=-(u>>n),u+=a*i),e[s]=u&r,u=(u>>n)-a}function zt(e,t){var n,r=0,s;for(n=e.length-1;n>=0;n--)s=r*i+e[n],e[n]=Math.floor(s/t),r=s%t;return r}function Wt(e,t,i,s){var o,u,a,f;a=e.length<t.length?e.length:t.length,f=e.length;for(u=0,o=0;o<a;o++)u+=i*e[o]+s*t[o],e[o]=u&r,u>>=n;for(o=a;o<f;o++)u+=i*e[o],e[o]=u&r,u>>=n}function Xt(e,t,i,s){var o,u,a,f;a=e.length<s+t.length?e.length:s+t.length,f=e.length;for(u=0,o=s;o<a;o++)u+=e[o]+i*t[o-s],e[o]=u&r,u>>=n;for(o=a;u&&o<f;o++)u+=e[o],e[o]=u&r,u>>=n}function Vt(e,t,i){var s,o,u,a;u=e.length<i+t.length?e.length:i+t.length,a=e.length;for(o=0,s=i;s<u;s++)o+=e[s]+t[s-i],e[s]=o&r,o>>=n;for(s=u;o&&s<a;s++)o+=e[s],e[s]=o&r,o>>=n}function $t(e,t,i){var s,o,u,a;u=e.length<i+t.length?e.length:i+t.length,a=e.length;for(o=0,s=i;s<u;s++)o+=e[s]-t[s-i],e[s]=o&r,o>>=n;for(s=u;o&&s<a;s++)o+=e[s],e[s]=o&r,o>>=n}function Jt(e,t){var i,s,o,u;o=e.length<t.length?e.length:t.length;for(s=0,i=0;i<o;i++)s+=e[i]-t[i],e[i]=s&r,s>>=n;for(i=o;s&&i<e.length;i++)s+=e[i],e[i]=s&r,s>>=n}function Kt(e,t){var i,s,o,u;o=e.length<t.length?e.length:t.length;for(s=0,i=0;i<o;i++)s+=e[i]+t[i],e[i]=s&r,s>>=n;for(i=o;s&&i<e.length;i++)s+=e[i],e[i]=s&r,s>>=n}function Qt(e,t){var n;a.length!=2*e.length&&(a=new Array(2*e.length)),jt(a,0);for(n=0;n<t.length;n++)t[n]&&Xt(a,e,t[n],n);Bt(e,a)}function Gt(e,t){p.length!=e.length?p=Ht(e):Bt(p,e),d.length!=e.length&&(d=Ht(e)),Ct(p,t,d,e)}function Yt(e,t,n){var r;f.length!=2*e.length&&(f=new Array(2*e.length)),jt(f,0);for(r=0;r<t.length;r++)t[r]&&Xt(f,e,t[r],r);Gt(f,n),Bt(e,f)}function Zt(e,t){var i,s,o,u,a,l,c;for(a=e.length;a>0&&!e[a-1];a--);c=a>t.length?2*a:2*t.length,f.length!=c&&(f=new Array(c)),jt(f,0);for(i=0;i<a;i++){u=f[2*i]+e[i]*e[i],f[2*i]=u&r,u>>=n;for(s=i+1;s<a;s++)u=f[i+s]+2*e[i]*e[s]+u,f[i+s]=u&r,u>>=n;f[i+a]=u}Gt(f,t),Bt(e,f)}function en(e,t){var n,r;for(n=e.length;n>0&&!e[n-1];n--);return r=new Array(n+t),Bt(r,e),r}function tn(e,t,r){var s,u,a,f;m.length!=r.length&&(m=Ht(r));if((r[0]&1)==0){Bt(m,e),jt(e,1);while(!Mt(t,0))t[0]&1&&Yt(e,m,r),zt(t,2),Zt(m,r);return}jt(m,0);for(a=r.length;a>0&&!r[a-1];a--);f=i-wt(Lt(r,i),i),m[a]=1,Yt(e,m,r),h.length!=e.length?h=Ht(e):Bt(h,e);for(s=t.length-1;s>0&!t[s];s--);if(t[s]==0){jt(e,1);return}for(u=1<<n-1;u&&!(t[s]&u);u>>=1);for(;;){if(!(u>>=1)){s--;if(s<0){nn(e,o,r,f);return}u=1<<n-1}nn(e,e,r,f),u&t[s]&&nn(e,h,r,f)}}function nn(e,t,i,s){var o,u,a,f,l,c,h=i.length,p=t.length;y.length!=h&&(y=new Array(h)),jt(y,0);for(;h>0&&i[h-1]==0;h--);for(;p>0&&t[p-1]==0;p--);c=y.length-1;for(o=0;o<h;o++){l=y[0]+e[o]*t[0],f=(l&r)*s&r,a=l+f*i[0]>>n,l=e[o],u=1;for(;u<p-4;)a+=y[u]+f*i[u]+l*t[u],y[u-1]=a&r,a>>=n,u++,a+=y[u]+f*i[u]+l*t[u],y[u-1]=a&r,a>>=n,u++,a+=y[u]+f*i[u]+l*t[u],y[u-1]=a&r,a>>=n,u++,a+=y[u]+f*i[u]+l*t[u],y[u-1]=a&r,a>>=n,u++,a+=y[u]+f*i[u]+l*t[u],y[u-1]=a&r,a>>=n,u++;for(;u<p;)a+=y[u]+f*i[u]+l*t[u],y[u-1]=a&r,a>>=n,u++;for(;u<h-4;)a+=y[u]+f*i[u],y[u-1]=a&r,a>>=n,u++,a+=y[u]+f*i[u],y[u-1]=a&r,a>>=n,u++,a+=y[u]+f*i[u],y[u-1]=a&r,a>>=n,u++,a+=y[u]+f*i[u],y[u-1]=a&r,a>>=n,u++,a+=y[u]+f*i[u],y[u-1]=a&r,a>>=n,u++;for(;u<h;)a+=y[u]+f*i[u],y[u-1]=a&r,a>>=n,u++;for(;u<c;)a+=y[u],y[u-1]=a&r,a>>=n,u++;y[u-1]=a&r}Nt(i,y)||Jt(y,i),Bt(e,y)}function on(e){function u(){var e=n.getBytes(i),t=0,s=0;for(;t<i;t++)s=s*r+e[t];return s}function a(){return n.getBytes(1)[0]}var n=new t([e[0],e[1],e[2],e[3],e[4],e[5],e[6],e[7],e[8],e[9],e[10],e[11],e[12],e[13],e[14],e[15],e[16],e[17],e[18],e[19],e[20],e[21],e[22],e[23],e[24],e[25],e[26],e[27],e[28],e[29],e[30],e[31]],[e[32],e[33],e[34],e[35],e[36],e[37],e[38],e[39]]),r=256,i=6,s=Math.pow(2,52),o=s*2;return sn=function(e){if(e>31)throw new Error("Too many bits.");var t=0,n=0,r=Math.floor(e/8),i=(1<<e%8)-1;i&&(n=a()&i);for(;t<r;t++)n=256*n+a();return n},function(){var e=u(),t=Math.pow(r,i),n=0;while(e<s)e=(e+n)*r,t*=r,n=a();while(e>=o)e/=2,t/=2,n>>>=1;return(e+n)/t}}function un(){var t;if(typeof e!="undefined"&&typeof e.randomBytes=="function")try{t=e.randomBytes(40)}catch(n){throw n}else{if(typeof e=="undefined"||typeof e.getRandomValues!="function")throw new Error("Keys should not be generated without CSPRNG.");t=new Uint8Array(40),e.getRandomValues(t)}return Array.prototype.slice.call(t,0)}var n=0,r=0,i=r+1,s="0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz_=!@#$%^&*()[]{}|;:,.<>/?`~ \\'\"+-";for(n=0;1<<n+1>1<<n;n++);n>>=1,r=(1<<n)-1,i=r+1;var o=At(1,1,1),u=new Array(0),a=u,f=u,l=u,c=u,h=u,p=u,d=u,v=u,m=u,g=u,y=u,b=u,w=u,E=u,S=u,x=u,T=u,N=u,C=u,k=u,L=u,A=u,O=u,M=u,_=u,D=u,P=u,H=u,B=u,j=u,F=u,I=u,q=u,R=u,U=u,z=u,W=u,X=u,V=u,$=u,J=u,K=u,Q=u,G=u,rn={str2bigInt:Ot,bigInt2str:Pt,int2bigInt:At,multMod:pt,powMod:ft,inverseMod:ht,randBigInt:vt,randBigInt_:mt,equals:_t,equalsInt:Mt,sub:lt,mod:ot,mod_:Gt,modInt:Lt,mult:at,divInt_:zt,rightShift_:It,leftShift_:Rt,dup:Ht,greater:Nt,add:ct,addInt:ut,addInt_:Ft,isZero:Dt,bitSize:tt,randTruePrime:rt,millerRabin:et,divide_:Ct,trim:en,expand:nt,bpe:n,primes:H,findPrimes:Y,getSeed:un},sn;return function an(){var t=typeof e!="undefined"&&(typeof e.randomBytes=="function"||typeof e.getRandomValues=="function");if(!t)return;Math.random=on(un()),typeof setTimeout=="function"&&typeof document!="undefined"&&setTimeout(an,3e5)}(),rn});var CryptoJS=CryptoJS||function(e,t){var n={},r=n.lib={},i=r.Base=function(){function e(){}return{extend:function(t){e.prototype=this;var n=new e;return t&&n.mixIn(t),n.hasOwnProperty("init")||(n.init=function(){n.$super.init.apply(this,arguments)}),n.init.prototype=n,n.$super=this,n},create:function(){var e=this.extend();return e.init.apply(e,arguments),e},init:function(){},mixIn:function(e){for(var t in e)e.hasOwnProperty(t)&&(this[t]=e[t]);e.hasOwnProperty("toString")&&(this.toString=e.toString)},clone:function(){return this.init.prototype.extend(this)}}}(),s=r.WordArray=i.extend({init:function(e,n){e=this.words=e||[],n!=t?this.sigBytes=n:this.sigBytes=e.length*4},toString:function(e){return(e||u).stringify(this)},concat:function(e){var t=this.words,n=e.words,r=this.sigBytes,i=e.sigBytes;this.clamp();if(r%4)for(var s=0;s<i;s++){var o=n[s>>>2]>>>24-s%4*8&255;t[r+s>>>2]|=o<<24-(r+s)%4*8}else if(n.length>65535)for(var s=0;s<i;s+=4)t[r+s>>>2]=n[s>>>2];else t.push.apply(t,n);return this.sigBytes+=i,this},clamp:function(){var t=this.words,n=this.sigBytes;t[n>>>2]&=4294967295<<32-n%4*8,t.length=e.ceil(n/4)},clone:function(){var e=i.clone.call(this);return e.words=this.words.slice(0),e},random:function(t){var n=[];for(var r=0;r<t;r+=4)n.push(e.random()*4294967296|0);return new s.init(n,t)}}),o=n.enc={},u=o.Hex={stringify:function(e){var t=e.words,n=e.sigBytes,r=[];for(var i=0;i<n;i++){var s=t[i>>>2]>>>24-i%4*8&255;r.push((s>>>4).toString(16)),r.push((s&15).toString(16))}return r.join("")},parse:function(e){var t=e.length,n=[];for(var r=0;r<t;r+=2)n[r>>>3]|=parseInt(e.substr(r,2),16)<<24-r%8*4;return new s.init(n,t/2)}},a=o.Latin1={stringify:function(e){var t=e.words,n=e.sigBytes,r=[];for(var i=0;i<n;i++){var s=t[i>>>2]>>>24-i%4*8&255;r.push(String.fromCharCode(s))}return r.join("")},parse:function(e){var t=e.length,n=[];for(var r=0;r<t;r++)n[r>>>2]|=(e.charCodeAt(r)&255)<<24-r%4*8;return new s.init(n,t)}},f=o.Utf8={stringify:function(e){try{return decodeURIComponent(escape(a.stringify(e)))}catch(t){throw new Error("Malformed UTF-8 data")}},parse:function(e){return a.parse(unescape(encodeURIComponent(e)))}},l=r.BufferedBlockAlgorithm=i.extend({reset:function(){this._data=new s.init,this._nDataBytes=0},_append:function(e){typeof e=="string"&&(e=f.parse(e)),this._data.concat(e),this._nDataBytes+=e.sigBytes},_process:function(t){var n=this._data,r=n.words,i=n.sigBytes,o=this.blockSize,u=o*4,a=i/u;t?a=e.ceil(a):a=e.max((a|0)-this._minBufferSize,0);var f=a*o,l=e.min(f*4,i);if(f){for(var c=0;c<f;c+=o)this._doProcessBlock(r,c);var h=r.splice(0,f);n.sigBytes-=l}return new s.init(h,l)},clone:function(){var e=i.clone.call(this);return e._data=this._data.clone(),e},_minBufferSize:0}),c=r.Hasher=l.extend({cfg:i.extend(),init:function(e){this.cfg=this.cfg.extend(e),this.reset()},reset:function(){l.reset.call(this),this._doReset()},update:function(e){return this._append(e),this._process(),this},finalize:function(e){e&&this._append(e);var t=this._doFinalize();return t},blockSize:16,_createHelper:function(e){return function(t,n){return(new e.init(n)).finalize(t)}},_createHmacHelper:function(e){return function(t,n){return(new h.HMAC.init(e,n)).finalize(t)}}}),h=n.algo={};return n}(Math);define("crypto.core",function(){}),function(){var e=CryptoJS,t=e.lib,n=t.WordArray,r=e.enc,i=r.Base64={stringify:function(e){var t=e.words,n=e.sigBytes,r=this._map;e.clamp();var i=[];for(var s=0;s<n;s+=3){var o=t[s>>>2]>>>24-s%4*8&255,u=t[s+1>>>2]>>>24-(s+1)%4*8&255,a=t[s+2>>>2]>>>24-(s+2)%4*8&255,f=o<<16|u<<8|a;for(var l=0;l<4&&s+l*.75<n;l++)i.push(r.charAt(f>>>6*(3-l)&63))}var c=r.charAt(64);if(c)while(i.length%4)i.push(c);return i.join("")},parse:function(e){var t=e.length,r=this._map,i=r.charAt(64);if(i){var s=e.indexOf(i);s!=-1&&(t=s)}var o=[],u=0;for(var a=0;a<t;a++)if(a%4){var f=r.indexOf(e.charAt(a-1))<<a%4*2,l=r.indexOf(e.charAt(a))>>>6-a%4*2;o[u>>>2]|=(f|l)<<24-u%4*8,u++}return n.create(o,u)},_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="}}(),define("crypto.enc-base64",function(){}),function(e){function a(e,t,n,r,i,s,o){var u=e+(t&n|~t&r)+i+o;return(u<<s|u>>>32-s)+t}function f(e,t,n,r,i,s,o){var u=e+(t&r|n&~r)+i+o;return(u<<s|u>>>32-s)+t}function l(e,t,n,r,i,s,o){var u=e+(t^n^r)+i+o;return(u<<s|u>>>32-s)+t}function c(e,t,n,r,i,s,o){var u=e+(n^(t|~r))+i+o;return(u<<s|u>>>32-s)+t}var t=CryptoJS,n=t.lib,r=n.WordArray,i=n.Hasher,s=t.algo,o=[];(function(){for(var t=0;t<64;t++)o[t]=e.abs(e.sin(t+1))*4294967296|0})();var u=s.MD5=i.extend({_doReset:function(){this._hash=new r.init([1732584193,4023233417,2562383102,271733878])},_doProcessBlock:function(e,t){for(var n=0;n<16;n++){var r=t+n,i=e[r];e[r]=(i<<8|i>>>24)&16711935|(i<<24|i>>>8)&4278255360}var s=this._hash.words,u=e[t+0],h=e[t+1],p=e[t+2],d=e[t+3],v=e[t+4],m=e[t+5],g=e[t+6],y=e[t+7],b=e[t+8],w=e[t+9],E=e[t+10],S=e[t+11],x=e[t+12],N=e[t+13],C=e[t+14],k=e[t+15],L=s[0],A=s[1],O=s[2],M=s[3];L=a(L,A,O,M,u,7,o[0]),M=a(M,L,A,O,h,12,o[1]),O=a(O,M,L,A,p,17,o[2]),A=a(A,O,M,L,d,22,o[3]),L=a(L,A,O,M,v,7,o[4]),M=a(M,L,A,O,m,12,o[5]),O=a(O,M,L,A,g,17,o[6]),A=a(A,O,M,L,y,22,o[7]),L=a(L,A,O,M,b,7,o[8]),M=a(M,L,A,O,w,12,o[9]),O=a(O,M,L,A,E,17,o[10]),A=a(A,O,M,L,S,22,o[11]),L=a(L,A,O,M,x,7,o[12]),M=a(M,L,A,O,N,12,o[13]),O=a(O,M,L,A,C,17,o[14]),A=a(A,O,M,L,k,22,o[15]),L=f(L,A,O,M,h,5,o[16]),M=f(M,L,A,O,g,9,o[17]),O=f(O,M,L,A,S,14,o[18]),A=f(A,O,M,L,u,20,o[19]),L=f(L,A,O,M,m,5,o[20]),M=f(M,L,A,O,E,9,o[21]),O=f(O,M,L,A,k,14,o[22]),A=f(A,O,M,L,v,20,o[23]),L=f(L,A,O,M,w,5,o[24]),M=f(M,L,A,O,C,9,o[25]),O=f(O,M,L,A,d,14,o[26]),A=f(A,O,M,L,b,20,o[27]),L=f(L,A,O,M,N,5,o[28]),M=f(M,L,A,O,p,9,o[29]),O=f(O,M,L,A,y,14,o[30]),A=f(A,O,M,L,x,20,o[31]),L=l(L,A,O,M,m,4,o[32]),M=l(M,L,A,O,b,11,o[33]),O=l(O,M,L,A,S,16,o[34]),A=l(A,O,M,L,C,23,o[35]),L=l(L,A,O,M,h,4,o[36]),M=l(M,L,A,O,v,11,o[37]),O=l(O,M,L,A,y,16,o[38]),A=l(A,O,M,L,E,23,o[39]),L=l(L,A,O,M,N,4,o[40]),M=l(M,L,A,O,u,11,o[41]),O=l(O,M,L,A,d,16,o[42]),A=l(A,O,M,L,g,23,o[43]),L=l(L,A,O,M,w,4,o[44]),M=l(M,L,A,O,x,11,o[45]),O=l(O,M,L,A,k,16,o[46]),A=l(A,O,M,L,p,23,o[47]),L=c(L,A,O,M,u,6,o[48]),M=c(M,L,A,O,y,10,o[49]),O=c(O,M,L,A,C,15,o[50]),A=c(A,O,M,L,m,21,o[51]),L=c(L,A,O,M,x,6,o[52]),M=c(M,L,A,O,d,10,o[53]),O=c(O,M,L,A,E,15,o[54]),A=c(A,O,M,L,h,21,o[55]),L=c(L,A,O,M,b,6,o[56]),M=c(M,L,A,O,k,10,o[57]),O=c(O,M,L,A,g,15,o[58]),A=c(A,O,M,L,N,21,o[59]),L=c(L,A,O,M,v,6,o[60]),M=c(M,L,A,O,S,10,o[61]),O=c(O,M,L,A,p,15,o[62]),A=c(A,O,M,L,w,21,o[63]),s[0]=s[0]+L|0,s[1]=s[1]+A|0,s[2]=s[2]+O|0,s[3]=s[3]+M|0},_doFinalize:function(){var t=this._data,n=t.words,r=this._nDataBytes*8,i=t.sigBytes*8;n[i>>>5]|=128<<24-i%32;var s=e.floor(r/4294967296),o=r;n[(i+64>>>9<<4)+15]=(s<<8|s>>>24)&16711935|(s<<24|s>>>8)&4278255360,n[(i+64>>>9<<4)+14]=(o<<8|o>>>24)&16711935|(o<<24|o>>>8)&4278255360,t.sigBytes=(n.length+1)*4,this._process();var u=this._hash,a=u.words;for(var f=0;f<4;f++){var l=a[f];a[f]=(l<<8|l>>>24)&16711935|(l<<24|l>>>8)&4278255360}return u},clone:function(){var e=i.clone.call(this);return e._hash=this._hash.clone(),e}});t.MD5=i._createHelper(u),t.HmacMD5=i._createHmacHelper(u)}(Math),define("crypto.md5",function(){}),function(){var e=CryptoJS,t=e.lib,n=t.Base,r=t.WordArray,i=e.algo,s=i.MD5,o=i.EvpKDF=n.extend({cfg:n.extend({keySize:4,hasher:s,iterations:1}),init:function(e){this.cfg=this.cfg.extend(e)},compute:function(e,t){var n=this.cfg,i=n.hasher.create(),s=r.create(),o=s.words,u=n.keySize,a=n.iterations;while(o.length<u){f&&i.update(f);var f=i.update(e).finalize(t);i.reset();for(var l=1;l<a;l++)f=i.finalize(f),i.reset();s.concat(f)}return s.sigBytes=u*4,s}});e.EvpKDF=function(e,t,n){return o.create(n).compute(e,t)}}(),define("crypto.evpkdf",function(){}),CryptoJS.lib.Cipher||function(e){var t=CryptoJS,n=t.lib,r=n.Base,i=n.WordArray,s=n.BufferedBlockAlgorithm,o=t.enc,u=o.Utf8,a=o.Base64,f=t.algo,l=f.EvpKDF,c=n.Cipher=s.extend({cfg:r.extend(),createEncryptor:function(e,t){return this.create(this._ENC_XFORM_MODE,e,t)},createDecryptor:function(e,t){return this.create(this._DEC_XFORM_MODE,e,t)},init:function(e,t,n){this.cfg=this.cfg.extend(n),this._xformMode=e,this._key=t,this.reset()},reset:function(){s.reset.call(this),this._doReset()},process:function(e){return this._append(e),this._process()},finalize:function(e){e&&this._append(e);var t=this._doFinalize();return t},keySize:4,ivSize:4,_ENC_XFORM_MODE:1,_DEC_XFORM_MODE:2,_createHelper:function(){function e(e){return typeof e=="string"?N:S}return function(t){return{encrypt:function(n,r,i){return e(r).encrypt(t,n,r,i)},decrypt:function(n,r,i){return e(r).decrypt(t,n,r,i)}}}}()}),h=n.StreamCipher=c.extend({_doFinalize:function(){var e=this._process(!0);return e},blockSize:1}),p=t.mode={},d=n.BlockCipherMode=r.extend({createEncryptor:function(e,t){return this.Encryptor.create(e,t)},createDecryptor:function(e,t){return this.Decryptor.create(e,t)},init:function(e,t){this._cipher=e,this._iv=t}}),v=p.CBC=function(){function n(t,n,r){var i=this._iv;if(i){var s=i;this._iv=e}else var s=this._prevBlock;for(var o=0;o<r;o++)t[n+o]^=s[o]}var t=d.extend();return t.Encryptor=t.extend({processBlock:function(e,t){var r=this._cipher,i=r.blockSize;n.call(this,e,t,i),r.encryptBlock(e,t),this._prevBlock=e.slice(t,t+i)}}),t.Decryptor=t.extend({processBlock:function(e,t){var r=this._cipher,i=r.blockSize,s=e.slice(t,t+i);r.decryptBlock(e,t),n.call(this,e,t,i),this._prevBlock=s}}),t}(),m=t.pad={},g=m.Pkcs7={pad:function(e,t){var n=t*4,r=n-e.sigBytes%n,s=r<<24|r<<16|r<<8|r,o=[];for(var u=0;u<r;u+=4)o.push(s);var a=i.create(o,r);e.concat(a)},unpad:function(e){var t=e.words[e.sigBytes-1>>>2]&255;e.sigBytes-=t}},y=n.BlockCipher=c.extend({cfg:c.cfg.extend({mode:v,padding:g}),reset:function(){c.reset.call(this);var e=this.cfg,t=e.iv,n=e.mode;if(this._xformMode==this._ENC_XFORM_MODE)var r=n.createEncryptor;else{var r=n.createDecryptor;this._minBufferSize=1}this._mode=r.call(n,this,t&&t.words)},_doProcessBlock:function(e,t){this._mode.processBlock(e,t)},_doFinalize:function(){var e=this.cfg.padding;if(this._xformMode==this._ENC_XFORM_MODE){e.pad(this._data,this.blockSize);var t=this._process(!0)}else{var t=this._process(!0);e.unpad(t)}return t},blockSize:4}),b=n.CipherParams=r.extend({init:function(e){this.mixIn(e)},toString:function(e){return(e||this.formatter).stringify(this)}}),w=t.format={},E=w.OpenSSL={stringify:function(e){var t=e.ciphertext,n=e.salt;if(n)var r=i.create([1398893684,1701076831]).concat(n).concat(t);else var r=t;return r.toString(a)},parse:function(e){var t=a.parse(e),n=t.words;if(n[0]==1398893684&&n[1]==1701076831){var r=i.create(n.slice(2,4));n.splice(0,4),t.sigBytes-=16}return b.create({ciphertext:t,salt:r})}},S=n.SerializableCipher=r.extend({cfg:r.extend({format:E}),encrypt:function(e,t,n,r){r=this.cfg.extend(r);var i=e.createEncryptor(n,r),s=i.finalize(t),o=i.cfg;return b.create({ciphertext:s,key:n,iv:o.iv,algorithm:e,mode:o.mode,padding:o.padding,blockSize:e.blockSize,formatter:r.format})},decrypt:function(e,t,n,r){r=this.cfg.extend(r),t=this._parse(t,r.format);var i=e.createDecryptor(n,r).finalize(t.ciphertext);return i},_parse:function(e,t){return typeof e=="string"?t.parse(e,this):e}}),x=t.kdf={},T=x.OpenSSL={execute:function(e,t,n,r){r||(r=i.random(8));var s=l.create({keySize:t+n}).compute(e,r),o=i.create(s.words.slice(t),n*4);return s.sigBytes=t*4,b.create({key:s,iv:o,salt:r})}},N=n.PasswordBasedCipher=S.extend({cfg:S.cfg.extend({kdf:T}),encrypt:function(e,t,n,r){r=this.cfg.extend(r);var i=r.kdf.execute(n,e.keySize,e.ivSize);r.iv=i.iv;var s=S.encrypt.call(this,e,t,i.key,r);return s.mixIn(i),s},decrypt:function(e,t,n,r){r=this.cfg.extend(r),t=this._parse(t,r.format);var i=r.kdf.execute(n,e.keySize,e.ivSize,t.salt);r.iv=i.iv;var s=S.decrypt.call(this,e,t,i.key,r);return s}})}(),define("crypto.cipher-core",function(){}),function(){var e=CryptoJS,t=e.lib,n=t.BlockCipher,r=e.algo,i=[],s=[],o=[],u=[],a=[],f=[],l=[],c=[],h=[],p=[];(function(){var e=[];for(var t=0;t<256;t++)t<128?e[t]=t<<1:e[t]=t<<1^283;var n=0,r=0;for(var t=0;t<256;t++){var d=r^r<<1^r<<2^r<<3^r<<4;d=d>>>8^d&255^99,i[n]=d,s[d]=n;var v=e[n],m=e[v],g=e[m],y=e[d]*257^d*16843008;o[n]=y<<24|y>>>8,u[n]=y<<16|y>>>16,a[n]=y<<8|y>>>24,f[n]=y;var y=g*16843009^m*65537^v*257^n*16843008;l[d]=y<<24|y>>>8,c[d]=y<<16|y>>>16,h[d]=y<<8|y>>>24,p[d]=y,n?(n=v^e[e[e[g^v]]],r^=e[e[r]]):n=r=1}})();var d=[0,1,2,4,8,16,32,64,128,27,54],v=r.AES=n.extend({_doReset:function(){var e=this._key,t=e.words,n=e.sigBytes/4,r=this._nRounds=n+6,s=(r+1)*4,o=this._keySchedule=[];for(var u=0;u<s;u++)if(u<n)o[u]=t[u];else{var a=o[u-1];u%n?n>6&&u%n==4&&(a=i[a>>>24]<<24|i[a>>>16&255]<<16|i[a>>>8&255]<<8|i[a&255]):(a=a<<8|a>>>24,a=i[a>>>24]<<24|i[a>>>16&255]<<16|i[a>>>8&255]<<8|i[a&255],a^=d[u/n|0]<<24),o[u]=o[u-n]^a}var f=this._invKeySchedule=[];for(var v=0;v<s;v++){var u=s-v;if(v%4)var a=o[u];else var a=o[u-4];v<4||u<=4?f[v]=a:f[v]=l[i[a>>>24]]^c[i[a>>>16&255]]^h[i[a>>>8&255]]^p[i[a&255]]}},encryptBlock:function(e,t){this._doCryptBlock(e,t,this._keySchedule,o,u,a,f,i)},decryptBlock:function(e,t){var n=e[t+1];e[t+1]=e[t+3],e[t+3]=n,this._doCryptBlock(e,t,this._invKeySchedule,l,c,h,p,s);var n=e[t+1];e[t+1]=e[t+3],e[t+3]=n},_doCryptBlock:function(e,t,n,r,i,s,o,u){var a=this._nRounds,f=e[t]^n[0],l=e[t+1]^n[1],c=e[t+2]^n[2],h=e[t+3]^n[3],p=4;for(var d=1;d<a;d++){var v=r[f>>>24]^i[l>>>16&255]^s[c>>>8&255]^o[h&255]^n[p++],m=r[l>>>24]^i[c>>>16&255]^s[h>>>8&255]^o[f&255]^n[p++],g=r[c>>>24]^i[h>>>16&255]^s[f>>>8&255]^o[l&255]^n[p++],y=r[h>>>24]^i[f>>>16&255]^s[l>>>8&255]^o[c&255]^n[p++];f=v,l=m,c=g,h=y}var v=(u[f>>>24]<<24|u[l>>>16&255]<<16|u[c>>>8&255]<<8|u[h&255])^n[p++],m=(u[l>>>24]<<24|u[c>>>16&255]<<16|u[h>>>8&255]<<8|u[f&255])^n[p++],g=(u[c>>>24]<<24|u[h>>>16&255]<<16|u[f>>>8&255]<<8|u[l&255])^n[p++],y=(u[h>>>24]<<24|u[f>>>16&255]<<16|u[l>>>8&255]<<8|u[c&255])^n[p++];e[t]=v,e[t+1]=m,e[t+2]=g,e[t+3]=y},keySize:8});e.AES=n._createHelper(v)}(),define("crypto.aes",function(){}),function(){var e=CryptoJS,t=e.lib,n=t.WordArray,r=t.Hasher,i=e.algo,s=[],o=i.SHA1=r.extend({_doReset:function(){this._hash=new n.init([1732584193,4023233417,2562383102,271733878,3285377520])},_doProcessBlock:function(e,t){var n=this._hash.words,r=n[0],i=n[1],o=n[2],u=n[3],a=n[4];for(var f=0;f<80;f++){if(f<16)s[f]=e[t+f]|0;else{var l=s[f-3]^s[f-8]^s[f-14]^s[f-16];s[f]=l<<1|l>>>31}var c=(r<<5|r>>>27)+a+s[f];f<20?c+=(i&o|~i&u)+1518500249:f<40?c+=(i^o^u)+1859775393:f<60?c+=(i&o|i&u|o&u)-1894007588:c+=(i^o^u)-899497514,a=u,u=o,o=i<<30|i>>>2,i=r,r=c}n[0]=n[0]+r|0,n[1]=n[1]+i|0,n[2]=n[2]+o|0,n[3]=n[3]+u|0,n[4]=n[4]+a|0},_doFinalize:function(){var e=this._data,t=e.words,n=this._nDataBytes*8,r=e.sigBytes*8;return t[r>>>5]|=128<<24-r%32,t[(r+64>>>9<<4)+14]=Math.floor(n/4294967296),t[(r+64>>>9<<4)+15]=n,e.sigBytes=t.length*4,this._process(),this._hash},clone:function(){var e=r.clone.call(this);return e._hash=this._hash.clone(),e}});e.SHA1=r._createHelper(o),e.HmacSHA1=r._createHmacHelper(o)}(),define("crypto.sha1",function(){}),function(e){var t=CryptoJS,n=t.lib,r=n.WordArray,i=n.Hasher,s=t.algo,o=[],u=[];(function(){function t(t){var n=e.sqrt(t);for(var r=2;r<=n;r++)if(!(t%r))return!1;return!0}function n(e){return(e-(e|0))*4294967296|0}var r=2,i=0;while(i<64)t(r)&&(i<8&&(o[i]=n(e.pow(r,.5))),u[i]=n(e.pow(r,1/3)),i++),r++})();var a=[],f=s.SHA256=i.extend({_doReset:function(){this._hash=new r.init(o.slice(0))},_doProcessBlock:function(e,t){var n=this._hash.words,r=n[0],i=n[1],s=n[2],o=n[3],f=n[4],l=n[5],c=n[6],h=n[7];for(var p=0;p<64;p++){if(p<16)a[p]=e[t+p]|0;else{var d=a[p-15],v=(d<<25|d>>>7)^(d<<14|d>>>18)^d>>>3,m=a[p-2],g=(m<<15|m>>>17)^(m<<13|m>>>19)^m>>>10;a[p]=v+a[p-7]+g+a[p-16]}var y=f&l^~f&c,b=r&i^r&s^i&s,w=(r<<30|r>>>2)^(r<<19|r>>>13)^(r<<10|r>>>22),E=(f<<26|f>>>6)^(f<<21|f>>>11)^(f<<7|f>>>25),S=h+E+y+u[p]+a[p],x=w+b;h=c,c=l,l=f,f=o+S|0,o=s,s=i,i=r,r=S+x|0}n[0]=n[0]+r|0,n[1]=n[1]+i|0,n[2]=n[2]+s|0,n[3]=n[3]+o|0,n[4]=n[4]+f|0,n[5]=n[5]+l|0,n[6]=n[6]+c|0,n[7]=n[7]+h|0},_doFinalize:function(){var t=this._data,n=t.words,r=this._nDataBytes*8,i=t.sigBytes*8;return n[i>>>5]|=128<<24-i%32,n[(i+64>>>9<<4)+14]=e.floor(r/4294967296),n[(i+64>>>9<<4)+15]=r,t.sigBytes=n.length*4,this._process(),this._hash},clone:function(){var e=i.clone.call(this);return e._hash=this._hash.clone(),e}});t.SHA256=i._createHelper(f),t.HmacSHA256=i._createHmacHelper(f)}(Math),define("crypto.sha256",function(){}),function(){var e=CryptoJS,t=e.lib,n=t.Base,r=e.enc,i=r.Utf8,s=e.algo,o=s.HMAC=n.extend({init:function(e,t){e=this._hasher=new e.init,typeof t=="string"&&(t=i.parse(t));var n=e.blockSize,r=n*4;t.sigBytes>r&&(t=e.finalize(t)),t.clamp();var s=this._oKey=t.clone(),o=this._iKey=t.clone(),u=s.words,a=o.words;for(var f=0;f<n;f++)u[f]^=1549556828,a[f]^=909522486;s.sigBytes=o.sigBytes=r,this.reset()},reset:function(){var e=this._hasher;e.reset(),e.update(this._iKey)},update:function(e){return this._hasher.update(e),this},finalize:function(e){var t=this._hasher,n=t.finalize(e);t.reset();var r=t.finalize(this._oKey.clone().concat(n));return r}})}(),define("crypto.hmac",function(){}),CryptoJS.pad.NoPadding={pad:function(){},unpad:function(){}},define("crypto.pad-nopadding",function(){}),CryptoJS.mode.CTR=function(){var e=CryptoJS.lib.BlockCipherMode.extend(),t=e.Encryptor=e.extend({processBlock:function(e,t){var n=this._cipher,r=n.blockSize,i=this._iv,s=this._counter;i&&(s=this._counter=i.slice(0),this._iv=undefined);var o=s.slice(0);n.encryptBlock(o,0),s[r-1]=s[r-1]+1|0;for(var u=0;u<r;u++)e[t+u]^=o[u]}});return e.Decryptor=t,e}(),define("crypto.mode-ctr",function(){}),function(e,t){typeof define=="function"&&define.amd?define("crypto",["crypto.core","crypto.enc-base64","crypto.md5","crypto.evpkdf","crypto.cipher-core","crypto.aes","crypto.sha1","crypto.sha256","crypto.hmac","crypto.pad-nopadding","crypto.mode-ctr"],function(){return CryptoJS}):e.CryptoJS=t()}(this),function(){function e(){}function n(e,t){var n=e.length;while(n--)if(e[n].listener===t)return n;return-1}function r(e){return function(){return this[e].apply(this,arguments)}}var t=e.prototype;t.getListeners=function(t){var n=this._getEvents(),r,i;if(typeof t=="object"){r={};for(i in n)n.hasOwnProperty(i)&&t.test(i)&&(r[i]=n[i])}else r=n[t]||(n[t]=[]);return r},t.flattenListeners=function(t){var n=[],r;for(r=0;r<t.length;r+=1)n.push(t[r].listener);return n},t.getListenersAsObject=function(t){var n=this.getListeners(t),r;return n instanceof Array&&(r={},r[t]=n),r||n},t.addListener=function(t,r){var i=this.getListenersAsObject(t),s=typeof r=="object",o;for(o in i)i.hasOwnProperty(o)&&n(i[o],r)===-1&&i[o].push(s?r:{listener:r,once:!1});return this},t.on=r("addListener"),t.addOnceListener=function(t,n){return this.addListener(t,{listener:n,once:!0})},t.once=r("addOnceListener"),t.defineEvent=function(t){return this.getListeners(t),this},t.defineEvents=function(t){for(var n=0;n<t.length;n+=1)this.defineEvent(t[n]);return this},t.removeListener=function(t,r){var i=this.getListenersAsObject(t),s,o;for(o in i)i.hasOwnProperty(o)&&(s=n(i[o],r),s!==-1&&i[o].splice(s,1));return this},t.off=r("removeListener"),t.addListeners=function(t,n){return this.manipulateListeners(!1,t,n)},t.removeListeners=function(t,n){return this.manipulateListeners(!0,t,n)},t.manipulateListeners=function(t,n,r){var i,s,o=t?this.removeListener:this.addListener,u=t?this.removeListeners:this.addListeners;if(typeof n!="object"||n instanceof RegExp){i=r.length;while(i--)o.call(this,n,r[i])}else for(i in n)n.hasOwnProperty(i)&&(s=n[i])&&(typeof s=="function"?o.call(this,i,s):u.call(this,i,s));return this},t.removeEvent=function(t){var n=typeof t,r=this._getEvents(),i;if(n==="string")delete r[t];else if(n==="object")for(i in r)r.hasOwnProperty(i)&&t.test(i)&&delete r[i];else delete this._events;return this},t.emitEvent=function(t,n){var r=this.getListenersAsObject(t),i,s,o,u;for(o in r)if(r.hasOwnProperty(o)){s=r[o].length;while(s--)i=r[o][s],i.once===!0&&this.removeListener(t,i.listener),u=i.listener.apply(this,n||[]),u===this._getOnceReturnValue()&&this.removeListener(t,i.listener)}return this},t.trigger=r("emitEvent"),t.emit=function(t){var n=Array.prototype.slice.call(arguments,1);return this.emitEvent(t,n)},t.setOnceReturnValue=function(t){return this._onceReturnValue=t,this},t._getOnceReturnValue=function(){return this.hasOwnProperty("_onceReturnValue")?this._onceReturnValue:!0},t._getEvents=function(){return this._events||(this._events={})},typeof define=="function"&&define.amd?define("eventemitter",[],function(){return e}):typeof module=="object"&&module.exports?module.exports=e:this.EventEmitter=e}.call(this),function(e,t){typeof define=="function"&&define.amd?define("otr",["bigint","crypto","eventemitter"],function(e,n,r){var i={BigInt:e,CryptoJS:n,EventEmitter:r,OTR:{},DSA:{}};return t.call(i)}):(e.OTR={},e.DSA={},t.call(e))}(this,function(){return function(){var e=this,t={N:"FFFFFFFFFFFFFFFFC90FDAA22168C234C4C6628B80DC1CD129024E088A67CC74020BBEA63B139B22514A08798E3404DDEF9519B3CD3A431B302B0A6DF25F14374FE1356D6D51C245E485B576625E7EC6F44C42E9A637ED6B0BFF5CB6F406B7EDEE386BFB5A899FA5AE9F24117C4B1FE649286651ECE45B3DC2007CB8A163BF0598DA48361C55D39A69163FA8FD24CF5F83655D23DCA3AD961C62F356208552BB9ED529077096966D670C354E4ABC9804F1746C08CA237327FFFFFFFFFFFFFFFF",G:"2",MSGSTATE_PLAINTEXT:0,MSGSTATE_ENCRYPTED:1,MSGSTATE_FINISHED:2,AUTHSTATE_NONE:0,AUTHSTATE_AWAITING_DHKEY:1,AUTHSTATE_AWAITING_REVEALSIG:2,AUTHSTATE_AWAITING_SIG:3,WHITESPACE_TAG:" ",WHITESPACE_TAG_V2:" ",WHITESPACE_TAG_V3:" ",OTR_TAG:"?OTR",OTR_VERSION_1:"\0",OTR_VERSION_2:"\0",OTR_VERSION_3:"\0",SMPSTATE_EXPECT0:0,SMPSTATE_EXPECT1:1,SMPSTATE_EXPECT2:2,SMPSTATE_EXPECT3:3,SMPSTATE_EXPECT4:4,STATUS_SEND_QUERY:0,STATUS_AKE_INIT:1,STATUS_AKE_SUCCESS:2,STATUS_END_OTR:3};typeof module!="undefined"&&module.exports?module.exports=t:e.OTR.CONST=t}.call(this),function(){var e=this,t={},n,r;typeof module!="undefined"&&module.exports?(module.exports=t={},n=require("../vendor/crypto.js"),r=require("../vendor/bigint.js")):(e.OTR&&(e.OTR.HLP=t),e.DSA&&(e.DSA.HLP=t),n=e.CryptoJS,r=e.BigInt);var i={BYTE:1,SHORT:2,INT:4,CTR:8,MAC:20,SIG:40},s="?OTR",o=".";t.debug=function(e){this.debug&&typeof this.debug!="function"&&typeof console!="undefined"&&console.log(e)},t.extend=function(e,t){function r(){this.constructor=e}for(var n in t)Object.hasOwnProperty.call(t,n)&&(e[n]=t[n]);r.prototype=t.prototype,e.prototype=new r,e.__super__=t.prototype},t.compare=function(e,t){if(e.length!==t.length)return!1;var n=0,r=0;for(;n<e.length;n++)r|=e[n].charCodeAt(0)^t[n].charCodeAt(0);return r===0},t.divMod=function(e,t,n){return r.multMod(e,r.inverseMod(t,n),n)},t.subMod=function(e,t,n){return e=r.mod(e,n),t=r.mod(t,n),r.greater(t,e)&&(e=r.add(e,n)),r.sub(e,t)},t.randomExponent=function(){return r.randBigInt(1536)},t.smpHash=function(e,r,s){var o=n.algo.SHA256.create();o.update(n.enc.Latin1.parse(t.packBytes(e,i.BYTE))),o.update(n.enc.Latin1.parse(t.packMPI(r))),s&&o.update(n.enc.Latin1.parse(t.packMPI(s)));var u=o.finalize();return t.bits2bigInt(u.toString(n.enc.Latin1))},t.makeMac=function(e,r){var i=n.enc.Latin1.parse(r),s=n.HmacSHA256(n.enc.Latin1.parse(e),i);return t.mask(s.toString(n.enc.Latin1),0,160)},t.make1Mac=function(e,t){var r=n.enc.Latin1.parse(t),i=n.HmacSHA1(n.enc.Latin1.parse(e),r);return i.toString(n.enc.Latin1)},t.encryptAes=function(e,t,r){var i={mode:n.mode.CTR,iv:n.enc.Latin1.parse(r),padding:n.pad.NoPadding},s=n.AES.encrypt(e,n.enc.Latin1.parse(t),i),o=n.enc.Base64.parse(s.toString());return n.enc.Latin1.stringify(o)},t.decryptAes=function(e,t,r){e=n.enc.Latin1.parse(e);var i={mode:n.mode.CTR,iv:n.enc.Latin1.parse(r),padding:n.pad.NoPadding};return n.AES.decrypt(n.enc.Base64.stringify(e),n.enc.Latin1.parse(t),i)},t.multPowMod=function(e,t,n,i,s){return r.multMod(r.powMod(e,t,s),r.powMod(n,i,s),s)},t.ZKP=function(e,n,i,s){return r.equals(n,t.smpHash(e,i,s))},t.GTOE=function(e,t){return r.equals(e,t)||r.greater(e,t)},t.between=function(e,t,n){return r.greater(e,t)&&r.greater(n,e)},t.checkGroup=function(e,n){var i=r.str2bigInt("2",10),s=r.sub(n,i);return t.GTOE(e,i)&&t.GTOE(s,e)};var u={XOR:function(e,t){return e^t},OR:function(e,t){return e|t},AND:function(e,t){return e&t}};t.bigBitWise=function(e,t,n){var i=t.length>n.length,s=i?n:t,o=i?t:n,a=o.length,f=r.expand(s,a),l=0;for(;l<a;l++)f[l]=u[e](f[l],o[l]);return f},t.h1=function(e,t){var r=n.algo.SHA1.create();return r.update(n.enc.Latin1.parse(e)),r.update(n.enc.Latin1.parse(t)),r.finalize().toString(n.enc.Latin1)},t.h2=function(e,t){var r=n.algo.SHA256.create();return r.update(n.enc.Latin1.parse(e)),r.update(n.enc.Latin1.parse(t)),r.finalize().toString(n.enc.Latin1)},t.mask=function(e,t,n){return e.substr(t/8,n/8)},t.twotothe=function(e){var t=[1<<e%r.bpe,0],n=0,i=Math.floor(e/r.bpe);for(;n<i;n++)t.unshift(0);return t},t.packBytes=function(e,t){e=e.toString(16);var n,r="";for(;t>0;t--)n=e.length?e.substr(-2,2):"0",e=e.substr(0,e.length-2),r=l(parseInt(n,16))+r;return r},t.packINT=function(e){return t.packBytes(e,i.INT)},t.packCtr=function(e){return t.padCtr(t.packBytes(e,i.CTR))},t.padCtr=function(e){return e+"\0\0\0\0\0\0\0\0"},t.unpackCtr=function(e){return e=t.toByteArray(e.substring(0,8)),t.unpack(e)},t.unpack=function(e){e.reverse();var t=0,n=0,r=e.length;for(;n<r;n++)t+=Math.pow(256,n)*e[n];return t},t.packData=function(e){return t.packINT(e.length)+e},t.bigInt2bits=function(e,t){t||(t=0),e=r.dup(e);var n="";while(!r.isZero(e))n=f[e[0]&255]+n,r.rightShift_(e,8);while(n.length<t)n="\0"+n;return n},t.bits2bigInt=function(e){return e=t.toByteArray(e),t.retMPI(e)},t.packMPI=function(e){return t.packData(t.bigInt2bits(r.trim(e,0)))},t.packSHORT=function(e){return t.packBytes(e,i.SHORT)},t.unpackSHORT=function(e){return e=t.toByteArray(e),t.unpack(e)},t.packTLV=function(e,n){return t.packSHORT(e)+t.packSHORT(n.length)+n},t.readLen=function(e){return e=t.toByteArray(e.substring(0,4)),t.unpack(e)},t.readData=function(e){var n=t.unpack(e.splice(0,4));return[n,e]},t.retMPI=function(e){var t=r.str2bigInt("0",10,e.length);return e.forEach(function(e,n){n&&r.leftShift_(t,8),t[0]|=e}),t},t.readMPI=function(e){return e=t.toByteArray(e),e=t.readData(e),t.retMPI(e[1])},t.packMPIs=function(e){return e.reduce(function(e,n){return e+t.packMPI(n)},"")},t.unpackMPIs=function(e,n){var r=0,i=[];for(;r<e;r++)i.push("MPI");return t.splitype(i,n).map(function(e){return t.readMPI(e)})},t.wrapMsg=function(e,r,i,u,a){e=n.enc.Base64.stringify(n.enc.Latin1.parse(e)),e=s+":"+e+o;var f;i&&(f="|",f+=t.readLen(u).toString(16),f+="|",f+=t.readLen(a).toString(16));if(!r)return[null,e];var l=Math.ceil(e.length/r);if(l>65535)return["Too many fragments"];if(l==1)return[null,e];var c,h,p,d,v,m=[];for(c=1;c<=l;c++)h=(c-1)*r,p=c*r,d=e.slice(h,p),v=s,i&&(v+=f),v+=","+c+",",v+=l+",",v+=d+",",m.push(v);return[null,m]},t.splitype=function p(e,n){var r=[];return e.forEach(function(e){var s;switch(e){case"PUBKEY":s=p(["SHORT","MPI","MPI","MPI","MPI"],n).join("");break;case"DATA":case"MPI":s=n.substring(0,t.readLen(n)+4);break;default:s=n.substring(0,i[e])}r.push(s),n=n.substring(s.length)}),r};var a={},f={},l=String.fromCharCode,c=0,h;for(;c<256;++c)h=l(c),a[h]=c,f[c]=h;for(c=128;c<256;++c)a[l(63232+c)]=c;t.toByteArray=function(e){var t=[],n=a,r,i=e.split(""),s=-1,o;o=i.length,r=o%8;while(r--)++s,t[s]=n[i[s]];r=o>>3;while(r--)t.push(n[i[++s]],n[i[++s]],n[i[++s]],n[i[++s]],n[i[++s]],n[i[++s]],n[i[++s]],n[i[++s]]);return t}}.call(this),function(){function f(){var e=(new Date).getTime();return function(t){if(!a||typeof console=="undefined")return;var n=(new Date).getTime();console.log(t+": "+(n-e)),e=n}}function l(e,t){var i=n.randBigInt(n.bitSize(t));return r.between(i,e,t)?i:l(e,t)}function h(e,t){var r,i=3e4,s=n.bitSize(e),o=n.primes;o.length===0&&(o=n.findPrimes(i)),c.length!=e.length&&(c=n.dup(e));for(r=0;r<o.length&&o[r]<=i;r++)if(n.modInt(e,o[r])===0&&!n.equalsInt(e,o[r]))return 0;for(r=0;r<t;r++){n.randBigInt_(c,s,0);while(!n.greater(e,c))n.randBigInt_(c,s,0);if(!n.millerRabin(e,c))return 0}return 1}function v(e){var t=f(),i=p[e].repeat,u=p[e].N,a=r.twotothe(e-1),l=4*e,c=!1,v,m,g,y;for(;;){v=n.randBigInt(u,1),v[0]|=1;if(!h(v,i))continue;t("q");for(y=0;y<l;y++){m=n.randBigInt(e,1),m[0]|=1,g=n.mod(m,v),g=n.sub(g,s),m=n.sub(m,g);if(n.greater(a,m))continue;if(!h(m,i))continue;t("p"),d[e]={p:m,q:v},c=!0;break}if(c)break}var b=n.dup(o),w=n.sub(m,s),E=n.multMod(w,n.inverseMod(v,m),m),S;for(;;){S=n.powMod(b,E,m);if(n.equals(S,s)){b=n.add(b,s);continue}d[e].g=S,t("g");return}throw new Error("Unreachable!")}function m(e,t){if(!(this instanceof m))return new m(e,t);t=t||{};if(e){var r=this;["p","q","g","y","x"].forEach(function(t){r[t]=e[t]}),this.type=e.type||u;return}var s=parseInt(t.bit_length?t.bit_length:1024,10);if(!p[s])throw new Error("Unsupported bit length.");d[s]||v(s),this.p=d[s].p,this.q=d[s].q,this.g=d[s].g,this.type=u,this.x=l(i,this.q),this.y=n.powMod(this.g,this.x,this.p),t.nocache&&(d[s]=null)}function g(e){var t,n;t=e.indexOf("("),n=e.lastIndexOf(")");if(t<0||n<0)throw new Error("Malformed S-Expression");e=e.substring(t+1,n);var r=e.search(/\s/),i={type:e.substring(0,r),val:[]};e=e.substring(r+1,n),t=e.indexOf("(");if(t<0)i.val.push(e);else{var s,o,u,a;while(t>-1){s=t+1,o=e.length;for(u=1,a=0;s<o&&a<u;s++)e[s]==="("&&u++,e[s]===")"&&a++;i.val.push(g(e.substring(t,++s))),e=e.substring(++s),t=e.indexOf("(")}}return i}function y(e){if(!e.type)throw new Error("Parse error.");var t,r;return e.type==="privkeys"?(t=[],e.val.forEach(function(e){t.push(y(e))}),t):(t={},e.val.forEach(function(e){r=e.val[0],typeof r=="string"?r.indexOf("#")===0&&(r=r.substring(1,r.lastIndexOf("#")),r=n.str2bigInt(r,16)):r=y(e),t[e.type]=r}),t)}var e=this,t,n,r;typeof module!="undefined"&&module.exports?(module.exports=m,t=require("../vendor/crypto.js"),n=require("../vendor/bigint.js"),r=require("./helpers.js")):(Object.keys(e.DSA).forEach(function(t){m[t]=e.DSA[t]}),e.DSA=m,t=e.CryptoJS,n=e.BigInt,r=m.HLP);var i=n.str2bigInt("0",10),s=n.str2bigInt("1",10),o=n.str2bigInt("2",10),u="\0\0",a=!1,c=[],p={1024:{N:160,repeat:40},2048:{N:224,repeat:56}},d={};m.prototype={constructor:m,packPublic:function(){var e=this.type;return e+=r.packMPI(this.p),e+=r.packMPI(this.q),e+=r.packMPI(this.g),e+=r.packMPI(this.y),e},packPrivate:function(){var e=this.packPublic()+r.packMPI(this.x);return e=t.enc.Latin1.parse(e),e.toString(t.enc.Base64)},generateNonce:function(e){var s=r.bigInt2bits(n.trim(this.x,0)),o=r.bigInt2bits(n.randBigInt(256)),u=t.algo.SHA256.create();u.update(t.enc.Latin1.parse(s)),u.update(e),u.update(t.enc.Latin1.parse(o));var a=u.finalize();return a=r.bits2bigInt(a.toString(t.enc.Latin1)),n.rightShift_(a,256-n.bitSize(this.q)),r.between(a,i,this.q)?a:this.generateNonce(e)},sign:function(e){e=t.enc.Latin1.parse(e);var r=n.str2bigInt(e.toString(t.enc.Hex),16),s,o=i,u=i;while(n.isZero(u)||n.isZero(o)){s=this.generateNonce(e),o=n.mod(n.powMod(this.g,s,this.p),this.q);if(n.isZero(o))continue;u=n.inverseMod(s,this.q),u=n.mult(u,n.add(r,n.mult(this.x,o))),u=n.mod(u,this.q)}return[o,u]},fingerprint:function(){var e=this.packPublic();return this.type===u&&(e=e.substring(2)),e=t.enc.Latin1.parse(e),t.SHA1(e).toString(t.enc.Hex)}},m.parsePublic=function(e,t){var n=["SHORT","MPI","MPI","MPI","MPI"];t&&n.push("MPI"),e=r.splitype(n,e);var i={type:e[0],p:r.readMPI(e[1]),q:r.readMPI(e[2]),g:r.readMPI(e[3]),y:r.readMPI(e[4])};return t&&(i.x=r.readMPI(e[5])),new m(i)},m.parsePrivate=function(e,n){return n?y(g(e))[0]["private-key"].dsa:(e=t.enc.Base64.parse(e),e=e.toString(t.enc.Latin1),m.parsePublic(e,!0))},m.verify=function(e,s,o,u){if(!r.between(o,i,e.q)||!r.between(u,i,e.q))return!1;var a=t.enc.Latin1.parse(s);a=n.str2bigInt(a.toString(t.enc.Hex),16);var f=n.inverseMod(u,e.q),l=n.multMod(a,f,e.q),c=n.multMod(o,f,e.q);l=n.powMod(e.g,l,e.p),c=n.powMod(e.y,c,e.p);var h=n.mod(n.multMod(l,c,e.p),e.q);return n.equals(h,o)}}.call(this),function(){var e=this,t={},n,r,i;typeof module!="undefined"&&module.exports?(module.exports=t,n=require("../vendor/crypto.js"),r=require("./const.js"),i=require("./helpers.js")):(e.OTR.Parse=t,n=e.CryptoJS,r=e.OTR.CONST,i=e.OTR.HLP);var s={};s[r.WHITESPACE_TAG_V2]=r.OTR_VERSION_2,s[r.WHITESPACE_TAG_V3]=r.OTR_VERSION_3,t.parseMsg=function(e,t){var o=[],u=t.indexOf(r.OTR_TAG);if(!~u){this.initFragment(e),l=t.indexOf(r.WHITESPACE_TAG);if(~l){t=t.split(""),t.splice(l,16);var a,f=t.length;for(;l<f;){a=t.slice(l,l+8).join("");if(Object.hasOwnProperty.call(s,a)){t.splice(l,8),o.push(s[a]);continue}l+=8}t=t.join("")}return{msg:t,ver:o}}var l=u+r.OTR_TAG.length,c=t[l];if(c===","||c==="|")return this.msgFragment(e,t.substring(l+1),c==="|");this.initFragment(e);if(~["?","v"].indexOf(c)){t[l]==="?"&&(o.push(r.OTR_VERSION_1),l+=1);var h={2:r.OTR_VERSION_2,3:r.OTR_VERSION_3},p=t.substring(l+1),d=p.indexOf("?");return d>=1&&(p=p.substring(0,d).split(""),t[l]==="v"&&p.forEach(function(e){Object.hasOwnProperty.call(h,e)&&o.push(h[e])})),{cls:"query",ver:o}}if(c===":"){l+=1;var v=t.substring(l,l+4);if(v.length<4)return{msg:t};v=n.enc.Base64.parse(v).toString(n.enc.Latin1);var m=v.substring(0,2),g=v.substring(2);if(!e["ALLOW_V"+i.unpackSHORT(m)])return{msg:t};l+=4;var y=t.substring(l).indexOf(".");if(!~y)return{msg:t};t=n.enc.Base64.parse(t.substring(l,l+y)),t=n.enc.Latin1.stringify(t);var b;m===r.OTR_VERSION_3&&(b=t.substring(0,8),t=t.substring(8));var w;return~["","\n","",""].indexOf(g)?w="ake":g===""&&(w="data"),{version:m,type:g,msg:t,cls:w,instance_tags:b}}return t.substring(l,l+7)===" Error:"?(e.ERROR_START_AKE&&e.sendQueryMsg(),{msg:t.substring(l+7),cls:"error"}):{msg:t}},t.initFragment=function(e){e.fragment={s:"",j:0,k:0}},t.msgFragment=function(e,t,n){t=t.split(",");if(n){var r=t.shift().split("|"),s=i.packINT(parseInt(r[0],16)),o=i.packINT(parseInt(r[1],16));if(e.checkInstanceTags(s+o))return}if(t.length<4||isNaN(parseInt(t[0],10))||isNaN(parseInt(t[1],10)))return;var u=parseInt(t[0],10),a=parseInt(t[1],10);t=t[2];if(a<u||a===0||u===0){this.initFragment(e);return}u===1?(this.initFragment(e),e.fragment={k:1,n:a,s:t}):a===e.fragment.n&&u===e.fragment.k+1?(e.fragment.s+=t,e.fragment.k+=1):this.initFragment(e);if(a===u)return t=e.fragment.s,this.initFragment(e),this.parseMsg(e,t);return}}.call(this),function(){function u(e,n,r,s,o){var u=t.enc.Latin1.parse(o),a=t.algo.HMAC.create(t.algo.SHA256,u);return a.update(t.enc.Latin1.parse(i.packMPI(e))),a.update(t.enc.Latin1.parse(i.packMPI(n))),a.update(t.enc.Latin1.parse(r)),a.update(t.enc.Latin1.parse(s)),a.finalize().toString(t.enc.Latin1)}function a(e){if(!(this instanceof a))return new a(e);this.otr=e,this.our_dh=e.our_old_dh,this.our_keyid=e.our_keyid-1,this.their_y=null,this.their_keyid=null,this.their_priv_pk=null,this.ssid=null,this.transmittedRS=!1,this.r=null,this.priv=e.priv;var t=this;["sendMsg"].forEach(function(e){t[e]=t[e].bind(t)})}var e=this,t,n,r,i,s;typeof module!="undefined"&&module.exports?(module.exports=a,t=require("../vendor/crypto.js"),n=require("../vendor/bigint.js"),r=require("./const.js"),i=require("./helpers.js"),s=require("./dsa.js")):(e.OTR.AKE=a,t=e.CryptoJS,n=e.BigInt,r=e.OTR.CONST,i=e.OTR.HLP,s=e.DSA);var o=n.str2bigInt(r.N,16);a.prototype={constructor:a,createKeys:function(e){var t=n.powMod(e,this.our_dh.privateKey,o),r=i.packMPI(t);this.ssid=i.mask(i.h2("\0",r),0,64);var s=i.h2("",r);this.c=i.mask(s,0,128),this.c_prime=i.mask(s,128,128),this.m1=i.h2("",r),this.m2=i.h2("",r),this.m1_prime=i.h2("",r),this.m2_prime=i.h2("",r)},verifySignMac:function(e,n,r,o,a,f,l,c){var h=i.makeMac(n,r);if(!i.compare(e,h))return["MACs do not match."];var p=i.decryptAes(n.substring(4),o,c);p=i.splitype(["PUBKEY","INT","SIG"],p.toString(t.enc.Latin1));var d=u(a,f,p[0],p[1],l),v=s.parsePublic(p[0]),m=i.bits2bigInt(p[2].substring(0,20)),g=i.bits2bigInt(p[2].substring(20));return s.verify(v,d,m,g)?[null,i.readLen(p[1]),v]:["Cannot verify signature of m."]},makeM:function(e,n,r,s){var o=this.priv.packPublic(),a=i.packINT(this.our_keyid),f=u(this.our_dh.publicKey,e,o,a,n);f=this.priv.sign(f);var l=o+a;l+=i.bigInt2bits(f[0],20),l+=i.bigInt2bits(f[1],20),l=t.enc.Latin1.parse(l);var c=i.packData(i.encryptAes(l,r,i.packCtr(0))),h=i.makeMac(c,s);return c+h},akeSuccess:function(e){i.debug.call(this.otr,"success");if(n.equals(this.their_y,this.our_dh.publicKey))return this.otr.error("equal keys - we have a problem.",!0);this.their_keyid!==this.otr.their_keyid&&this.their_keyid!==this.otr.their_keyid-1&&(this.otr.our_old_dh=this.our_dh,this.otr.their_y=this.their_y,this.otr.their_old_y=null,this.otr.their_keyid=this.their_keyid,this.otr.their_priv_pk=this.their_priv_pk,this.otr.sessKeys[0]=[new this.otr.DHSession(this.otr.our_dh,this.otr.their_y),null],this.otr.sessKeys[1]=[new this.otr.DHSession(this.otr.our_old_dh,this.otr.their_y),null]),this.otr.ssid=this.ssid,this.otr.transmittedRS=this.transmittedRS,this.otr_version=e,this.otr.authstate=r.AUTHSTATE_NONE,this.otr.msgstate=r.MSGSTATE_ENCRYPTED,this.r=null,this.myhashed=null,this.dhcommit=null,this.encrypted=null,this.hashed=null,this.otr.trigger("status",[r.STATUS_AKE_SUCCESS]),this.otr.sendStored()},handleAKE:function(e){var s,u,a,f=e.version;switch(e.type){case"":i.debug.call(this.otr,"d-h key message"),e=i.splitype(["DATA","DATA"],e.msg);if(this.otr.authstate===r.AUTHSTATE_AWAITING_DHKEY){var l=i.readMPI(this.myhashed),c=i.readMPI(e[1]);if(n.greater(l,c)){a="",s=this.dhcommit;break}this.our_dh=this.otr.dh(),this.otr.authstate=r.AUTHSTATE_NONE,this.r=null,this.myhashed=null}else this.otr.authstate===r.AUTHSTATE_AWAITING_SIG&&(this.our_dh=this.otr.dh());this.otr.authstate=r.AUTHSTATE_AWAITING_REVEALSIG,this.encrypted=e[0].substring(4),this.hashed=e[1].substring(4),a="\n",s=i.packMPI(this.our_dh.publicKey);break;case"\n":i.debug.call(this.otr,"reveal signature message"),e=i.splitype(["MPI"],e.msg);if(this.otr.authstate!==r.AUTHSTATE_AWAITING_DHKEY){if(this.otr.authstate!==r.AUTHSTATE_AWAITING_SIG)return;if(!n.equals(this.their_y,i.readMPI(e[0])))return}this.otr.authstate=r.AUTHSTATE_AWAITING_SIG,this.their_y=i.readMPI(e[0]);if(!i.checkGroup(this.their_y,o))return this.otr.error("Illegal g^y.",!0);this.createKeys(this.their_y),a="",s=i.packMPI(this.r),s+=this.makeM(this.their_y,this.m1,this.c,this.m2),this.m1=null,this.m2=null,this.c=null;break;case"":i.debug.call(this.otr,"signature message");if(this.otr.authstate!==r.AUTHSTATE_AWAITING_REVEALSIG)return;e=i.splitype(["DATA","DATA","MAC"],e.msg),this.r=i.readMPI(e[0]);var h=t.enc.Hex.parse(n.bigInt2str(this.r,16));h=t.enc.Latin1.stringify(h);var p=i.decryptAes(this.encrypted,h,i.packCtr(0));p=p.toString(t.enc.Latin1),this.their_y=i.readMPI(p);var d=t.SHA256(t.enc.Latin1.parse(p));if(!i.compare(this.hashed,d.toString(t.enc.Latin1)))return this.otr.error("Hashed g^x does not match.",!0);if(!i.checkGroup(this.their_y,o))return this.otr.error("Illegal g^x.",!0);this.createKeys(this.their_y),u=this.verifySignMac(e[2],e[1],this.m2,this.c,this.their_y,this.our_dh.publicKey,this.m1,i.packCtr(0));if(u[0])return this.otr.error(u[0],!0);this.their_keyid=u[1],this.their_priv_pk=u[2],s=this.makeM(this.their_y,this.m1_prime,this.c_prime,this.m2_prime),this.m1=null,this.m2=null,this.m1_prime=null,this.m2_prime=null,this.c=null,this.c_prime=null,this.sendMsg(f,"",s),this.akeSuccess(f);return;case"":i.debug.call(this.otr,"data message");if(this.otr.authstate!==r.AUTHSTATE_AWAITING_SIG)return;e=i.splitype(["DATA","MAC"],e.msg),u=this.verifySignMac(e[1],e[0],this.m2_prime,this.c_prime,this.their_y,this.our_dh.publicKey,this.m1_prime,i.packCtr(0));if(u[0])return this.otr.error(u[0],!0);this.their_keyid=u[1],this.their_priv_pk=u[2],this.m1_prime=null,this.m2_prime=null,this.c_prime=null,this.transmittedRS=!0,this.akeSuccess(f);return;default:return}this.sendMsg(f,a,s)},sendMsg:function(e,t,n){var s=e+t,o=e===r.OTR_VERSION_3;o&&(i.debug.call(this.otr,"instance tags"),s+=this.otr.our_instance_tag,s+=this.otr.their_instance_tag),s+=n,s=i.wrapMsg(s,this.otr.fragment_size,o,this.otr.our_instance_tag,this.otr.their_instance_tag);if(s[0])return this.otr.error(s[0]);this.otr._sendMsg(s[1],!0)},initiateAKE:function(e){i.debug.call(this.otr,"d-h commit message"),this.otr.trigger("status",[r.STATUS_AKE_INIT]),this.otr.authstate=r.AUTHSTATE_AWAITING_DHKEY;var s=i.packMPI(this.our_dh.publicKey);s=t.enc.Latin1.parse(s),this.r=n.randBigInt(128);var o=t.enc.Hex.parse(n.bigInt2str(this.r,16));o=t.enc.Latin1.stringify(o),this.myhashed=t.SHA256(s),this.myhashed=i.packData(this.myhashed.toString(t.enc.Latin1)),this.dhcommit=i.packData(i.encryptAes(s,o,i.packCtr(0))),this.dhcommit+=this.myhashed,this.sendMsg(e,"",this.dhcommit)}}}.call(this),function(){function f(e){if(!(this instanceof f))return new f(e);this.version=1,this.our_fp=e.our_fp,this.their_fp=e.their_fp,this.ssid=e.ssid,this.debug=!!e.debug,this.init()}var e=this,t,n,r,i,s;typeof module!="undefined"&&module.exports?(module.exports=f,t=require("../vendor/crypto.js"),n=require("../vendor/bigint.js"),r=require("../vendor/eventemitter.js"),i=require("./const.js"),s=require("./helpers.js")):(e.OTR.SM=f,t=e.CryptoJS,n=e.BigInt,r=e.EventEmitter,i=e.OTR.CONST,s=e.OTR.HLP);var o=n.str2bigInt(i.G,10),u=n.str2bigInt(i.N,16),a=n.sub(u,n.str2bigInt("1",10));n.divInt_(a,2),s.extend(f,r),f.prototype.init=function(){this.smpstate=i.SMPSTATE_EXPECT1,this.secret=null},f.prototype.makeSecret=function(e,n){var r=t.algo.SHA256.create();r.update(t.enc.Latin1.parse(s.packBytes(this.version,1))),r.update(t.enc.Hex.parse(e?this.our_fp:this.their_fp)),r.update(t.enc.Hex.parse(e?this.their_fp:this.our_fp)),r.update(t.enc.Latin1.parse(this.ssid)),r.update(t.enc.Latin1.parse(n));var i=r.finalize();this.secret=s.bits2bigInt(i.toString(t.enc.Latin1))},f.prototype.makeG2s=function(){this.a2=s.randomExponent(),this.a3=s.randomExponent(),this.g2a=n.powMod(o,this.a2,u),this.g3a=n.powMod(o,this.a3,u),(!s.checkGroup(this.g2a,u)||!s.checkGroup(this.g3a,u))&&this.makeG2s()},f.prototype.computeGs=function(e,t){this.g2=n.powMod(e,this.a2,u),this.g3=n.powMod(t,this.a3,u)},f.prototype.computePQ=function(e){this.p=n.powMod(this.g3,e,u),this.q=s.multPowMod(o,e,this.g2,this.secret,u)},f.prototype.computeR=function(){this.r=n.powMod(this.QoQ,this.a3,u)},f.prototype.computeRab=function(e){return n.powMod(e,this.a3,u)},f.prototype.computeC=function(e,t){return s.smpHash(e,n.powMod(o,t,u))},f.prototype.computeD=function(e,t,r){return s.subMod(e,n.multMod(t,r,a),a)},f.prototype.handleSM=function(e){var t,r,a,f,l,c,h,p,d,v,m,g,y,b,w={2:i.SMPSTATE_EXPECT1,3:i.SMPSTATE_EXPECT2,4:i.SMPSTATE_EXPECT3,5:i.SMPSTATE_EXPECT4,7:i.SMPSTATE_EXPECT1};if(e.type===6){this.init(),this.trigger("trust",[!1]);return}if(this.smpstate!==w[e.type])return this.abort();switch(this.smpstate){case i.SMPSTATE_EXPECT1:s.debug.call(this,"smp tlv 2");var E,S;e.type===7&&(E=e.msg.indexOf("\0"),S=e.msg.substring(0,E),e.msg=e.msg.substring(E+1)),y=s.readLen(e.msg.substr(0,4));if(y!==6)return this.abort();e=s.unpackMPIs(6,e.msg.substring(4));if(!s.checkGroup(e[0],u)||!s.checkGroup(e[3],u))return this.abort();if(!s.ZKP(1,e[1],s.multPowMod(o,e[2],e[0],e[1],u)))return this.abort();if(!s.ZKP(2,e[4],s.multPowMod(o,e[5],e[3],e[4],u)))return this.abort();this.g3ao=e[3],this.makeG2s(),r=s.randomExponent(),a=s.randomExponent(),this.c2=this.computeC(3,r),this.c3=this.computeC(4,a),this.d2=this.computeD(r,this.a2,this.c2),this.d3=this.computeD(a,this.a3,this.c3),this.computeGs(e[0],e[3]),this.smpstate=i.SMPSTATE_EXPECT0,this.trigger("question",[S]);return;case i.SMPSTATE_EXPECT2:s.debug.call(this,"smp tlv 3"),y=s.readLen(e.msg.substr(0,4));if(y!==11)return this.abort();e=s.unpackMPIs(11,e.msg.substring(4));if(!s.checkGroup(e[0],u)||!s.checkGroup(e[3],u)||!s.checkGroup(e[6],u)||!s.checkGroup(e[7],u))return this.abort();if(!s.ZKP(3,e[1],s.multPowMod(o,e[2],e[0],e[1],u)))return this.abort();if(!s.ZKP(4,e[4],s.multPowMod(o,e[5],e[3],e[4],u)))return this.abort();this.g3ao=e[3],this.computeGs(e[0],e[3]),l=s.multPowMod(this.g3,e[9],e[6],e[8],u),c=s.multPowMod(o,e[9],this.g2,e[10],u),c=n.multMod(c,n.powMod(e[7],e[8],u),u);if(!s.ZKP(5,e[8],l,c))return this.abort();var x=s.randomExponent();this.computePQ(x);var T=s.randomExponent(),C=s.randomExponent(),k=s.multPowMod(o,T,this.g2,C,u),L=s.smpHash(6,n.powMod(this.g3,T,u),k),A=this.computeD(T,x,L),O=this.computeD(C,this.secret,L);this.QoQ=s.divMod(this.q,e[7],u),this.PoP=s.divMod(this.p,e[6],u),this.computeR(),f=s.randomExponent(),v=n.powMod(this.QoQ,f,u),m=s.smpHash(7,n.powMod(o,f,u),v),g=this.computeD(f,this.a3,m),this.smpstate=i.SMPSTATE_EXPECT4,t=s.packINT(8)+s.packMPIs([this.p,this.q,L,A,O,this.r,m,g]),t=s.packTLV(4,t);break;case i.SMPSTATE_EXPECT3:s.debug.call(this,"smp tlv 4"),y=s.readLen(e.msg.substr(0,4));if(y!==8)return this.abort();e=s.unpackMPIs(8,e.msg.substring(4));if(!s.checkGroup(e[0],u)||!s.checkGroup(e[1],u)||!s.checkGroup(e[5],u))return this.abort();l=s.multPowMod(this.g3,e[3],e[0],e[2],u),c=s.multPowMod(o,e[3],this.g2,e[4],u),c=n.multMod(c,n.powMod(e[1],e[2],u),u);if(!s.ZKP(6,e[2],l,c))return this.abort();h=s.multPowMod(o,e[7],this.g3ao,e[6],u),this.QoQ=s.divMod(e[1],this.q,u),p=s.multPowMod(this.QoQ,e[7],e[5],e[6],u);if(!s.ZKP(7,e[6],h,p))return this.abort();this.computeR(),f=s.randomExponent(),v=n.powMod(this.QoQ,f,u),m=s.smpHash(8,n.powMod(o,f,u),v),g=this.computeD(f,this.a3,m),t=s.packINT(3)+s.packMPIs([this.r,m,g]),t=s.packTLV(5,t),d=this.computeRab(e[5]),b=!!n.equals(d,s.divMod(e[0],this.p,u)),this.trigger("trust",[b,"answered"]),this.init();break;case i.SMPSTATE_EXPECT4:s.debug.call(this,"smp tlv 5"),y=s.readLen(e.msg.substr(0,4));if(y!==3)return this.abort();e=s.unpackMPIs(3,e.msg.substring(4));if(!s.checkGroup(e[0],u))return this.abort();h=s.multPowMod(o,e[2],this.g3ao,e[1],u),p=s.multPowMod(this.QoQ,e[2],e[0],e[1],u);if(!s.ZKP(8,e[1],h,p))return this.abort();d=this.computeRab(e[0]),b=!!n.equals(d,this.PoP),this.trigger("trust",[b,"asked"]),this.init();return}this.sendMsg(t)},f.prototype.sendMsg=function(e){this.trigger("send",[this.ssid,"\0"+e])},f.prototype.rcvSecret=function(e,t){s.debug.call(this,"receive secret");var n,r=!1;this.smpstate===i.SMPSTATE_EXPECT0?n=this.answer:(n=this.initiate,r=!0),this.makeSecret(r,e),n.call(this,t)},f.prototype.answer=function(){s.debug.call(this,"smp answer");var e=s.randomExponent();this.computePQ(e);var t=s.randomExponent(),r=s.randomExponent(),a=s.multPowMod(o,t,this.g2,r,u),f=s.smpHash(5,n.powMod(this.g3,t,u),a),l=this.computeD(t,e,f),c=this.computeD(r,this.secret,f);this.smpstate=i.SMPSTATE_EXPECT3;var h=s.packINT(11)+s.packMPIs([this.g2a,this.c2,this.d2,this.g3a,this.c3,this.d3,this.p,this.q,f,l,c]);this.sendMsg(s.packTLV(3,h))},f.prototype.initiate=function(e){s.debug.call(this,"smp initiate"),this.smpstate!==i.SMPSTATE_EXPECT1&&this.abort(),this.makeG2s();var t=s.randomExponent(),n=s.randomExponent();this.c2=this.computeC(1,t),this.c3=this.computeC(2,n),this.d2=this.computeD(t,this.a2,this.c2),this.d3=this.computeD(n,this.a3,this.c3),this.smpstate=i.SMPSTATE_EXPECT2;var r="",o=2;e&&(r+=e,r+="\0",o=7),r+=s.packINT(6)+s.packMPIs([this.g2a,this.c2,this.d2,this.g3a,this.c3,this.d3]),this.sendMsg(s.packTLV(o,r))},f.prototype.abort=function(){this.init(),this.sendMsg(s.packTLV(6,"")),this.trigger("abort")}}.call(this),function(){function m(e){if(!(this instanceof m))return new m(e);e=e||{};if(!(!e.priv||e.priv instanceof c))throw new Error("Requires long-lived DSA key.");this.priv=e.priv?e.priv:new c,this.fragment_size=e.fragment_size||0;if(this.fragment_size<0)throw new Error("Fragment size must be a positive integer.");this.send_interval=e.send_interval||0;if(this.send_interval<0)throw new Error("Send interval must be a positive integer.");this.outgoing=[],this.our_instance_tag=e.instance_tag||m.makeInstanceTag(),this.debug=!!e.debug,this.smw=e.smw,this.init();var t=this;["sendMsg","receiveMsg"].forEach(function(e){t[e]=t[e].bind(t)}),r.call(this)}var e=this,t,n,r,i,s,o,u,a,f,l,c;typeof module!="undefined"&&module.exports?(module.exports=m,t=require("../vendor/crypto.js"),n=require("../vendor/bigint.js"),r=require("../vendor/eventemitter.js"),i=require("webworker-threads").Worker,s=require("path").join(__dirname,"/sm-webworker.js"),o=require("./const.js"),u=require("./helpers.js"),a=require("./parse.js"),f=require("./ake.js"),l=require("./sm.js"),c=require("./dsa.js"),m.CONST=o):(Object.keys(e.OTR).forEach(function(t){m[t]=e.OTR[t]}),e.OTR=m,t=e.CryptoJS,n=e.BigInt,r=e.EventEmitter,i=e.Worker,s="sm-webworker.js",o=m.CONST,u=m.HLP,a=m.Parse,f=m.AKE,l=m.SM,c=e.DSA);var h=n.str2bigInt(o.G,10),p=n.str2bigInt(o.N,16),d=Math.pow(2,53)-1,v=Math.pow(2,31)-1;u.extend(m,r),m.prototype.init=function(){this.msgstate=o.MSGSTATE_PLAINTEXT,this.authstate=o.AUTHSTATE_NONE,this.ALLOW_V2=!0,this.ALLOW_V3=!0,this.REQUIRE_ENCRYPTION=!1,this.SEND_WHITESPACE_TAG=!1,this.WHITESPACE_START_AKE=!1,this.ERROR_START_AKE=!1,a.initFragment(this),this.their_y=null,this.their_old_y=null,this.their_keyid=0,this.their_priv_pk=null,this.their_instance_tag="\0\0\0\0",this.our_dh=this.dh(),this.our_old_dh=this.dh(),this.our_keyid=2,this.sessKeys=[new Array(2),new Array(2)],this.storedMgs=[],this.oldMacKeys=[],this.sm=null,this._akeInit(),this.receivedPlaintext=!1},m.prototype._akeInit=function(){this.ake=new f(this),this.transmittedRS=!1,this.ssid=null},m.prototype._SMW=function(e,t){this.otr=e;var r={path:s,seed:n.getSeed};typeof e.smw=="object"&&Object.keys(e.smw).forEach(function(t){r[t]=e.smw[t]}),this.worker=new i(r.path);var o=this;this.worker.onmessage=function(e){var t=e.data;if(!t)return;o.trigger(t.method,t.args)},this.worker.postMessage({type:"seed",seed:r.seed(),imports:r.imports}),this.worker.postMessage({type:"init",reqs:t})},u.extend(m.prototype._SMW,r),["handleSM","rcvSecret","abort"].forEach(function(e){m.prototype._SMW.prototype[e]=function(){this.worker.postMessage({type:"method",method:e,args:Array.prototype.slice.call(arguments,0)})}}),m.prototype._smInit=function(){var e={ssid:this.ssid,our_fp:this.priv.fingerprint(),their_fp:this.their_priv_pk.fingerprint(),debug:this.debug};this.smw?(this.sm&&this.sm.worker.terminate(),this.sm=new this._SMW(this,e)):this.sm=new l(e);var t=this;["trust","abort","question"].forEach(function(e){t.sm.on(e,function(){t.trigger("smp",[e].concat(Array.prototype.slice.call(arguments)))})}),this.sm.on("send",function(e,n){t.ssid===e&&t._sendMsg(n)})},m.prototype.io=function(e){this.outgoing=this.outgoing.concat(e);var t=this;(function n(e){if(!e){if(!t.outgoing.length)return;var r=t.outgoing.shift();t.trigger("io",[r])}setTimeout(n,e?0:t.send_interval)})(!0)},m.prototype.dh=function(){var t={privateKey:n.randBigInt(320)};return t.publicKey=n.powMod(h,t.privateKey,p),t},m.prototype.DHSession=function g(e,r){if(!(this instanceof g))return new g(e,r);var i=n.powMod(r,e.privateKey,p),s=u.packMPI(i);this.id=u.mask(u.h2("\0",s),0,64);var o=n.greater(e.publicKey,r),a=o?"":"",f=o?"":"";this.sendenc=u.mask(u.h1(a,s),0,128),this.sendmac=t.SHA1(t.enc.Latin1.parse(this.sendenc)),this.sendmac=this.sendmac.toString(t.enc.Latin1),this.sendmacused=!1,this.rcvenc=u.mask(u.h1(f,s),0,128),this.rcvmac=t.SHA1(t.enc.Latin1.parse(this.rcvenc)),this.rcvmac=this.rcvmac.toString(t.enc.Latin1),this.rcvmacused=!1,this.extra_symkey=u.h2("ÿ",s),this.send_counter=0,this.rcv_counter=0},m.prototype.rotateOurKeys=function(){var e=this;this.sessKeys[1].forEach(function(t){t&&t.sendmacused&&e.oldMacKeys.push(t.sendmac),t&&t.rcvmacused&&e.oldMacKeys.push(t.rcvmac)}),this.our_old_dh=this.our_dh,this.our_dh=this.dh(),this.our_keyid+=1,this.sessKeys[1][0]=this.sessKeys[0][0],this.sessKeys[1][1]=this.sessKeys[0][1],this.sessKeys[0]=[this.their_y?new this.DHSession(this.our_dh,this.their_y):null,this.their_old_y?new this.DHSession(this.our_dh,this.their_old_y):null]},m.prototype.rotateTheirKeys=function(e){this.their_keyid+=1;var t=this;this.sessKeys.forEach(function(e){e[1]&&e[1].sendmacused&&t.oldMacKeys.push(e[1].sendmac),e[1]&&e[1].rcvmacused&&t.oldMacKeys.push(e[1].rcvmac)}),this.their_old_y=this.their_y,this.sessKeys[0][1]=this.sessKeys[0][0],this.sessKeys[1][1]=this.sessKeys[1][0],this.their_y=e,this.sessKeys[0][0]=new this.DHSession(this.our_dh,this.their_y),this.sessKeys[1][0]=new this.DHSession(this.our_old_dh,this.their_y)},m.prototype.prepareMsg=function(e,n){if(this.msgstate!==o.MSGSTATE_ENCRYPTED||this.their_keyid===0)return this.error("Not ready to encrypt.");var r=this.sessKeys[1][0];if(r.send_counter>=d)return this.error("Should have rekeyed by now.");r.send_counter+=1;var i=u.packCtr(r.send_counter),s=this.ake.otr_version+"",a=this.ake.otr_version===o.OTR_VERSION_3;a&&(s+=this.our_instance_tag,s+=this.their_instance_tag),s+="\0",s+=u.packINT(this.our_keyid-1),s+=u.packINT(this.their_keyid),s+=u.packMPI(this.our_dh.publicKey),s+=i.substring(0,8);if(Math.ceil(e.length/8)>=v)return this.error("Message is too long.");var f=u.encryptAes(t.enc.Latin1.parse(e),r.sendenc,i);return s+=u.packData(f),s+=u.make1Mac(s,r.sendmac),s+=u.packData(this.oldMacKeys.splice(0).join("")),r.sendmacused=!0,s=u.wrapMsg(s,this.fragment_size,a,this.our_instance_tag,this.their_instance_tag),s[0]?this.error(s[0]):(n&&this.trigger("file",["send",r.extra_symkey,n]),s[1])},m.prototype.handleDataMsg=function(e){var n=e.version+e.type;this.ake.otr_version===o.OTR_VERSION_3&&(n+=e.instance_tags);var r=["BYTE","INT","INT","MPI","CTR","DATA","MAC","DATA"];e=u.splitype(r,e.msg);var i=e[0]==="";if(this.msgstate!==o.MSGSTATE_ENCRYPTED||e.length!==8){i||this.error("Received an unreadable encrypted message.",!0);return}var s=this.our_keyid-u.readLen(e[2]),a=this.their_keyid-u.readLen(e[1]);if(s<0||s>1){i||this.error("Not of our latest keys.",!0);return}if(a<0||a>1){i||this.error("Not of your latest keys.",!0);return}var f=a?this.their_old_y:this.their_y;if(a===1&&!f){i||this.error("Do not have that key.");return}var l=this.sessKeys[s][a],c=u.unpackCtr(e[4]);if(c<=l.rcv_counter){i||this.error("Counter in message is not larger.");return}l.rcv_counter=c,n+=e.slice(0,6).join("");var h=u.make1Mac(n,l.rcvmac);if(!u.compare(e[6],h)){i||this.error("MACs do not match.");return}l.rcvmacused=!0;var p=u.decryptAes(e[5].substring(4),l.rcvenc,u.padCtr(e[4]));p=p.toString(t.enc.Latin1),s||this.rotateOurKeys(),a||this.rotateTheirKeys(u.readMPI(e[3]));var d=p.indexOf("\0");return~d&&(this.handleTLVs(p.substring(d+1),l),p=p.substring(0,d)),p=t.enc.Latin1.parse(p),p.toString(t.enc.Utf8)},m.prototype.handleTLVs=function(e,n){var r,i,s;for(;e.length;){r=u.unpackSHORT(e.substr(0,2)),i=u.unpackSHORT(e.substr(2,2)),s=e.substr(4,i);if(s.length<i)break;switch(r){case 1:this.msgstate=o.MSGSTATE_FINISHED,this.trigger("status",[o.STATUS_END_OTR]);break;case 2:case 3:case 4:case 5:case 6:case 7:if(this.msgstate!==o.MSGSTATE_ENCRYPTED){this.sm&&this.sm.abort();return}this.sm||this._smInit(),this.sm.handleSM({msg:s,type:r});break;case 8:s=s.substring(4),s=t.enc.Latin1.parse(s),s=s.toString(t.enc.Utf8),this.trigger("file",["receive",n.extra_symkey,s])}e=e.substring(4+i)}},m.prototype.smpSecret=function(e,t){if(this.msgstate!==o.MSGSTATE_ENCRYPTED)return this.error("Must be encrypted for SMP.");if(typeof e!="string"||e.length<1)return this.error("Secret is required.");this.sm||this._smInit(),this.sm.rcvSecret(e,t)},m.prototype.sendQueryMsg=function(){var e={},t=o.OTR_TAG;this.ALLOW_V2&&(e[2]=!0),this.ALLOW_V3&&(e[3]=!0);var n=Object.keys(e);n.length&&(t+="v",n.forEach(function(e){e!=="1"&&(t+=e)}),t+="?"),this._sendMsg(t,!0),this.trigger("status",[o.STATUS_SEND_QUERY])},m.prototype.sendMsg=function(e){if(this.REQUIRE_ENCRYPTION||this.msgstate!==o.MSGSTATE_PLAINTEXT)e=t.enc.Utf8.parse(e),e=e.toString(t.enc.Latin1);this._sendMsg(e)},m.prototype._sendMsg=function(e,t){if(!t)switch(this.msgstate){case o.MSGSTATE_PLAINTEXT:if(this.REQUIRE_ENCRYPTION){this.storedMgs.push(e),this.sendQueryMsg();return}this.SEND_WHITESPACE_TAG&&!this.receivedPlaintext&&(e+=o.WHITESPACE_TAG,this.ALLOW_V3&&(e+=o.WHITESPACE_TAG_V3),this.ALLOW_V2&&(e+=o.WHITESPACE_TAG_V2));break;case o.MSGSTATE_FINISHED:this.storedMgs.push(e),this.error("Message cannot be sent at this time.");return;default:e=this.prepareMsg(e)}e&&this.io(e)},m.prototype.receiveMsg=function(e){e=a.parseMsg(this,e);if(!e)return;switch(e.cls){case"error":this.error(e.msg);return;case"ake":if(e.version===o.OTR_VERSION_3&&this.checkInstanceTags(e.instance_tags))return;this.ake.handleAKE(e);return;case"data":if(e.version===o.OTR_VERSION_3&&this.checkInstanceTags(e.instance_tags))return;e.msg=this.handleDataMsg(e),e.encrypted=!0;break;case"query":this.msgstate===o.MSGSTATE_ENCRYPTED&&this._akeInit(),this.doAKE(e);break;default:(this.REQUIRE_ENCRYPTION||this.msgstate!==o.MSGSTATE_PLAINTEXT)&&this.error("Received an unencrypted message."),this.receivedPlaintext=!0,this.WHITESPACE_START_AKE&&e.ver.length>0&&this.doAKE(e)}e.msg&&this.trigger("ui",[e.msg,e.encrypted])},m.prototype.checkInstanceTags=function(e){var t=u.readLen(e.substr(0,4)),n=u.readLen(e.substr(4,4));if(n&&n!==u.readLen(this.our_instance_tag))return!0;if(u.readLen(this.their_instance_tag)){if(u.readLen(this.their_instance_tag)!==t)return!0}else{if(t<100)return!0;this.their_instance_tag=u.packINT(t)}},m.prototype.doAKE=function(e){this.ALLOW_V3&&~e.ver.indexOf(o.OTR_VERSION_3)?this.ake.initiateAKE(o.OTR_VERSION_3):this.ALLOW_V2&&~e.ver.indexOf(o.OTR_VERSION_2)?this.ake.initiateAKE(o.OTR_VERSION_2):this.error("OTR conversation requested, but no compatible protocol version found.")},m.prototype.error=function(e,t){if(t){this.debug||(e="An OTR error has occurred."),e="?OTR Error:"+e,this._sendMsg(e,!0);return}this.trigger("error",[e])},m.prototype.sendStored=function(){var e=this;this.storedMgs.splice(0).forEach(function(t){e._sendMsg(t)})},m.prototype.sendFile=function(e){if(this.msgstate!==o.MSGSTATE_ENCRYPTED)return this.error("Not ready to encrypt.");if(this.ake.otr_version!==o.OTR_VERSION_3)return this.error("Protocol v3 required.");if(!e)return this.error("Please specify a filename.");var n=t.enc.Utf8.parse(e);n=n.toString(t.enc.Latin1);if(n.length>=65532)return this.error("filename is too long.");var r="\0";r+="\0\b",r+=u.packSHORT(4+n.length),r+="\0\0\0",r+=n,r=this.prepareMsg(r,e),r&&this._sendMsg(r,!0)},m.prototype.endOtr=function(){this.msgstate===o.MSGSTATE_ENCRYPTED&&(this.sendMsg("\0\0\0\0"),this.sm&&(this.smw&&this.sm.worker.terminate(),this.sm=null)),this.msgstate=o.MSGSTATE_PLAINTEXT,this.receivedPlaintext=!1,this.trigger("status",[o.STATUS_END_OTR])},m.makeInstanceTag=function(){var e=n.randBigInt(32);return n.greater(n.str2bigInt("100",16),e)?m.makeInstanceTag():u.packINT(parseInt(n.bigInt2str(e,10),10))}}.call(this),{OTR:this.OTR,DSA:this.DSA}}),function(e,t){function l(e){return f.PF.compile(e||"nplurals=2; plural=(n != 1);")}function c(e,t){this._key=e,this._i18n=t}var n=Array.prototype,r=Object.prototype,i=n.slice,s=r.hasOwnProperty,o=n.forEach,u={},a={forEach:function(e,t,n){var r,i,a;if(e===null)return;if(o&&e.forEach===o)e.forEach(t,n);else if(e.length===+e.length){for(r=0,i=e.length;r<i;r++)if(r in e&&t.call(n,e[r],r,e)===u)return}else for(a in e)if(s.call(e,a)&&t.call(n,e[a],a,e)===u)return},extend:function(e){return this.forEach(i.call(arguments,1),function(t){for(var n in t)e[n]=t[n]}),e}},f=function(e){this.defaults={locale_data:{messages:{"":{domain:"messages",lang:"en",plural_forms:"nplurals=2; plural=(n != 1);"}}},domain:"messages"},this.options=a.extend({},this.defaults,e),this.textdomain(this.options.domain);if(e.domain&&!this.options.locale_data[this.options.domain])throw new Error("Text domain set to non-existent domain: `"+e.domain+"`")};f.context_delimiter=String.fromCharCode(4),a.extend(c.prototype,{onDomain:function(e){return this._domain=e,this},withContext:function(e){return this._context=e,this},ifPlural:function(e,t){return this._val=e,this._pkey=t,this},fetch:function(e){return{}.toString.call(e)!="[object Array]"&&(e=[].slice.call(arguments)),(e&&e.length?f.sprintf:function(e){return e})(this._i18n.dcnpgettext(this._domain,this._context,this._key,this._pkey,this._val),e)}}),a.extend(f.prototype,{translate:function(e){return new c(e,this)},textdomain:function(e){if(!e)return this._textdomain;this._textdomain=e},gettext:function(e){return this.dcnpgettext.call(this,t,t,e)},dgettext:function(e,n){return this.dcnpgettext.call(this,e,t,n)},dcgettext:function(e,n){return this.dcnpgettext.call(this,e,t,n)},ngettext:function(e,n,r){return this.dcnpgettext.call(this,t,t,e,n,r)},dngettext:function(e,n,r,i){return this.dcnpgettext.call(this,e,t,n,r,i)},dcngettext:function(e,n,r,i){return this.dcnpgettext.call(this,e,t,n,r,i)},pgettext:function(e,n){return this.dcnpgettext.call(this,t,e,n)},dpgettext:function(e,t,n){return this.dcnpgettext.call(this,e,t,n)},dcpgettext:function(e,t,n){return this.dcnpgettext.call(this,e,t,n)},npgettext:function(e,n,r,i){return this.dcnpgettext.call(this,t,e,n,r,i)},dnpgettext:function(e,t,n,r,i){return this.dcnpgettext.call(this,e,t,n,r,i)},dcnpgettext:function(e,t,n,r,i){r=r||n,e=e||this._textdomain,i=typeof i=="undefined"?1:i;var s;if(!this.options)return s=new f,s.dcnpgettext.call(s,undefined,undefined,n,r,i);if(!this.options.locale_data)throw new Error("No locale data provided.");if(!this.options.locale_data[e])throw new Error("Domain `"+e+"` was not found.");if(!this.options.locale_data[e][""])throw new Error("No locale meta information provided.");if(!n)throw new Error("No translation key found.");if(typeof i!="number"){i=parseInt(i,10);if(isNaN(i))throw new Error("The number that was passed in is not a number.")}var o=t?t+f.context_delimiter+n:n,u=this.options.locale_data,a=u[e],c=a[""].plural_forms||(u.messages||this.defaults.locale_data.messages)[""].plural_forms,h=l(c)(i)+1,p,d;if(!a)throw new Error("No domain named `"+e+"` could be found.");return p=a[o],!p||h>=p.length?(this.options.missing_key_callback&&this.options.missing_key_callback(o),d=[null,n,r],d[l(c)(i)+1]):(d=p[h],d?d:(d=[null,n,r],d[l(c)(i)+1]))}});var h=function(){function e(e){return Object.prototype.toString.call(e).slice(8,-1).toLowerCase()}function t(e,t){for(var n=[];t>0;n[--t]=e);return n.join("")}var n=function(){return n.cache.hasOwnProperty(arguments[0])||(n.cache[arguments[0]]=n.parse(arguments[0])),n.format.call(null,n.cache[arguments[0]],arguments)};return n.format=function(n,r){var i=1,s=n.length,o="",u,a=[],f,l,c,p,d,v;for(f=0;f<s;f++){o=e(n[f]);if(o==="string")a.push(n[f]);else if(o==="array"){c=n[f];if(c[2]){u=r[i];for(l=0;l<c[2].length;l++){if(!u.hasOwnProperty(c[2][l]))throw h('[sprintf] property "%s" does not exist',c[2][l]);u=u[c[2][l]]}}else c[1]?u=r[c[1]]:u=r[i++];if(/[^s]/.test(c[8])&&e(u)!="number")throw h("[sprintf] expecting number but found %s",e(u));if(typeof u=="undefined"||u===null)u="";switch(c[8]){case"b":u=u.toString(2);break;case"c":u=String.fromCharCode(u);break;case"d":u=parseInt(u,10);break;case"e":u=c[7]?u.toExponential(c[7]):u.toExponential();break;case"f":u=c[7]?parseFloat(u).toFixed(c[7]):parseFloat(u);break;case"o":u=u.toString(8);break;case"s":u=(u=String(u))&&c[7]?u.substring(0,c[7]):u;break;case"u":u=Math.abs(u);break;case"x":u=u.toString(16);break;case"X":u=u.toString(16).toUpperCase()}u=/[def]/.test(c[8])&&c[3]&&u>=0?"+"+u:u,d=c[4]?c[4]=="0"?"0":c[4].charAt(1):" ",v=c[6]-String(u).length,p=c[6]?t(d,v):"",a.push(c[5]?u+p:p+u)}}return a.join("")},n.cache={},n.parse=function(e){var t=e,n=[],r=[],i=0;while(t){if((n=/^[^\x25]+/.exec(t))!==null)r.push(n[0]);else if((n=/^\x25{2}/.exec(t))!==null)r.push("%");else{if((n=/^\x25(?:([1-9]\d*)\$|\(([^\)]+)\))?(\+)?(0|'[^$])?(-)?(\d+)?(?:\.(\d+))?([b-fosuxX])/.exec(t))===null)throw"[sprintf] huh?";if(n[2]){i|=1;var s=[],o=n[2],u=[];if((u=/^([a-z_][a-z_\d]*)/i.exec(o))===null)throw"[sprintf] huh?";s.push(u[1]);while((o=o.substring(u[0].length))!=="")if((u=/^\.([a-z_][a-z_\d]*)/i.exec(o))!==null)s.push(u[1]);else{if((u=/^\[(\d+)\]/.exec(o))===null)throw"[sprintf] huh?";s.push(u[1])}n[2]=s}else i|=2;if(i===3)throw"[sprintf] mixing positional and named placeholders is not (yet) supported";r.push(n)}t=t.substring(n[0].length)}return r},n}(),p=function(e,t){return t.unshift(e),h.apply(null,t)};f.parse_plural=function(e,t){return e=e.replace(/n/g,t),f.parse_expression(e)},f.sprintf=function(e,t){return{}.toString.call(t)=="[object Array]"?p(e,[].slice.call(t)):h.apply(this,[].slice.call(arguments))},f.prototype.sprintf=function(){return f.sprintf.apply(this,arguments)},f.PF={},f.PF.parse=function(e){var t=f.PF.extractPluralExpr(e);return f.PF.parser.parse.call(f.PF.parser,t)},f.PF.compile=function(e){function t(e){return e===!0?1:e?e:0}var n=f.PF.parse(e);return function(e){return t(f.PF.interpreter(n)(e))}},f.PF.interpreter=function(e){return function(t){var n;switch(e.type){case"GROUP":return f.PF.interpreter(e.expr)(t);case"TERNARY":if(f.PF.interpreter(e.expr)(t))return f.PF.interpreter(e.truthy)(t);return f.PF.interpreter(e.falsey)(t);case"OR":return f.PF.interpreter(e.left)(t)||f.PF.interpreter(e.right)(t);case"AND":return f.PF.interpreter(e.left)(t)&&f.PF.interpreter(e.right)(t);case"LT":return f.PF.interpreter(e.left)(t)<f.PF.interpreter(e.right)(t);case"GT":return f.PF.interpreter(e.left)(t)>f.PF.interpreter(e.right)(t);case"LTE":return f.PF.interpreter(e.left)(t)<=f.PF.interpreter(e.right)(t);case"GTE":return f.PF.interpreter(e.left)(t)>=f.PF.interpreter(e.right)(t);case"EQ":return f.PF.interpreter(e.left)(t)==f.PF.interpreter(e.right)(t);case"NEQ":return f.PF.interpreter(e.left)(t)!=f.PF.interpreter(e.right)(t);case"MOD":return f.PF.interpreter(e.left)(t)%f.PF.interpreter(e.right)(t);case"VAR":return t;case"NUM":return e.val;default:throw new Error("Invalid Token found.")}}},f.PF.extractPluralExpr=function(e){e=e.replace(/^\s\s*/,"").replace(/\s\s*$/,""),/;\s*$/.test(e)||(e=e.concat(";"));var t=/nplurals\=(\d+);/,n=/plural\=(.*);/,r=e.match(t),i={},s;if(r.length>1){i.nplurals=r[1],e=e.replace(t,""),s=e.match(n);if(!(s&&s.length>1))throw new Error("`plural` expression not found: "+e);return s[1]}throw new Error("nplurals not found in plural_forms string: "+e)},f.PF.parser=function(){var e={trace:function(){},yy:{},symbols_:{error:2,expressions:3,e:4,EOF:5,"?":6,":":7,"||":8,"&&":9,"<":10,"<=":11,">":12,">=":13,"!=":14,"==":15,"%":16,"(":17,")":18,n:19,NUMBER:20,$accept:0,$end:1},terminals_:{2:"error",5:"EOF",6:"?",7:":",8:"||",9:"&&",10:"<",11:"<=",12:">",13:">=",14:"!=",15:"==",16:"%",17:"(",18:")",19:"n",20:"NUMBER"},productions_:[0,[3,2],[4,5],[4,3],[4,3],[4,3],[4,3],[4,3],[4,3],[4,3],[4,3],[4,3],[4,3],[4,1],[4,1]],performAction:function(t,n,r,i,s,o,u){var a=o.length-1;switch(s){case 1:return{type:"GROUP",expr:o[a-1]};case 2:this.$={type:"TERNARY",expr:o[a-4],truthy:o[a-2],falsey:o[a]};break;case 3:this.$={type:"OR",left:o[a-2],right:o[a]};break;case 4:this.$={type:"AND",left:o[a-2],right:o[a]};break;case 5:this.$={type:"LT",left:o[a-2],right:o[a]};break;case 6:this.$={type:"LTE",left:o[a-2],right:o[a]};break;case 7:this.$={type:"GT",left:o[a-2],right:o[a]};break;case 8:this.$={type:"GTE",left:o[a-2],right:o[a]};break;case 9:this.$={type:"NEQ",left:o[a-2],right:o[a]};break;case 10:this.$={type:"EQ",left:o[a-2],right:o[a]};break;case 11:this.$={type:"MOD",left:o[a-2],right:o[a]};break;case 12:this.$={type:"GROUP",expr:o[a-1]};break;case 13:this.$={type:"VAR"};break;case 14:this.$={type:"NUM",val:Number(t)}}},table:[{3:1,4:2,17:[1,3],19:[1,4],20:[1,5]},{1:[3]},{5:[1,6],6:[1,7],8:[1,8],9:[1,9],10:[1,10],11:[1,11],12:[1,12],13:[1,13],14:[1,14],15:[1,15],16:[1,16]},{4:17,17:[1,3],19:[1,4],20:[1,5]},{5:[2,13],6:[2,13],7:[2,13],8:[2,13],9:[2,13],10:[2,13],11:[2,13],12:[2,13],13:[2,13],14:[2,13],15:[2,13],16:[2,13],18:[2,13]},{5:[2,14],6:[2,14],7:[2,14],8:[2,14],9:[2,14],10:[2,14],11:[2,14],12:[2,14],13:[2,14],14:[2,14],15:[2,14],16:[2,14],18:[2,14]},{1:[2,1]},{4:18,17:[1,3],19:[1,4],20:[1,5]},{4:19,17:[1,3],19:[1,4],20:[1,5]},{4:20,17:[1,3],19:[1,4],20:[1,5]},{4:21,17:[1,3],19:[1,4],20:[1,5]},{4:22,17:[1,3],19:[1,4],20:[1,5]},{4:23,17:[1,3],19:[1,4],20:[1,5]},{4:24,17:[1,3],19:[1,4],20:[1,5]},{4:25,17:[1,3],19:[1,4],20:[1,5]},{4:26,17:[1,3],19:[1,4],20:[1,5]},{4:27,17:[1,3],19:[1,4],20:[1,5]},{6:[1,7],8:[1,8],9:[1,9],10:[1,10],11:[1,11],12:[1,12],13:[1,13],14:[1,14],15:[1,15],16:[1,16],18:[1,28]},{6:[1,7],7:[1,29],8:[1,8],9:[1,9],10:[1,10],11:[1,11],12:[1,12],13:[1,13],14:[1,14],15:[1,15],16:[1,16]},{5:[2,3],6:[2,3],7:[2,3],8:[2,3],9:[1,9],10:[1,10],11:[1,11],12:[1,12],13:[1,13],14:[1,14],15:[1,15],16:[1,16],18:[2,3]},{5:[2,4],6:[2,4],7:[2,4],8:[2,4],9:[2,4],10:[1,10],11:[1,11],12:[1,12],13:[1,13],14:[1,14],15:[1,15],16:[1,16],18:[2,4]},{5:[2,5],6:[2,5],7:[2,5],8:[2,5],9:[2,5],10:[2,5],11:[2,5],12:[2,5],13:[2,5],14:[2,5],15:[2,5],16:[1,16],18:[2,5]},{5:[2,6],6:[2,6],7:[2,6],8:[2,6],9:[2,6],10:[2,6],11:[2,6],12:[2,6],13:[2,6],14:[2,6],15:[2,6],16:[1,16],18:[2,6]},{5:[2,7],6:[2,7],7:[2,7],8:[2,7],9:[2,7],10:[2,7],11:[2,7],12:[2,7],13:[2,7],14:[2,7],15:[2,7],16:[1,16],18:[2,7]},{5:[2,8],6:[2,8],7:[2,8],8:[2,8],9:[2,8],10:[2,8],11:[2,8],12:[2,8],13:[2,8],14:[2,8],15:[2,8],16:[1,16],18:[2,8]},{5:[2,9],6:[2,9],7:[2,9],8:[2,9],9:[2,9],10:[2,9],11:[2,9],12:[2,9],13:[2,9],14:[2,9],15:[2,9],16:[1,16],18:[2,9]},{5:[2,10],6:[2,10],7:[2,10],8:[2,10],9:[2,10],10:[2,10],11:[2,10],12:[2,10],13:[2,10],14:[2,10],15:[2,10],16:[1,16],18:[2,10]},{5:[2,11],6:[2,11],7:[2,11],8:[2,11],9:[2,11],10:[2,11],11:[2,11],12:[2,11],13:[2,11],14:[2,11],15:[2,11],16:[2,11],18:[2,11]},{5:[2,12],6:[2,12],7:[2,12],8:[2,12],9:[2,12],10:[2,12],11:[2,12],12:[2,12],13:[2,12],14:[2,12],15:[2,12],16:[2,12],18:[2,12]},{4:30,17:[1,3],19:[1,4],20:[1,5]},{5:[2,2],6:[1,7],7:[2,2],8:[1,8],9:[1,9],10:[1,10],11:[1,11],12:[1,12],13:[1,13],14:[1,14],15:[1,15],16:[1,16],18:[2,2]}],defaultActions:{6:[2,1]},parseError:function(t,n){throw new Error(t)},parse:function(t){function d(e){r.length=r.length-2*e,i.length=i.length-e,s.length=s.length-e}function v(){var e;return e=n.lexer.lex()||1,typeof e!="number"&&(e=n.symbols_[e]||e),e}var n=this,r=[0],i=[null],s=[],o=this.table,u="",a=0,f=0,l=0,c=2,h=1;this.lexer.setInput(t),this.lexer.yy=this.yy,this.yy.lexer=this.lexer,typeof this.lexer.yylloc=="undefined"&&(this.lexer.yylloc={});var p=this.lexer.yylloc;s.push(p),typeof this.yy.parseError=="function"&&(this.parseError=this.yy.parseError);var m,g,y,b,w,E,S={},x,T,N,C;for(;;){y=r[r.length-1],this.defaultActions[y]?b=this.defaultActions[y]:(m==null&&(m=v()),b=o[y]&&o[y][m]);if(typeof b=="undefined"||!b.length||!b[0]){if(!l){C=[];for(x in o[y])this.terminals_[x]&&x>2&&C.push("'"+this.terminals_[x]+"'");var k="";this.lexer.showPosition?k="Parse error on line "+(a+1)+":\n"+this.lexer.showPosition()+"\nExpecting "+C.join(", ")+", got '"+this.terminals_[m]+"'":k="Parse error on line "+(a+1)+": Unexpected "+(m==1?"end of input":"'"+(this.terminals_[m]||m)+"'"),this.parseError(k,{text:this.lexer.match,token:this.terminals_[m]||m,line:this.lexer.yylineno,loc:p,expected:C})}if(l==3){if(m==h)throw new Error(k||"Parsing halted.");f=this.lexer.yyleng,u=this.lexer.yytext,a=this.lexer.yylineno,p=this.lexer.yylloc,m=v()}for(;;){if(c.toString()in o[y])break;if(y==0)throw new Error(k||"Parsing halted.");d(1),y=r[r.length-1]}g=m,m=c,y=r[r.length-1],b=o[y]&&o[y][c],l=3}if(b[0]instanceof Array&&b.length>1)throw new Error("Parse Error: multiple actions possible at state: "+y+", token: "+m);switch(b[0]){case 1:r.push(m),i.push(this.lexer.yytext),s.push(this.lexer.yylloc),r.push(b[1]),m=null,g?(m=g,g=null):(f=this.lexer.yyleng,u=this.lexer.yytext,a=this.lexer.yylineno,p=this.lexer.yylloc,l>0&&l--);break;case 2:T=this.productions_[b[1]][1],S.$=i[i.length-T],S._$={first_line:s[s.length-(T||1)].first_line,last_line:s[s.length-1].last_line,first_column:s[s.length-(T||1)].first_column,last_column:s[s.length-1].last_column},E=this.performAction.call(S,u,f,a,this.yy,b[1],i,s);if(typeof E!="undefined")return E;T&&(r=r.slice(0,-1*T*2),i=i.slice(0,-1*T),s=s.slice(0,-1*T)),r.push(this.productions_[b[1]][0]),i.push(S.$),s.push(S._$),N=o[r[r.length-2]][r[r.length-1]],r.push(N);break;case 3:return!0}}return!0}},t=function(){var e={EOF:1,parseError:function(t,n){if(!this.yy.parseError)throw new Error(t);this.yy.parseError(t,n)},setInput:function(e){return this._input=e,this._more=this._less=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this},input:function(){var e=this._input[0];this.yytext+=e,this.yyleng++,this.match+=e,this.matched+=e;var t=e.match(/\n/);return t&&this.yylineno++,this._input=this._input.slice(1),e},unput:function(e){return this._input=e+this._input,this},more:function(){return this._more=!0,this},pastInput:function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?"...":"")+e.substr(-20).replace(/\n/g,"")},upcomingInput:function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?"...":"")).replace(/\n/g,"")},showPosition:function(){var e=this.pastInput(),t=(new Array(e.length+1)).join("-");return e+this.upcomingInput()+"\n"+t+"^"},next:function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext="",this.match="");var i=this._currentRules();for(var s=0;s<i.length;s++){t=this._input.match(this.rules[i[s]]);if(t){r=t[0].match(/\n.*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-1:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,this.yyleng=this.yytext.length,this._more=!1,this._input=this._input.slice(t[0].length),this.matched+=t[0],e=this.performAction.call(this,this.yy,this,i[s],this.conditionStack[this.conditionStack.length-1]);if(e)return e;return}}if(this._input==="")return this.EOF;this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},lex:function(){var t=this.next();return typeof t!="undefined"?t:this.lex()},begin:function(t){this.conditionStack.push(t)},popState:function(){return this.conditionStack.pop()},_currentRules:function(){return this.conditions[this.conditionStack[this.conditionStack.length-1]].rules},topState:function(){return this.conditionStack[this.conditionStack.length-2]},pushState:function(t){this.begin(t)}};return e.performAction=function(t,n,r,i){var s=i;switch(r){case 0:break;case 1:return 20;case 2:return 19;case 3:return 8;case 4:return 9;case 5:return 6;case 6:return 7;case 7:return 11;case 8:return 13;case 9:return 10;case 10:return 12;case 11:return 14;case 12:return 15;case 13:return 16;case 14:return 17;case 15:return 18;case 16:return 5;case 17:return"INVALID"}},e.rules=[/^\s+/,/^[0-9]+(\.[0-9]+)?\b/,/^n\b/,/^\|\|/,/^&&/,/^\?/,/^:/,/^<=/,/^>=/,/^</,/^>/,/^!=/,/^==/,/^%/,/^\(/,/^\)/,/^$/,/^./],e.conditions={INITIAL:{rules:[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17],inclusive:!0}},e}();return e.lexer=t,e}(),typeof exports!="undefined"?(typeof module!="undefined"&&module.exports&&(exports=module.exports=f),exports.Jed=f):(typeof define=="function"&&define.amd&&define("jed",[],function(){return f}),e.Jed=f)}(this),function(e,t){var n={domain:"converse",locale_data:{converse:{"":{"Project-Id-Version":"Converse.js 0.4","Report-Msgid-Bugs-To":"","POT-Creation-Date":"2013-09-15 21:55+0200","PO-Revision-Date":"2013-09-15 21:56+0200","Last-Translator":"JC Brand <jc@opkode.com>","Language-Team":"Afrikaans",Language:"af","MIME-Version":"1.0","Content-Type":"text/plain; charset=UTF-8","Content-Transfer-Encoding":"8bit",domain:"converse",lang:"af",plural_forms:"nplurals=2; plural=(n != 1);"},unencrypted:[null,"nie-privaat"],unverified:[null,"ongeverifieer"],verified:[null,"privaat"],finished:[null,"afgesluit"],Disconnected:[null,"Verbindung onderbreek"],Error:[null,"Fout"],Connecting:[null,"Verbind tans"],"Connection Failed":[null,"Verbinding het gefaal"],Authenticating:[null,"Besig om te bekragtig"],"Authentication Failed":[null,"Bekragtiging het gefaal"],Disconnecting:[null,"Onderbreek verbinding"],"Re-establishing encrypted session":[null,"Herstel versleutelde sessie"],"Your browser needs to generate a private key, which will be used in your encrypted chat session. This can take up to 30 seconds during which your browser might freeze and become unresponsive.":[null,"Die webblaaier moet 'n private sleutel vir die versleutelde klets-sessie genereer. Dit kan tot 30 sekondes duur, waartydenѕ die webblaaier mag vries en nie reageer nie."],"Private key generated.":[null,"Private sleutel"],"Authentication request from %1$s\n\nYour buddy is attempting to verify your identity, by asking you the question below.\n\n%2$s":[null,"Verifikasie versoek van %1$s\n\nU gespreksmaat probeer om u identiteit te verifieer, deur die volgende vraag te vra \n\n%2$s"],"Could not verify this user's identify.":[null,"Kon nie hierdie gebruiker se identitied verifieer nie."],"Personal message":[null,"Persoonlike boodskap"],"Start encrypted conversation":[null,"Begin versleutelde gesprek"],"Refresh encrypted conversation":[null,"Verfris versleutelde gesprek"],"End encrypted conversation":[null,"Beëindig versleutelde gesprek"],"Verify with SMP":[null,"Verifieer met SMP"],"Verify with fingerprints":[null,"Verifieer met vingerafdrukke"],"What's this?":[null,"Wat is hierdie?"],me:[null,"ek"],"Show this menu":[null,"Vertoon hierdie keuselys"],"Write in the third person":[null,"Skryf in die derde persoon"],"Remove messages":[null,"Verwyder boodskappe"],"Your message could not be sent":[null,"U boodskap kon nie gestuur word nie"],"We received an unencrypted message":[null,"Ons het 'n onversleutelde boodskap ontvang"],"We received an unreadable encrypted message":[null,"Ons het 'n onleesbare versleutelde boodskap ontvang"],"This user has requested an encrypted session.":[null,"Hierdie gebruiker versoek 'n versleutelde sessie"],"Here are the fingerprints, please confirm them with %1$s, outside of this chat.\n\nFingerprint for you, %2$s: %3$s\n\nFingerprint for %1$s: %4$s\n\nIf you have confirmed that the fingerprints match, click OK, otherwise click Cancel.":[null,"Hier is die vingerafdrukke, bevestig hulle met %1$s, buite hierdie kletskanaal \n\nU vingerafdruk, %2$s: %3$s\n\nVingerafdruk vir %1$s: %4$s\n\nIndien u die vingerafdrukke bevestig het, klik OK, andersinds klik Kanselleer"],"You will be prompted to provide a security question and then an answer to that question.\n\nYour buddy will then be prompted the same question and if they type the exact same answer (case sensitive), their identity will have been verified.":[null,"Daar sal van u verwag word om 'n sekuriteitsvraag te stel, en dan ook die antwoord tot daardie vraag te verskaf.\n\nU gespreksmaat sal dan daardie vraag gestel word, en indien hulle presies dieselfde antwoord (hoofletters tel) verskaf, sal hul identiteit geverifieer wees."],"What is your security question?":[null,"Wat is u sekuriteitsvraag?"],"What is the answer to the security question?":[null,"Wat is die antwoord tot die sekuriteitsvraag?"],"Invalid authentication scheme provided":[null,"Ongeldige verifikasiemetode verskaf"],"Your messages are not encrypted anymore":[null,"U boodskappe is nie meer versleutel nie"],"Your messages are now encrypted but your buddy's identity has not been verified.":[null,"U boodskappe is now versleutel maar u gespreksmaat se identiteit is nog onseker."],"Your buddy's identify has been verified.":[null,"U gespreksmaat se identiteit is geverifieer."],"Your buddy has ended encryption on their end, you should do the same.":[null,"U gespreksmaat het versleuteling gestaak, u behoort nou dieselfde te doen."],"Your messages are not encrypted. Click here to enable OTR encryption.":[null,"U boodskappe is nie versleutel nie. Klik hier om OTR versleuteling te aktiveer."],"Your messages are encrypted, but your buddy has not been verified.":[null,"U boodskappe is versleutel, maar u gespreksmaat se identiteit is not onseker."],"Your messages are encrypted and your buddy verified.":[null,"U boodskappe is versleutel en u gespreksmaat se identiteit geverifieer."],"Your buddy has closed their end of the private session, you should do the same":[null,"U gespreksmaat het die private sessie gestaak. U behoort dieselfde te doen"],Contacts:[null,"Kontakte"],Online:[null,"Aangemeld"],Busy:[null,"Besig"],Away:[null,"Afwesig"],Offline:[null,"Afgemeld"],"Click to add new chat contacts":[null,"Kliek om nuwe kletskontakte by te voeg"],"Add a contact":[null,"Voeg 'n kontak by"],"Contact username":[null,"Konak gebruikersnaam"],Add:[null,"Voeg by"],"Contact name":[null,"Kontaknaam"],Search:[null,"Soek"],"No users found":[null,"Geen gebruikers gevind"],"Click to add as a chat contact":[null,"Kliek om as kletskontak by te voeg"],"Click to open this room":[null,"Kliek om hierdie kletskamer te open"],"Show more information on this room":[null,"Wys meer inligting aangaande hierdie kletskamer"],"Description:":[null,"Beskrywing:"],"Occupants:":[null,"Deelnemers:"],"Features:":[null,"Eienskappe:"],"Requires authentication":[null,"Benodig magtiging"],Hidden:[null,"Verskuil"],"Requires an invitation":[null,"Benodig 'n uitnodiging"],Moderated:[null,"Gemodereer"],"Non-anonymous":[null,"Nie-anoniem"],"Open room":[null,"Oop kletskamer"],"Permanent room":[null,"Permanente kamer"],Public:[null,"Publiek"],"Semi-anonymous":[null,"Deels anoniem"],"Temporary room":[null,"Tydelike kamer"],Unmoderated:[null,"Ongemodereer"],Rooms:[null,"Kamers"],"Room name":[null,"Kamer naam"],Nickname:[null,"Bynaam"],Server:[null,"Bediener"],Join:[null,"Sluit aan"],"Show rooms":[null,"Wys kamers"],"No rooms on %1$s":[null,"Geen kamers op %1$s"],"Rooms on %1$s":[null,"Kamers op %1$s"],"Set chatroom topic":[null,"Stel kletskamer onderwerp"],"Kick user from chatroom":[null,"Skop gebruiker uit die kletskamer"],"Ban user from chatroom":[null,"Verban gebruiker vanuit die kletskamer"],Message:[null,"Boodskap"],Save:[null,"Stoor"],Cancel:[null,"Kanseleer"],"An error occurred while trying to save the form.":[null,"A fout het voorgekom terwyl probeer is om die vorm te stoor."],"This chatroom requires a password":[null,"Hiedie kletskamer benodig 'n wagwoord"],"Password: ":[null,"Wagwoord:"],Submit:[null,"Dien in"],"This room is not anonymous":[null,"Hierdie vertrek is nie anoniem nie"],"This room now shows unavailable members":[null,"Hierdie vertrek wys nou onbeskikbare lede"],"This room does not show unavailable members":[null,"Hierdie vertrek wys nie onbeskikbare lede nie"],"Non-privacy-related room configuration has changed":[null,"Nie-privaatheidverwante kamer instellings het verander"],"Room logging is now enabled":[null,"Kamer log is nou aangeskakel"],"Room logging is now disabled":[null,"Kamer log is nou afgeskakel"],"This room is now non-anonymous":[null,"Hiedie kamer is nou nie anoniem nie"],"This room is now semi-anonymous":[null,"Hierdie kamer is nou gedeeltelik anoniem"],"This room is now fully-anonymous":[null,"Hierdie kamer is nou ten volle anoniem"],"A new room has been created":[null,"'n Nuwe kamer is geskep"],"Your nickname has been changed":[null,"Jou bynaam is verander"],"<strong>%1$s</strong> has been banned":[null,"<strong>%1$s</strong> is verban"],"<strong>%1$s</strong> has been kicked out":[null,"<strong>%1$s</strong> is uitgeskop"],"<strong>%1$s</strong> has been removed because of an affiliation change":[null,"<strong>%1$s</strong> is verwyder a.g.v 'n verandering van affiliasie"],"<strong>%1$s</strong> has been removed for not being a member":[null,"<strong>%1$s</strong> is nie 'n lid nie, en dus verwyder"],"You have been banned from this room":[null,"Jy is uit die kamer verban"],"You have been kicked from this room":[null,"Jy is uit die kamer geskop"],"You have been removed from this room because of an affiliation change":[null,"Jy is vanuit die kamer verwyder a.g.v 'n verandering van affiliasie"],"You have been removed from this room because the room has changed to members-only and you're not a member":[null,"Jy is vanuit die kamer verwyder omdat die kamer nou slegs tot lede beperk word en jy nie 'n lid is nie."],"You have been removed from this room because the MUC (Multi-user chat) service is being shut down.":[null,"Jy is van hierdie kamer verwyder aangesien die MUC (Multi-user chat) diens nou afgeskakel word."],"You are not on the member list of this room":[null,"Jy is nie op die ledelys van hierdie kamer nie"],"No nickname was specified":[null,"Geen bynaam verskaf nie"],"You are not allowed to create new rooms":[null,"Jy word nie toegelaat om nog kamers te skep nie"],"Your nickname doesn't conform to this room's policies":[null,"Jou bynaam voldoen nie aan die kamer se beleid nie"],"Your nickname is already taken":[null,"Jou bynaam is reeds geneem"],"This room does not (yet) exist":[null,"Hierdie kamer bestaan tans (nog) nie"],"This room has reached it's maximum number of occupants":[null,"Hierdie kamer het sy maksimum aantal deelnemers bereik"],"Topic set by %1$s to: %2$s":[null,"Onderwerp deur %1$s bygewerk na: %2$s"],"This user is a moderator":[null,"Hierdie gebruiker is 'n moderator"],"This user can send messages in this room":[null,"Hierdie gebruiker kan boodskappe na die kamer stuur"],"This user can NOT send messages in this room":[null,"Hierdie gebruiker kan NIE boodskappe na die kamer stuur nie"],"Click to chat with this contact":[null,"Kliek om met hierdie kontak te klets"],"Click to remove this contact":[null,"Kliek om hierdie kontak te verwyder"],"This contact is busy":[null,"Hierdie persoon is besig"],"This contact is online":[null,"Hierdie persoon is aanlyn"],"This contact is offline":[null,"Hierdie persoon is aflyn"],"This contact is unavailable":[null,"Hierdie persoon is onbeskikbaar"],"This contact is away for an extended period":[null,"Hierdie persoon is vir lank afwesig"],"This contact is away":[null,"Hierdie persoon is afwesig"],"Contact requests":[null,"Kontak versoeke"],"My contacts":[null,"My kontakte"],"Pending contacts":[null,"Hangende kontakte"],"Custom status":[null,"Doelgemaakte status"],"Click to change your chat status":[null,"Kliek om jou klets-status te verander"],"Click here to write a custom status message":[null,"Kliek hier om jou eie statusboodskap te skryf"],online:[null,"aangemeld"],busy:[null,"besig"],"away for long":[null,"vir lank afwesig"],away:[null,"afwesig"],"I am %1$s":[null,"Ek is %1$s"],"Sign in":[null,"Teken in"],"XMPP/Jabber Username:":[null,"XMPP/Jabber Gebruikersnaam:"],"Password:":[null,"Wagwoord"],"Log In":[null,"Meld aan"],"BOSH Service URL:":[null,"BOSH bediener URL"],"Online Contacts":[null,"Kontakte aangemeld"],Connected:[null,"Verbind"],Attached:[null,"Geheg"]}}};typeof define=="function"&&define.amd?define("af",["jed"],function(){return t(new Jed(n))}):(window.locales||(window.locales={}),window.locales.af=t(new Jed(n)))}(this,function(e){return e}),function(e,t){var n={domain:"converse",locale_data:{converse:{"":{"Project-Id-Version":"Converse.js 0.4","Report-Msgid-Bugs-To":"","POT-Creation-Date":"2013-09-15 21:55+0200","PO-Revision-Date":"2013-09-15 22:03+0200","Last-Translator":"JC Brand <jc@opkode.com>","Language-Team":"German",Language:"de","MIME-Version":"1.0","Content-Type":"text/plain; charset=UTF-8","Content-Transfer-Encoding":"8bit","Plural-Forms":"nplurals=2; plural=(n != 1);",domain:"converse",lang:"de",plural_forms:"nplurals=2; plural=(n != 1);"},unencrypted:[null,""],unverified:[null,""],verified:[null,""],finished:[null,""],Disconnected:[null,"Verbindung unterbrochen."],Error:[null,"Fehler"],Connecting:[null,"Verbindungsaufbau …"],"Connection Failed":[null,"Entfernte Verbindung fehlgeschlagen"],Authenticating:[null,"Authentifizierung"],"Authentication Failed":[null,"Authentifizierung gescheitert"],Disconnecting:[null,"Trenne Verbindung"],"Re-establishing encrypted session":[null,""],"Your browser needs to generate a private key, which will be used in your encrypted chat session. This can take up to 30 seconds during which your browser might freeze and become unresponsive.":[null,""],"Private key generated.":[null,""],"Authentication request from %1$s\n\nYour buddy is attempting to verify your identity, by asking you the question below.\n\n%2$s":[null,""],"Could not verify this user's identify.":[null,""],"Personal message":[null,"Persönliche Nachricht"],"Start encrypted conversation":[null,""],"Refresh encrypted conversation":[null,""],"End encrypted conversation":[null,""],"Verify with SMP":[null,""],"Verify with fingerprints":[null,""],"What's this?":[null,""],me:[null,"Ich"],"Show this menu":[null,"Dieses Menü anzeigen"],"Write in the third person":[null,"In der dritten Person schreiben"],"Remove messages":[null,"Nachrichten entfernen"],"Your message could not be sent":[null,""],"We received an unencrypted message":[null,""],"We received an unreadable encrypted message":[null,""],"This user has requested an encrypted session.":[null,""],"Here are the fingerprints, please confirm them with %1$s, outside of this chat.\n\nFingerprint for you, %2$s: %3$s\n\nFingerprint for %1$s: %4$s\n\nIf you have confirmed that the fingerprints match, click OK, otherwise click Cancel.":[null,""],"You will be prompted to provide a security question and then an answer to that question.\n\nYour buddy will then be prompted the same question and if they type the exact same answer (case sensitive), their identity will have been verified.":[null,""],"What is your security question?":[null,""],"What is the answer to the security question?":[null,""],"Invalid authentication scheme provided":[null,""],"Your messages are not encrypted anymore":[null,""],"Your messages are now encrypted but your buddy's identity has not been verified.":[null,""],"Your buddy's identify has been verified.":[null,""],"Your buddy has ended encryption on their end, you should do the same.":[null,""],"Your messages are not encrypted. Click here to enable OTR encryption.":[null,""],"Your messages are encrypted, but your buddy has not been verified.":[null,""],"Your messages are encrypted and your buddy verified.":[null,""],"Your buddy has closed their end of the private session, you should do the same":[null,""],Contacts:[null,"Kontakte"],Online:[null,"Online"],Busy:[null,"Beschäfticht"],Away:[null,"Abwesend"],Offline:[null,"Abgemeldet"],"Click to add new chat contacts":[null,"Klicken Sie, um einen neuen Kontakt hinzuzufügen"],"Add a contact":[null,"Kontakte hinzufügen"],"Contact username":[null,"Benutzername"],Add:[null,"Hinzufügen"],"Contact name":[null,"Name des Kontakts"],Search:[null,"Suche"],"No users found":[null,"Keine Benutzer gefunden"],"Click to add as a chat contact":[null,"Hier klicken um als Kontakt hinzuzufügen"],"Click to open this room":[null,"Hier klicken um diesen Raum zu öffnen"],"Show more information on this room":[null,"Mehr Information über diesen Raum zeigen"],"Description:":[null,"Beschreibung"],"Occupants:":[null,"Teilnehmer"],"Features:":[null,"Funktionen:"],"Requires authentication":[null,"Authentifizierung erforderlich"],Hidden:[null,"Versteckt"],"Requires an invitation":[null,"Einladung erforderlich"],Moderated:[null,"Moderiert"],"Non-anonymous":[null,"Nicht anonym"],"Open room":[null,"Offener Raum"],"Permanent room":[null,"Dauerhafter Raum"],Public:[null,"Öffentlich"],"Semi-anonymous":[null,"Teils anonym"],"Temporary room":[null,"Vorübergehender Raum"],Unmoderated:[null,"Unmoderiert"],Rooms:[null,"Räume"],"Room name":[null,"Raumname"],Nickname:[null,"Spitzname"],Server:[null,"Server"],Join:[null,"Beitreten"],"Show rooms":[null,"Räume anzeigen"],"No rooms on %1$s":[null,"Keine Räume auf %1$s"],"Rooms on %1$s":[null,"Räume auf %1$s"],"Set chatroom topic":[null,"Chatraum Thema festlegen"],"Kick user from chatroom":[null,"Werfe einen Benutzer aus dem Raum."],"Ban user from chatroom":[null,"Verbanne einen Benutzer aus dem Raum."],Message:[null,"Nachricht"],Save:[null,"Speichern"],Cancel:[null,"Abbrechen"],"An error occurred while trying to save the form.":[null,"Beim Speichern der Formular is ein Fehler aufgetreten."],"This chatroom requires a password":[null,"Passwort wird für die Anmeldung benötigt."],"Password: ":[null,"Passwort: "],Submit:[null,"Einreichen"],"This room is not anonymous":[null,"Dieser Raum ist nicht anonym"],"This room now shows unavailable members":[null,"Dieser Raum zeigt jetzt unferfügbare Mitglieder"],"This room does not show unavailable members":[null,"Dieser Raum zeigt nicht unverfügbare Mitglieder"],"Non-privacy-related room configuration has changed":[null,"Die Konfiguration, die nicht auf die Privatsphäre bezogen ist, hat sich geändert"],"Room logging is now enabled":[null,"Zukünftige Nachrichten dieses Raums werden protokolliert."],"Room logging is now disabled":[null,"Zukünftige Nachrichten dieses Raums werden nicht protokolliert."],"This room is now non-anonymous":[null,"Dieser Raum ist jetzt nicht anonym"],"This room is now semi-anonymous":[null,"Dieser Raum ist jetzt teils anonym"],"This room is now fully-anonymous":[null,"Dieser Raum ist jetzt anonym"],"A new room has been created":[null,"Einen neuen Raum ist erstellen"],"Your nickname has been changed":[null,"Spitzname festgelegen"],"<strong>%1$s</strong> has been banned":[null,"<strong>%1$s</strong> ist verbannt"],"<strong>%1$s</strong> has been kicked out":[null,"<strong>%1$s</strong> ist hinausgeworfen"],"<strong>%1$s</strong> has been removed because of an affiliation change":[null,"<strong>%1$s</strong> wurde wegen einer Zugehörigkeitsänderung entfernt"],"<strong>%1$s</strong> has been removed for not being a member":[null,"<strong>%1$s</strong> ist kein Mitglied und wurde daher entfernt"],"You have been banned from this room":[null,"Sie sind aus diesem Raum verbannt worden"],"You have been kicked from this room":[null,"Sie wurden aus diesem Raum hinausgeworfen"],"You have been removed from this room because of an affiliation change":[null,"Sie wurden wegen einer Zugehörigkeitsänderung entfernt"],"You have been removed from this room because the room has changed to members-only and you're not a member":[null,"Sie wurden aus diesem Raum entfernt da Sie kein Mitglied sind."],"You have been removed from this room because the MUC (Multi-user chat) service is being shut down.":[null,"Sie werden aus diesem Raum entfernt da der MUC (Muli-user chat) Dienst gerade abgeschalten wird."],"You are not on the member list of this room":[null,"Sie sind nicht auf der Mitgliederliste dieses Raums"],"No nickname was specified":[null,"Kein Spitzname festgelegt"],"You are not allowed to create new rooms":[null,"Es ist Ihnen nicht erlaubt, neue Räume anzulegen"],"Your nickname doesn't conform to this room's policies":[null,"Ungültiger Spitzname"],"Your nickname is already taken":[null,"Ihre Spitzname existiert bereits."],"This room does not (yet) exist":[null,"Dieser Raum existiert (noch) nicht"],"This room has reached it's maximum number of occupants":[null,"Dieser Raum hat die maximale Mitgliederanzahl erreicht"],"Topic set by %1$s to: %2$s":[null,'%1$s hat das Thema zu "%2$s" abgeändert'],"This user is a moderator":[null,"Dieser Benutzer ist ein Moderator"],"This user can send messages in this room":[null,"Dieser Benutzer kann Nachrichten in diesem Raum verschicken"],"This user can NOT send messages in this room":[null,"Dieser Benutzer kann keine Nachrichten in diesem Raum verschicken"],"Click to chat with this contact":[null,"Hier klicken um mit diesem Kontakt zu chatten"],"Click to remove this contact":[null,"Hier klicken um diesen Kontakt zu entfernen"],"This contact is busy":[null,"Dieser Kontakt ist beschäfticht"],"This contact is online":[null,"Dieser Kontakt ist online"],"This contact is offline":[null,"Dieser Kontakt ist offline"],"This contact is unavailable":[null,"Dieser Kontakt ist nicht verfügbar"],"This contact is away for an extended period":[null,"Dieser Kontakt is für längere Zeit abwesend"],"This contact is away":[null,"Dieser Kontakt ist abwesend"],"Contact requests":[null,"Kontaktanfragen"],"My contacts":[null,"Meine Kontakte"],"Pending contacts":[null,"Unbestätigte Kontakte"],"Custom status":[null,"Status-Nachricht"],"Click to change your chat status":[null,"Klicken Sie, um ihrer Status to ändern"],"Click here to write a custom status message":[null,"Klicken Sie hier, um ihrer Status-Nachricht to ändern"],online:[null,"online"],busy:[null,"beschäfticht"],"away for long":[null,"länger abwesend"],away:[null,"abwesend"],"I am %1$s":[null,"Ich bin %1$s"],"Sign in":[null,"Anmelden"],"XMPP/Jabber Username:":[null,"XMPP/Jabber Benutzername"],"Password:":[null,"Passwort:"],"Log In":[null,"Anmelden"],"BOSH Service URL:":[null,"BOSH "],"Online Contacts":[null,"Online-Kontakte"],"%1$s is typing":[null,"%1$s tippt"],Connected:[null,"Verbunden"],Attached:[null,"Angehängt"]}}};typeof define=="function"&&define.amd?define("de",["jed"],function(){return t(new Jed(n))}):(window.locales||(window.locales={}),window.locales.de=t(new Jed(n)))}(this,function(e){return e}),function(e,t){var n={domain:"converse",locale_data:{converse:{"":{domain:"converse",lang:"en",plural_forms:"nplurals=2; plural=(n != 1);"}}}};typeof define=="function"&&define.amd?define("en",["jed"],function(){return t(new Jed(n))}):(window.locales||(window.locales={}),window.locales.en=t(new Jed(n)))}(this,function(e){return e}),function(e,t){var n={domain:"converse",locale_data:{converse:{"":{"Project-Id-Version":"Converse.js 0.4","Report-Msgid-Bugs-To":"","POT-Creation-Date":"2013-09-15 21:55+0200","PO-Revision-Date":"2013-09-15 21:59+0200","Last-Translator":"Leonardo J. Caballero G. <leonardocaballero@gmail.com>","Language-Team":"ES <LL@li.org>",Language:"es","MIME-Version":"1.0","Content-Type":"text/plain; charset=UTF-8","Content-Transfer-Encoding":"8bit","Plural-Forms":"nplurals=2; plural=(n != 1);",plural_forms:"nplurals=2; plural=(n != 1);",lang:"es","Language-Code":"es","Language-Name":"Español","Preferred-Encodings":"utf-8 latin1",Domain:"converse",domain:"converse","X-Is-Fallback-For":"es-ar es-bo es-cl es-co es-cr es-do es-ec es-es es-sv es-gt es-hn es-mx es-ni es-pa es-py es-pe es-pr es-us es-uy es-ve"},unencrypted:[null,""],unverified:[null,""],verified:[null,""],finished:[null,""],Disconnected:[null,"Desconectado"],Error:[null,"Error"],Connecting:[null,"Conectando"],"Connection Failed":[null,"Conexión fallo"],Authenticating:[null,"Autenticando"],"Authentication Failed":[null,"Autenticación fallo"],Disconnecting:[null,"Desconectando"],"Re-establishing encrypted session":[null,""],"Your browser needs to generate a private key, which will be used in your encrypted chat session. This can take up to 30 seconds during which your browser might freeze and become unresponsive.":[null,""],"Private key generated.":[null,""],"Authentication request from %1$s\n\nYour buddy is attempting to verify your identity, by asking you the question below.\n\n%2$s":[null,""],"Could not verify this user's identify.":[null,""],"Personal message":[null,"Mensaje personal"],"Start encrypted conversation":[null,""],"Refresh encrypted conversation":[null,""],"End encrypted conversation":[null,""],"Verify with SMP":[null,""],"Verify with fingerprints":[null,""],"What's this?":[null,""],me:[null,""],"Show this menu":[null,"Mostrar este menú"],"Write in the third person":[null,"Escribir en tercera persona"],"Remove messages":[null,"Eliminar mensajes"],"Your message could not be sent":[null,""],"We received an unencrypted message":[null,""],"We received an unreadable encrypted message":[null,""],"This user has requested an encrypted session.":[null,""],"Here are the fingerprints, please confirm them with %1$s, outside of this chat.\n\nFingerprint for you, %2$s: %3$s\n\nFingerprint for %1$s: %4$s\n\nIf you have confirmed that the fingerprints match, click OK, otherwise click Cancel.":[null,""],"You will be prompted to provide a security question and then an answer to that question.\n\nYour buddy will then be prompted the same question and if they type the exact same answer (case sensitive), their identity will have been verified.":[null,""],"What is your security question?":[null,""],"What is the answer to the security question?":[null,""],"Invalid authentication scheme provided":[null,""],"Your messages are not encrypted anymore":[null,""],"Your messages are now encrypted but your buddy's identity has not been verified.":[null,""],"Your buddy's identify has been verified.":[null,""],"Your buddy has ended encryption on their end, you should do the same.":[null,""],"Your messages are not encrypted. Click here to enable OTR encryption.":[null,""],"Your messages are encrypted, but your buddy has not been verified.":[null,""],"Your messages are encrypted and your buddy verified.":[null,""],"Your buddy has closed their end of the private session, you should do the same":[null,""],Contacts:[null,"Contactos"],Online:[null,"En linea"],Busy:[null,"Ocupado"],Away:[null,"Ausente"],Offline:[null,"Desconectado"],"Click to add new chat contacts":[null,"Haga clic para agregar nuevos contactos al chat"],"Add a contact":[null,"Agregar un contacto"],"Contact username":[null,"Nombre de usuario de contacto"],Add:[null,"Agregar"],"Contact name":[null,"Nombre de contacto"],Search:[null,"Búsqueda"],"No users found":[null,"Sin usuarios encontrados"],"Click to add as a chat contact":[null,"Haga clic para agregar como un contacto de chat"],"Click to open this room":[null,"Haga clic para abrir esta sala"],"Show more information on this room":[null,"Mostrar mas información en esta sala"],"Description:":[null,"Descripción"],"Occupants:":[null,"Ocupantes:"],"Features:":[null,"Características:"],"Requires authentication":[null,"Autenticación requerida"],Hidden:[null,"Oculto"],"Requires an invitation":[null,"Requiere una invitación"],Moderated:[null,"Moderado"],"Non-anonymous":[null,"No usuario anónimo"],"Open room":[null,"Abrir sala"],"Permanent room":[null,"Sala permanente"],Public:[null,"Publico"],"Semi-anonymous":[null,"Semi anónimo"],"Temporary room":[null,"Sala temporal"],Unmoderated:[null,"Sin moderar"],Rooms:[null,"Salas"],"Room name":[null,"Nombre de sala"],Nickname:[null,"Apodo"],Server:[null,"Servidor"],Join:[null,"Unirse"],"Show rooms":[null,"Mostrar salas"],"No rooms on %1$s":[null,"Sin salas en %1$s"],"Rooms on %1$s":[null,"Salas en %1$s"],"Set chatroom topic":[null,"Defina tema de sala de chat"],"Kick user from chatroom":[null,"Expulsar usuario de sala de chat."],"Ban user from chatroom":[null,"Prohibir usuario de sala de chat."],Message:[null,"Mensaje"],Save:[null,"Guardar"],Cancel:[null,"Cancelar"],"An error occurred while trying to save the form.":[null,"Un error ocurrido mientras trataba de guardar el formulario."],"This chatroom requires a password":[null,"Esta sala de chat requiere una contraseña."],"Password: ":[null,"Contraseña: "],Submit:[null,"Enviar"],"This room is not anonymous":[null,"Esta sala no es para usuarios anónimos"],"This room now shows unavailable members":[null,"Esta sala ahora muestra los miembros no disponibles"],"This room does not show unavailable members":[null,"Esta sala no muestra los miembros no disponibles"],"Non-privacy-related room configuration has changed":[null,"Configuración de la sala para no relacionada con la privacidad ha sido cambiada"],"Room logging is now enabled":[null,"El registro de la sala ahora está habilitada"],"Room logging is now disabled":[null,"El registro de la sala ahora está deshabilitada"],"This room is now non-anonymous":[null,"Esta sala ahora es para los usuarios no anónimos"],"This room is now semi-anonymous":[null,"Esta sala ahora es para los usuarios semi-anónimos"],"This room is now fully-anonymous":[null,"Esta sala ahora es para los usuarios completamente-anónimos"],"A new room has been created":[null,"Una nueva sala ha sido creada"],"Your nickname has been changed":[null,"Su apodo ha sido cambiado"],"<strong>%1$s</strong> has been banned":[null,"<strong>%1$s</strong> ha sido prohibido"],"<strong>%1$s</strong> has been kicked out":[null,"<strong>%1$s</strong> ha sido expulsado"],"<strong>%1$s</strong> has been removed because of an affiliation change":[null,"<strong>%1$s</strong> ha sido eliminado debido a un cambio de afiliación"],"<strong>%1$s</strong> has been removed for not being a member":[null,"<strong>%1$s</strong> ha sido eliminado debido a que no es miembro"],"You have been banned from this room":[null,"Usted ha sido prohibido de esta sala"],"You have been kicked from this room":[null,"Usted ha sido expulsado de esta sala"],"You have been removed from this room because of an affiliation change":[null,"Usted ha sido eliminado de esta sala debido a un cambio de afiliación"],"You have been removed from this room because the room has changed to members-only and you're not a member":[null,"Usted ha sido eliminado de esta sala debido a que la sala cambio su configuración a solo-miembros y usted no es un miembro"],"You have been removed from this room because the MUC (Multi-user chat) service is being shut down.":[null,"Usted ha sido eliminado de esta sala debido al servicio MUC (Multi-user chat) está apagado."],"You are not on the member list of this room":[null,"Usted no está en la lista de miembros de esta sala"],"No nickname was specified":[null,"Sin apodo especificado"],"You are not allowed to create new rooms":[null,"A usted no se le permite crear nuevas salas"],"Your nickname doesn't conform to this room's policies":[null,"Su apodo no se ajusta a la política de esta sala"],"Your nickname is already taken":[null,"Su apodo ya ha sido tomando por otro usuario"],"This room does not (yet) exist":[null,"Esta sala (aún) no existe"],"This room has reached it's maximum number of occupants":[null,"Esta sala ha alcanzado su número máximo de ocupantes"],"Topic set by %1$s to: %2$s":[null,"Tema fijado por %1$s a: %2$s"],"This user is a moderator":[null,"Este usuario es un moderador"],"This user can send messages in this room":[null,"Este usuario puede enviar mensajes en esta sala"],"This user can NOT send messages in this room":[null,"Este usuario NO puede enviar mensajes en esta"],"Click to chat with this contact":[null,"Haga clic para conversar con este contacto"],"Click to remove this contact":[null,"Haga clic para eliminar este contacto"],"This contact is busy":[null,""],"This contact is online":[null,""],"This contact is offline":[null,""],"This contact is unavailable":[null,"Esta sala ahora muestra los miembros no disponibles"],"This contact is away for an extended period":[null,""],"This contact is away":[null,""],"Contact requests":[null,"Solicitudes de contacto"],"My contacts":[null,"Mi contactos"],"Pending contacts":[null,"Contactos pendientes"],"Custom status":[null,"Personalice estatus"],"Click to change your chat status":[null,"Haga clic para cambiar su estatus de chat"],"Click here to write a custom status message":[null,"Haga clic para escribir un mensaje de estatus personalizado"],online:[null,"en linea"],busy:[null,"ocupado"],"away for long":[null,"lejos por mucho tiempo"],away:[null,"ausente"],"I am %1$s":[null,"Yo soy %1$s"],"Sign in":[null,"Registro"],"XMPP/Jabber Username:":[null,"Nombre de usuario XMPP/Jabber"],"Password:":[null,"Contraseña:"],"Log In":[null,"Iniciar sesión"],"BOSH Service URL:":[null,"URL del servicio BOSH:"],"Online Contacts":[null,"Contactos en linea"],Connected:[null,"Conectado"],Attached:[null,"Adjuntado"]}}};typeof define=="function"&&define.amd?define("es",["jed"],function(){return t(new Jed(n))}):(window.locales||(window.locales={}),window.locales.es=t(new Jed(n)))}(this,function(e){return e}),function(e,t){var n={domain:"converse",locale_data:{converse:{"":{"Project-Id-Version":"Converse.js 0.4","Report-Msgid-Bugs-To":"","POT-Creation-Date":"2013-09-15 21:55+0200","PO-Revision-Date":"2013-09-15 21:58+0200","Language-Team":"FR <LL@li.org>",Language:"fr","MIME-Version":"1.0","Content-Type":"text/plain; charset=UTF-8","Content-Transfer-Encoding":"8bit","Plural-Forms":"nplurals=2; plural=(n != 1);",plural_forms:"nplurals=2; plural=(n != 1);",lang:"fr","Language-Code":"fr","Preferred-Encodings":"utf-8 latin1",Domain:"converse",domain:"converse"},unencrypted:[null,""],unverified:[null,""],verified:[null,""],finished:[null,""],Disconnected:[null,"Déconnecté"],Error:[null,"Erreur"],Connecting:[null,"Connection"],"Connection Failed":[null,"La connection a échoué"],Authenticating:[null,"Authentification"],"Authentication Failed":[null,"L'authentification a échoué"],Disconnecting:[null,"Déconnection"],"Re-establishing encrypted session":[null,""],"Your browser needs to generate a private key, which will be used in your encrypted chat session. This can take up to 30 seconds during which your browser might freeze and become unresponsive.":[null,""],"Private key generated.":[null,""],"Authentication request from %1$s\n\nYour buddy is attempting to verify your identity, by asking you the question below.\n\n%2$s":[null,""],"Could not verify this user's identify.":[null,""],"Personal message":[null,"Message personnel"],"Start encrypted conversation":[null,""],"Refresh encrypted conversation":[null,""],"End encrypted conversation":[null,""],"Verify with SMP":[null,""],"Verify with fingerprints":[null,""],"What's this?":[null,""],me:[null,""],"Show this menu":[null,"Afficher ce menu"],"Write in the third person":[null,"Écrire à la troisième personne"],"Remove messages":[null,"Effacer les messages"],"Your message could not be sent":[null,""],"We received an unencrypted message":[null,""],"We received an unreadable encrypted message":[null,""],"This user has requested an encrypted session.":[null,""],"Here are the fingerprints, please confirm them with %1$s, outside of this chat.\n\nFingerprint for you, %2$s: %3$s\n\nFingerprint for %1$s: %4$s\n\nIf you have confirmed that the fingerprints match, click OK, otherwise click Cancel.":[null,""],"You will be prompted to provide a security question and then an answer to that question.\n\nYour buddy will then be prompted the same question and if they type the exact same answer (case sensitive), their identity will have been verified.":[null,""],"What is your security question?":[null,""],"What is the answer to the security question?":[null,""],"Invalid authentication scheme provided":[null,""],"Your messages are not encrypted anymore":[null,""],"Your messages are now encrypted but your buddy's identity has not been verified.":[null,""],"Your buddy's identify has been verified.":[null,""],"Your buddy has ended encryption on their end, you should do the same.":[null,""],"Your messages are not encrypted. Click here to enable OTR encryption.":[null,""],"Your messages are encrypted, but your buddy has not been verified.":[null,""],"Your messages are encrypted and your buddy verified.":[null,""],"Your buddy has closed their end of the private session, you should do the same":[null,""],Contacts:[null,"Contacts"],Online:[null,"En ligne"],Busy:[null,"Occupé"],Away:[null,"Absent"],Offline:[null,"Déconnecté"],"Click to add new chat contacts":[null,"Cliquez pour ajouter de nouveaux contacts"],"Add a contact":[null,"Ajouter un contact"],"Contact username":[null,"Nom du contact"],Add:[null,"Ajouter"],"Contact name":[null,"Nom du contact"],Search:[null,"Rechercher"],"No users found":[null,"Aucun utilisateur trouvé"],"Click to add as a chat contact":[null,"Cliquer pour ajouter aux contacts de chat"],"Click to open this room":[null,"Cliquer pour ouvrir ce salon"],"Show more information on this room":[null,"Afficher davantage d'informations sur ce salon"],"Description:":[null,"Description :"],"Occupants:":[null,"Participants :"],"Features:":[null,"Caractéristiques :"],"Requires authentication":[null,"Nécessite une authentification"],Hidden:[null,"Masqué"],"Requires an invitation":[null,"Nécessite une invitation"],Moderated:[null,"Modéré"],"Non-anonymous":[null,"Non-anonyme"],"Open room":[null,"Ouvrir un salon"],"Permanent room":[null,"Salon permanent"],Public:[null,"Public"],"Semi-anonymous":[null,"Semi-anonyme"],"Temporary room":[null,"Salon temporaire"],Unmoderated:[null,"Non modéré"],Rooms:[null,"Salons"],"Room name":[null,"Numéro de salon"],Nickname:[null,"Alias"],Server:[null,"Serveur"],Join:[null,"Rejoindre"],"Show rooms":[null,"Afficher les salons"],"No rooms on %1$s":[null,"Aucun salon dans %1$s"],"Rooms on %1$s":[null,"Salons dans %1$s"],"Set chatroom topic":[null,"Indiquer le sujet du salon"],"Kick user from chatroom":[null,"Expulser l'utilisateur du salon."],"Ban user from chatroom":[null,"Bannir l'utilisateur du salon."],Message:[null,"Message"],Save:[null,"Enregistrer"],Cancel:[null,"Annuler"],"An error occurred while trying to save the form.":[null,"Une erreur est survenue lors de l'enregistrement du formulaire."],"This chatroom requires a password":[null,"Ce salon nécessite un mot de passe."],"Password: ":[null,"Mot de passe : "],Submit:[null,"Soumettre"],"This room is not anonymous":[null,"Ce salon n'est pas anonyme"],"This room now shows unavailable members":[null,"Ce salon affiche maintenant des membres indisponibles"],"This room does not show unavailable members":[null,"Ce salon n'affiche pas les membres indisponibles"],"Non-privacy-related room configuration has changed":[null,"Les paramètres du salon non liés à la confidentialité ont été modifiés"],"Room logging is now enabled":[null,"Le logging du salon est activé"],"Room logging is now disabled":[null,"Le logging du salon est désactivé"],"This room is now non-anonymous":[null,"Ce salon est maintenant non-anonyme"],"This room is now semi-anonymous":[null,"Ce salon est maintenant semi-anonyme"],"This room is now fully-anonymous":[null,"Ce salon est maintenant entièrement anonyme"],"A new room has been created":[null,"Un nouveau salon a été créé"],"Your nickname has been changed":[null,"Votre alias a été modifié"],"<strong>%1$s</strong> has been banned":[null,"<strong>%1$s</strong> a été banni"],"<strong>%1$s</strong> has been kicked out":[null,"<strong>%1$s</strong> a été expulsé"],"<strong>%1$s</strong> has been removed because of an affiliation change":[null,"<strong>%1$s</strong> a été supprimé à cause d'un changement d'affiliation"],"<strong>%1$s</strong> has been removed for not being a member":[null,"<strong>%1$s</strong> a été supprimé car il n'est pas membre"],"You have been banned from this room":[null,"Vous avez été banni de ce salon"],"You have been kicked from this room":[null,"Vous avez été expulsé de ce salon"],"You have been removed from this room because of an affiliation change":[null,"Vous avez été retiré de ce salon du fait d'un changement d'affiliation"],"You have been removed from this room because the room has changed to members-only and you're not a member":[null,"Vous avez été retiré de ce salon parce que ce salon est devenu réservé aux membres et vous n'êtes pas membre"],"You have been removed from this room because the MUC (Multi-user chat) service is being shut down.":[null,"Vous avez été retiré de ce salon parce que le service de chat multi-utilisateur a été désactivé."],"You are not on the member list of this room":[null,"Vous n'êtes pas dans la liste des membres de ce salon"],"No nickname was specified":[null,"Aucun alias n'a été indiqué"],"You are not allowed to create new rooms":[null,"Vous n'êtes pas autorisé à créer des salons"],"Your nickname doesn't conform to this room's policies":[null,"Votre alias n'est pas conforme à la politique de ce salon"],"Your nickname is already taken":[null,"Votre alias est déjà utilisé"],"This room does not (yet) exist":[null,"Ce salon n'existe pas encore"],"This room has reached it's maximum number of occupants":[null,"Ce salon a atteint la limite maximale d'occupants"],"Topic set by %1$s to: %2$s":[null,"Le sujet '%1$s' a été défini par %2$s"],"This user is a moderator":[null,"Cet utilisateur est modérateur"],"This user can send messages in this room":[null,"Cet utilisateur peut envoyer des messages dans ce salon"],"This user can NOT send messages in this room":[null,"Cet utilisateur ne peut PAS envoyer de messages dans ce salon"],"Click to chat with this contact":[null,"Cliquez pour discuter avec ce contact"],"Click to remove this contact":[null,"Cliquez pour supprimer ce contact"],"This contact is busy":[null,""],"This contact is online":[null,""],"This contact is offline":[null,""],"This contact is unavailable":[null,"Ce salon affiche maintenant des membres indisponibles"],"This contact is away for an extended period":[null,""],"This contact is away":[null,""],"Contact requests":[null,"Demandes de contacts"],"My contacts":[null,"Mes contacts"],"Pending contacts":[null,"Contacts en attente"],"Custom status":[null,"Statut personnel"],"Click to change your chat status":[null,"Cliquez pour changer votre statut"],"Click here to write a custom status message":[null,"Cliquez ici pour indiquer votre statut personnel"],online:[null,"en ligne"],busy:[null,"occupé"],"away for long":[null,"absent pour une longue durée"],away:[null,"absent"],"I am %1$s":[null,"Je suis %1$s"],"Sign in":[null,"S'inscrire"],"XMPP/Jabber Username:":[null,"Nom d'utilisateur XMPP/Jabber"],"Password:":[null,"Mot de passe :"],"Log In":[null,"Se connecter"],"BOSH Service URL:":[null,"URL du service BOSH:"],"Online Contacts":[null,"Contacts en ligne"],Connected:[null,"Connecté"],Attached:[null,"Attaché"]}}};typeof define=="function"&&define.amd?define("fr",["jed"],function(){return t(new Jed(n))}):(window.locales||(window.locales={}),window.locales.fr=t(new Jed(n)))}(this,function(e){return e}),function(e,t){var n={domain:"converse",locale_data:{converse:{"":{"Project-Id-Version":"Converse.js 0.7.0","Report-Msgid-Bugs-To":"","POT-Creation-Date":"2014-01-28 03:50+0200","PO-Revision-Date":"2014-02-21 06:07+0200","Last-Translator":"GreenLunar <GreenLunar@github.com>","Language-Team":"Rahut <http://sourceforge.net/projects/rahut/>",Language:"he","MIME-Version":"1.0","Content-Type":"text/plain; charset=UTF-8","Content-Transfer-Encoding":"8bit","X-Generator":"Poedit 1.5.1"},unencrypted:[null,"לא מוצפנת"],unverified:[null,"לא מאומתת"],verified:[null,"מאומתת"],finished:[null,"מוגמרת"],"This contact is busy":[null,"איש קשר זה עסוק"],"This contact is online":[null,"איש קשר זה מקוון"],"This contact is offline":[null,"איש קשר זה לא מקוון"],"This contact is unavailable":[null,"איש קשר זה לא זמין"],"This contact is away for an extended period":[null,"איש קשר זה נעדר למשך זמן ממושך"],"This contact is away":[null,"איש קשר זה הינו נעדר"],Disconnected:[null,"מנותק"],Error:[null,"שגיאה"],Connecting:[null,"כעת מתחבר"],"Connection Failed":[null,"חיבור נכשל"],Authenticating:[null,"כעת מאמת"],"Authentication Failed":[null,"אימות נכשל"],Disconnecting:[null,"כעת מתנתק"],"Online Contacts":[null,"אנשי קשר מקוונים"],"Re-establishing encrypted session":[null,"בסס מחדש ישיבה מוצפנת"],"Your browser needs to generate a private key, which will be used in your encrypted chat session. This can take up to 30 seconds during which your browser might freeze and become unresponsive.":[null,"על הדפדפן שלך להפיק מפתח פרטי, אשר ישמש אותך בישיבות שיחה מוצפנות. פעולה זו יכולה לקחת למעלה מן 30 שניות אשר במהלכה הדפדפן שלך עשוי לקפוא ולהפוך לחסר תגובה."],"Private key generated.":[null,"מפתח פרטי הופק."],"Authentication request from %1$s\n\nYour buddy is attempting to verify your identity, by asking you the question below.\n\n%2$s":[null,"בקשת אימות מאת %1$s\n\nהאישיות שכנגד מנסה לאמת את הזהות שלך, בעזרת שאילת שאלה להלן.\n\n%2$s"],"Could not verify this user's identify.":[null,"לא היתה אפשרות לאמת את זהות משתמש זה."],"Personal message":[null,"הודעה אישית"],"Start encrypted conversation":[null,"התחל ישיבה מוצפנת"],"Refresh encrypted conversation":[null,"רענן ישיבה מוצפנת"],"End encrypted conversation":[null,"סיים ישיבה מוצפנת"],"Verify with SMP":[null,"אמת בעזרת SMP"],"Verify with fingerprints":[null,"אמת בעזרת טביעות אצבע"],"What's this?":[null,"מה זה?"],me:[null,"אני"],"Show this menu":[null,"הצג את תפריט זה"],"Write in the third person":[null,"כתוב בגוף השלישי"],"Remove messages":[null,"הסר הודעות"],"Your message could not be sent":[null,"ההודעה שלך לא היתה יכולה להישלח"],"We received an unencrypted message":[null,"אנחנו קיבלנו הודעה לא מוצפנת"],"We received an unreadable encrypted message":[null,"אנחנו קיבלנו הודעה מוצפנת לא קריאה"],"This user has requested an encrypted session.":[null,"משתמש זה ביקש ישיבה מוצפנת."],"Here are the fingerprints, please confirm them with %1$s, outside of this chat.\n\nFingerprint for you, %2$s: %3$s\n\nFingerprint for %1$s: %4$s\n\nIf you have confirmed that the fingerprints match, click OK, otherwise click Cancel.":[null,"הרי טביעות האצבע, אנא אמת אותן עם %1$s, מחוץ לשיחה זו.\n\nטביעת אצבע עבורך, %2$s: %3$s\n\nטביעת אצבע עבור %1$s: %4$s\n\nהיה ואימתת כי טביעות האצבע תואמות, לחץ אישור (OK), אחרת לחץ ביטול (Cancel)."],"You will be prompted to provide a security question and then an answer to that question.\n\nYour buddy will then be prompted the same question and if they type the exact same answer (case sensitive), their identity will be verified.":[null,"אתה תתבקש לספק שאלת אבטחה ולאחריה תשובה לשאלה הזו.\n\nהאישיות שכנגד תתבקש עובר זאת לאותה שאלת אבטחה ואם זו תקלידו את את אותה התשובה במדויק (case sensitive), זהותה תאומת."],"What is your security question?":[null,"מהי שאלת האבטחה שלך?"],"What is the answer to the security question?":[null,"מהי התשובה לשאלת האבטחה?"],"Invalid authentication scheme provided":[null,"סופקה סכימת אימות שגויה"],"Your messages are not encrypted anymore":[null,"ההודעות שלך אינן מוצפנות עוד"],"Your messages are now encrypted but your buddy's identity has not been verified.":[null,"ההודעות שלך מוצפנות כעת אך זהות האישיות שכנגד טרם אומתה."],"Your buddy's identify has been verified.":[null,"זהות האישיות שכנגד אומתה."],"Your buddy has ended encryption on their end, you should do the same.":[null,"האישיות שכנגד סיימה הצפנה בקצה שלה, עליך לעשות את אותו הדבר."],"Your messages are not encrypted. Click here to enable OTR encryption.":[null,"ההודעות שלך אינן וצפנות. לחץ כאן כדי לאפשר OTR."],"Your messages are encrypted, but your buddy has not been verified.":[null,"ההודעות שלך מוצפנות כעת, אך האישיות שכנגד טרם אומתה."],"Your messages are encrypted and your buddy verified.":[null,"ההודעות שלך מוצפנות כעת והאישיות שכנגד אומתה."],"Your buddy has closed their end of the private session, you should do the same":[null,"האישיות שכנגד סגרה את קצה הישיבה הפרטית שלה, עליך לעשות את אותו הדבר."],Contacts:[null,"אנשי קשר"],Online:[null,"מקוון"],Busy:[null,"עסוק"],Away:[null,"נעדר"],Offline:[null,"בלתי מקוון"],"Click to add new chat contacts":[null,"לחץ כדי להוסיף אנשי קשר שיחה חדשים"],"Add a contact":[null,"הוסף איש קשר"],"Contact username":[null,"שם משתמש איש קשר"],Add:[null,"הוסף"],"Contact name":[null,"שם איש קשר"],Search:[null,"חיפוש"],"No users found":[null,"לא נמצאו משתמשים"],"Click to add as a chat contact":[null,"לחץ כדי להוסיף בתור איש קשר שיחה"],"Click to open this room":[null,"לחץ כדי לפתוח את חדר זה"],"Show more information on this room":[null,"הצג עוד מידע אודות חדר זה"],"Description:":[null,"תיאור:"],"Occupants:":[null,"נוכחים:"],"Features:":[null,"תכונות:"],"Requires authentication":[null,"מצריך אישור"],Hidden:[null,"נסתר"],"Requires an invitation":[null,"מצריך הזמנה"],Moderated:[null,"מבוקר"],"Non-anonymous":[null,"לא אנונימי"],"Open room":[null,"חדר פתוח"],"Permanent room":[null,"חדר צמיתה"],Public:[null,"פומבי"],"Semi-anonymous":[null,"אנונימי למחצה"],"Temporary room":[null,"חדר זמני"],Unmoderated:[null,"לא מבוקר"],Rooms:[null,"חדרים"],"Room name":[null,"שם חדר"],Nickname:[null,"שם כינוי"],Server:[null,"שרת"],Join:[null,"הצטרף"],"Show rooms":[null,"הצג חדרים"],"No rooms on %1$s":[null,"אין חדרים על %1$s"],"Rooms on %1$s":[null,"חדרים על %1$s"],"Set chatroom topic":[null,"קבע נושא חדר שיחה"],"Kick user from chatroom":[null,"בעט משתמש מתוך חדר שיחה"],"Ban user from chatroom":[null,"אסור משתמש מתוך חדר שיחה"],Message:[null,"הודעה"],Save:[null,"שמור"],Cancel:[null,"ביטול"],"An error occurred while trying to save the form.":[null,"אירעה שגיאה במהלך ניסיון שמירת הטופס."],"This chatroom requires a password":[null,"חדר שיחה זה מצריך סיסמה"],"Password: ":[null,"סיסמה: "],Submit:[null,"שלח"],"This room is not anonymous":[null,"חדר זה אינו אנונימי"],"This room now shows unavailable members":[null,"חדר זה כעת מציג חברים לא זמינים"],"This room does not show unavailable members":[null,"חדר זה לא מציג חברים לא זמינים"],"Non-privacy-related room configuration has changed":[null,"תצורת חדר אשר לא-קשורה-בפרטיות שונתה"],"Room logging is now enabled":[null,"יומן חדר הינו מופעל כעת"],"Room logging is now disabled":[null,"יומן חדר הינו מנוטרל כעת"],"This room is now non-anonymous":[null,"חדר זה אינו אנונימי כעת"],"This room is now semi-anonymous":[null,"חדר זה הינו אנונימי למחצה כעת"],"This room is now fully-anonymous":[null,"חדר זה הינו אנונימי לחלוטין כעת"],"A new room has been created":[null,"חדר חדש נוצר"],"Your nickname has been changed":[null,"שם הכינוי שלך שונה"],"<strong>%1$s</strong> has been banned":[null,"<strong>%1$s</strong> נאסר(ה)"],"<strong>%1$s</strong> has been kicked out":[null,"<strong>%1$s</strong> נבעט(ה)"],"<strong>%1$s</strong> has been removed because of an affiliation change":[null,"<strong>%1$s</strong> הוסרה(ה) משום שינוי שיוך"],"<strong>%1$s</strong> has been removed for not being a member":[null,"<strong>%1$s</strong> הוסר(ה) משום אי הימצאות במסגרת מעמד של חבר"],"You have been banned from this room":[null,"נאסרת מתוך חדר זה"],"You have been kicked from this room":[null,"נבעטת מתוך חדר זה"],"You have been removed from this room because of an affiliation change":[null,"הוסרת מתוך חדר זה משום שינוי שיוך"],"You have been removed from this room because the room has changed to members-only and you're not a member":[null,"הוסרת מתוך חדר זה משום שהחדר שונה לחברים-בלבד ואינך במעמד של חבר"],"You have been removed from this room because the MUC (Multi-user chat) service is being shut down.":[null,"הוסרת מתוך חדר זה משום ששירות שמ״מ (שיחה מרובת משתמשים) זה כעת מצוי בהליכי סגירה."],"You are not on the member list of this room":[null,"אינך ברשימת החברים של חדר זה"],"No nickname was specified":[null,"לא צוין שום שם כינוי"],"You are not allowed to create new rooms":[null,"אין לך רשות ליצור חדרים חדשים"],"Your nickname doesn't conform to this room's policies":[null,"שם הכינוי שלך לא תואם את המדינויות של חדר זה"],"Your nickname is already taken":[null,"שם הכינוי שלך הינו תפוס"],"This room does not (yet) exist":[null,"חדר זה (עדיין) לא קיים"],"This room has reached it's maximum number of occupants":[null,"חדר זה הגיע לסף הנוכחים המרבי שלו"],"Topic set by %1$s to: %2$s":[null,"נושא חדר זה נקבע על ידי %1$s אל: %2$s"],"This user is a moderator":[null,"משתמש זה הינו אחראי"],"This user can send messages in this room":[null,"משתמש זה מסוגל לשלוח הודעות בתוך חדר זה"],"This user can NOT send messages in this room":[null,"משתמש זה ﬥﬡ מסוגל לשלוח הודעות בתוך חדר זה"],"Click to chat with this contact":[null,"לחץ כדי לשוחח עם איש קשר זה"],"Click to remove this contact":[null,"לחץ כדי להסיר את איש קשר זה"],"Contact requests":[null,"בקשות איש קשר"],"My contacts":[null,"אנשי הקשר שלי"],"Pending contacts":[null,"אנשי קשר ממתינים"],"Custom status":[null,"מצב מותאם"],"Click to change your chat status":[null,"לחץ כדי לשנות את הודעת השיחה שלך"],"Click here to write a custom status message":[null,"לחץ כאן כדי לכתוב הודעת מצב מותאמת"],online:[null,"מקוון"],busy:[null,"עסוק"],"away for long":[null,"נעדר לזמן מה"],away:[null,"נעדר"],"I am %1$s":[null,"מצבי כעת הינו %1$s"],"Sign in":[null,"התחברות"],"XMPP/Jabber Username:":[null,"שם משתמש XMPP/Jabber:"],"Password:":[null,"סיסמה:"],"Log In":[null,"כניסה"],"BOSH Service URL:":[null,"כתובת שירות BOSH:"]}}};typeof define=="function"&&define.amd?define("he",["jed"],function(){return t(new Jed(n))}):(window.locales||(window.locales={}),window.locales.he=t(new Jed(n)))}(this,function(e){return e}),function(e,t){var n={domain:"converse",locale_data:{converse:{"":{"Project-Id-Version":"Converse.js 0.4","Report-Msgid-Bugs-To":"","POT-Creation-Date":"2013-09-24 23:22+0200","PO-Revision-Date":"2013-09-25 22:42+0200","Last-Translator":"Krisztian Kompar <w3host@w3host.hu>","Language-Team":"Hungarian",Language:"hu","MIME-Version":"1.0","Content-Type":"text/plain; charset=UTF-8","Content-Transfer-Encoding":"8bit",domain:"converse",lang:"hu",plural_forms:"nplurals=2; plural=(n != 1);"},Disconnected:[null,"Szétkapcsolva"],Error:[null,"Hiba"],Connecting:[null,"Kapcsolódás"],"Connection Failed":[null,"Kapcsolódási hiba"],Authenticating:[null,"Azonosítás"],"Authentication Failed":[null,"Azonosítási hiba"],Disconnecting:[null,"Szétkapcsolás"],me:[null,"én"],"%1$s is typing":[null,"%1$s gépel"],"Show this menu":[null,"Mutasd ezt a menüt"],"Write in the third person":[null,""],"Remove messages":[null,"Üzenet törlése"],"Personal message":[null,"Saját üzenet"],Contacts:[null,"Kapcsolatok"],Online:[null,"Elérhető"],Busy:[null,"Foglalt"],Away:[null,"Távol"],Offline:[null,"Nem elérhető"],"Click to add new chat contacts":[null,"Új kapcsolatok hozzáadása"],"Add a contact":[null,"Új kapcsolat"],"Contact username":[null,"Felhasználónév"],Add:[null,"Hozzáadás"],"Contact name":[null,"Kapcsolat neve"],Search:[null,"Keresés"],"No users found":[null,"Nincs találat"],"Click to add as a chat contact":[null,"Csevegő kapcsolatként hozzáad"],"Click to open this room":[null,"Belépés a csevegő szobába"],"Show more information on this room":[null,"További információk a csevegő szobáról"],"Description:":[null,"Leírás:"],"Occupants:":[null,"Jelenlevők:"],"Features:":[null,"Tulajdonságok"],"Requires authentication":[null,"Azonosítás szükséges"],Hidden:[null,"Rejtett"],"Requires an invitation":[null,"Meghívás szükséges"],Moderated:[null,"Moderált"],"Non-anonymous":[null,"NEM névtelen"],"Open room":[null,"Nyitott szoba"],"Permanent room":[null,"Állandó szoba"],Public:[null,"Nyílvános"],"Semi-anonymous":[null,"Félig névtelen"],"Temporary room":[null,"Ideiglenes szoba"],Unmoderated:[null,"Moderálatlan"],Rooms:[null,"Szobák"],"Room name":[null,"A szoba neve"],Nickname:[null,"Becenév"],Server:[null,"Szerver"],Join:[null,"Csatlakozás"],"Show rooms":[null,"Létező szobák"],"No rooms on %1$s":[null,"Nincs csevegő szoba a(z) %1$s szerveren"],"Rooms on %1$s":[null,"Csevegő szobák a(z) %1$s szerveren"],"Set chatroom topic":[null,"Csevegőszoba téma beállítás"],"Kick user from chatroom":[null,"Felhasználó kiléptetése a csevegő szobából"],"Ban user from chatroom":[null,"Felhasználó kitíltása a csevegő szobából"],Message:[null,"Üzenet"],Save:[null,"Mentés"],Cancel:[null,"Mégsem"],"An error occurred while trying to save the form.":[null,"Hiba történt az adatok mentése közben."],"This chatroom requires a password":[null,"A csevegő szoba belépéshez jelszó szükséges"],"Password: ":[null,"Jelszó:"],Submit:[null,"Küldés"],"This room is not anonymous":[null,"Ez a szoba NEM névtelen"],"This room now shows unavailable members":[null,"Ez a szoba mutatja az elérhetetlen tagokat"],"This room does not show unavailable members":[null,"Ez a szoba nem mutatja az elérhetetlen tagokat"],"Non-privacy-related room configuration has changed":[null,"A szoba általános konfigurációja módosult"],"Room logging is now enabled":[null,"A szobába a belépés lehetséges"],"Room logging is now disabled":[null,"A szobába a belépés szünetel"],"This room is now non-anonymous":[null,"Ez a szoba most NEM névtelen"],"This room is now semi-anonymous":[null,"Ez a szoba most félig névtelen"],"This room is now fully-anonymous":[null,"Ez a szoba most teljesen névtelen"],"A new room has been created":[null,"Létrejött egy új csevegő szoba"],"Your nickname has been changed":[null,"A beceneved módosításra került"],"<strong>%1$s</strong> has been banned":[null,"A szobából kitíltva: <strong>%1$s</strong>"],"<strong>%1$s</strong> has been kicked out":[null,"A szobából kidobva: <strong>%1$s</strong>"],"<strong>%1$s</strong> has been removed because of an affiliation change":[null,"Taglista módosítás miatt a szobából kiléptetve: <strong>%1$s</strong>"],"<strong>%1$s</strong> has been removed for not being a member":[null,"A taglistán nem szerepel így a szobából kiléptetve: <strong>%1$s</strong>"],"You have been banned from this room":[null,"Ki lettél tíltva ebből a szobából"],"You have been kicked from this room":[null,"Ki lettél dobva ebből a szobából"],"You have been removed from this room because of an affiliation change":[null,"Taglista módosítás miatt kiléptettünk a csevegő szobából"],"You have been removed from this room because the room has changed to members-only and you're not a member":[null,"Kiléptettünk a csevegő szobából, mert mostantól csak a taglistán szereplők lehetnek jelen."],"You have been removed from this room because the MUC (Multi-user chat) service is being shut down.":[null,"Kiléptettünk a csevegő szobából, mert a MUC (Multi-User Chat) szolgáltatás leállításra került."],"You are not on the member list of this room":[null,"Nem szerepelsz a csevegő szoba taglistáján"],"No nickname was specified":[null,"Nem lett megadva becenév"],"You are not allowed to create new rooms":[null,"Nem lehet új csevegő szobát létrehozni"],"Your nickname doesn't conform to this room's policies":[null,"A beceneved ütközik a csevegő szoba szabályzataival"],"Your nickname is already taken":[null,"A becenevedet már valaki használja"],"This room does not (yet) exist":[null,"Ez a szoba (még) nem létezik"],"This room has reached it's maximum number of occupants":[null,"Ez a csevegő szoba elérte a maximális jelenlevők számát"],"Topic set by %1$s to: %2$s":[null,"A következő témát állította be %1$s: %2$s"],"This user is a moderator":[null,"Ez a felhasználó egy moderátor"],"This user can send messages in this room":[null,"Ez a felhasználó küldhet üzenetet ebbe a szobába"],"This user can NOT send messages in this room":[null,"Ez a felhasználó NEM küldhet üzenetet ebbe a szobába"],"Click to chat with this contact":[null,"Csevegés indítása ezzel a kapcsolatunkkal"],"Click to remove this contact":[null,"A kapcsolat törlése"],"This contact is busy":[null,"Elfoglalt"],"This contact is online":[null,"Online"],"This contact is offline":[null,"Nincs bejelentkezve"],"This contact is unavailable":[null,"Elérhetetlen"],"This contact is away for an extended period":[null,"Hosszabb ideje távol"],"This contact is away":[null,"Távol"],"Contact requests":[null,"Kapcsolat felvételi kérés"],"My contacts":[null,"Kapcsolatok:"],"Pending contacts":[null,"Függőben levő kapcsolatok"],"Custom status":[null,"Egyedi státusz"],"Click to change your chat status":[null,"Saját státusz beállítása"],"Click here to write a custom status message":[null,"Egyedi státusz üzenet írása"],online:[null,"online"],busy:[null,"elfoglalt"],"away for long":[null,"hosszú ideje távol"],away:[null,"távol"],"I am %1$s":[null,"%1$s vagyok"],"Sign in":[null,"Belépés"],"XMPP/Jabber Username:":[null,"XMPP/Jabber azonosító:"],"Password:":[null,"Jelszó:"],"Log In":[null,"Belépés"],"BOSH Service URL:":[null,"BOSH szerver URL"],"Online Contacts":[null,"Online kapcsolatok"]}}};typeof define=="function"&&define.amd?define("hu",["jed"],function(){return t(new Jed(n))}):(window.locales||(window.locales={}),window.locales.hu=t(new Jed(n)))}(this,function(e){return e}),function(e,t){var n={domain:"converse",locale_data:{converse:{"":{"project-id-version":"Converse.js 0.7.0","report-msgid-bugs-to":"","pot-creation-date":"2014-01-22 17:07+0200","po-revision-date":"2014-01-25 21:30+0700","last-translator":"Priyadi Iman Nurcahyo <priyadi@priyadi.net>","language-team":"Bahasa Indonesia","mime-version":"1.0","content-type":"text/plain; charset=UTF-8","content-transfer-encoding":"8bit",language:"id"},unencrypted:[null,"tak dienkripsi"],unverified:[null,"tak diverifikasi"],verified:[null,"diverifikasi"],finished:[null,"selesai"],"This contact is busy":[null,"Teman ini sedang sibuk"],"This contact is online":[null,"Teman ini terhubung"],"This contact is offline":[null,"Teman ini tidak terhubung"],"This contact is unavailable":[null,"Teman ini tidak tersedia"],"This contact is away for an extended period":[null,"Teman ini tidak di tempat untuk waktu yang lama"],"This contact is away":[null,"Teman ini tidak di tempat"],Disconnected:[null,"Terputus"],Error:[null,"Kesalahan"],Connecting:[null,"Menyambung"],"Connection Failed":[null,"Gagal Menyambung"],Authenticating:[null,"Melakukan otentikasi"],"Authentication Failed":[null,"Otentikasi gagal"],Disconnecting:[null,"Memutuskan hubungan"],"Online Contacts":[null,"Teman yang Terhubung"],"Re-establishing encrypted session":[null,"Menyambung kembali sesi terenkripsi"],"Your browser needs to generate a private key, which will be used in your encrypted chat session. This can take up to 30 seconds during which your browser might freeze and become unresponsive.":[null,"Perambah anda perlu membuat kunci privat, yang akan digunakan pada sesi perbincangan anda. Ini akan membutuhkan waktu sampai 30 detik, dan selama itu perambah mungkin akan tidak responsif."],"Private key generated.":[null,"Kunci privat berhasil dibuat."],"Authentication request from %1$s\n\nYour buddy is attempting to verify your identity, by asking you the question below.\n\n%2$s":[null,"Permintaan otentikasi dari %1$s\n\nTeman anda mencoba untuk melakukan verifikasi identitas anda dengan cara menanyakan pertanyaan di bawah ini.\n\n%2$s"],"Could not verify this user's identify.":[null,"Tak dapat melakukan verifikasi identitas pengguna ini."],"Personal message":[null,"Pesan pribadi"],"Start encrypted conversation":[null,"Mulai sesi terenkripsi"],"Refresh encrypted conversation":[null,"Setel ulang percakapan terenkripsi"],"End encrypted conversation":[null,"Sudahi percakapan terenkripsi"],"Verify with SMP":[null,"Verifikasi menggunakan SMP"],"Verify with fingerprints":[null,"Verifikasi menggunakan sidik jari"],"What's this?":[null,"Apakah ini?"],me:[null,"saya"],"Show this menu":[null,"Tampilkan menu ini"],"Write in the third person":[null,"Tulis ini menggunakan bahasa pihak ketiga"],"Remove messages":[null,"Hapus pesan"],"Your message could not be sent":[null,"Pesan anda tak dapat dikirim"],"We received an unencrypted message":[null,"Kami menerima pesan terenkripsi"],"We received an unreadable encrypted message":[null,"Kami menerima pesan terenkripsi yang gagal dibaca"],"This user has requested an encrypted session.":[null,"Pengguna ini meminta sesi terenkripsi"],"Here are the fingerprints, please confirm them with %1$s, outside of this chat.\n\nFingerprint for you, %2$s: %3$s\n\nFingerprint for %1$s: %4$s\n\nIf you have confirmed that the fingerprints match, click OK, otherwise click Cancel.":[null,"Ini adalah sidik jari anda, konfirmasikan bersama mereka dengan %1$s, di luar percakapan ini.\n\nSidik jari untuk anda, %2$s: %3$s\n\nSidik jari untuk %1$s: %4$s\n\nJika anda bisa mengkonfirmasi sidik jadi cocok, klik Lanjutkan, jika tidak klik Batal."],"You will be prompted to provide a security question and then an answer to that question.\n\nYour buddy will then be prompted the same question and if they type the exact same answer (case sensitive), their identity will have been verified.":[null,"Anda akan ditanyakan pertanyaan untuk keamanan beserta jawaban untuk pertanyaan tersebut.\n\nTeman anda akan ditanyakan pertanyaan yang sama dan jika dia memberikan jawaban yang sama (huruf kapital diperhatikan), identitas mereka diverifikasi."],"What is your security question?":[null,"Apakah pertanyaan keamanan anda?"],"What is the answer to the security question?":[null,"Apa jawaban dari pertanyaan keamanan tersebut?"],"Invalid authentication scheme provided":[null,"Skema otentikasi salah"],"Your messages are not encrypted anymore":[null,"Pesan anda tidak lagi terenkripsi"],"Your messages are now encrypted but your buddy's identity has not been verified.":[null,"Pesan anda sekarang terenkripsi, namun identitas teman anda belum dapat diverifikasi."],"Your buddy's identify has been verified.":[null,"Identitas teman anda telah diverifikasi."],"Your buddy has ended encryption on their end, you should do the same.":[null,"Teman anda menghentikan percakapan terenkripsi, anda sebaiknya melakukan hal yang sama."],"Your messages are not encrypted. Click here to enable OTR encryption.":[null,"Pesan anda tak terenkripsi. Klik di sini untuk menyalakan enkripsi OTR."],"Your messages are encrypted, but your buddy has not been verified.":[null,"Pesan anda terenkripsi, tetapi teman anda belum diverifikasi."],"Your messages are encrypted and your buddy verified.":[null,"Pesan anda terenkripsi dan teman anda telah diverifikasi."],"Your buddy has closed their end of the private session, you should do the same":[null,"Teman anda telah mematikan sesi terenkripsi, dan anda juga sebaiknya melakukan hal yang sama"],Contacts:[null,"Teman"],Online:[null,"Terhubung"],Busy:[null,"Sibuk"],Away:[null,"Pergi"],Offline:[null,"Tak Terhubung"],"Click to add new chat contacts":[null,"Klik untuk menambahkan teman baru"],"Add a contact":[null,"Tambah teman"],"Contact username":[null,"Username teman"],Add:[null,"Tambah"],"Contact name":[null,"Nama teman"],Search:[null,"Cari"],"No users found":[null,"Pengguna tak ditemukan"],"Click to add as a chat contact":[null,"Klik untuk menambahkan sebagai teman"],"Click to open this room":[null,"Klik untuk membuka ruangan ini"],"Show more information on this room":[null,"Tampilkan informasi ruangan ini"],"Description:":[null,"Keterangan:"],"Occupants:":[null,"Penghuni:"],"Features:":[null,"Fitur:"],"Requires authentication":[null,"Membutuhkan otentikasi"],Hidden:[null,"Tersembunyi"],"Requires an invitation":[null,"Membutuhkan undangan"],Moderated:[null,"Dimoderasi"],"Non-anonymous":[null,"Tidak anonim"],"Open room":[null,"Ruangan terbuka"],"Permanent room":[null,"Ruangan permanen"],Public:[null,"Umum"],"Semi-anonymous":[null,"Semi-anonim"],"Temporary room":[null,"Ruangan sementara"],Unmoderated:[null,"Tak dimoderasi"],Rooms:[null,"Ruangan"],"Room name":[null,"Nama ruangan"],Nickname:[null,"Nama panggilan"],Server:[null,"Server"],Join:[null,"Ikuti"],"Show rooms":[null,"Perlihatkan ruangan"],"No rooms on %1$s":[null,"Tak ada ruangan di %1$s"],"Rooms on %1$s":[null,"Ruangan di %1$s"],"Set chatroom topic":[null,"Setel topik ruangan"],"Kick user from chatroom":[null,"Tendang pengguna dari ruangan"],"Ban user from chatroom":[null,"Larang pengguna dari ruangan"],Message:[null,"Pesan"],Save:[null,"Simpan"],Cancel:[null,"Batal"],"An error occurred while trying to save the form.":[null,"Kesalahan terjadi saat menyimpan formulir ini."],"This chatroom requires a password":[null,"Ruangan ini membutuhkan kata sandi"],"Password: ":[null,"Kata sandi: "],Submit:[null,"Kirim"],"This room is not anonymous":[null,"Ruangan ini tidak anonim"],"This room now shows unavailable members":[null,"Ruangan ini menampilkan anggota yang tak tersedia"],"This room does not show unavailable members":[null,"Ruangan ini tidak menampilkan anggota yang tak tersedia"],"Non-privacy-related room configuration has changed":[null,"Konfigurasi ruangan yang tak berhubungan dengan privasi telah diubah"],"Room logging is now enabled":[null,"Pencatatan di ruangan ini sekarang dinyalakan"],"Room logging is now disabled":[null,"Pencatatan di ruangan ini sekarang dimatikan"],"This room is now non-anonymous":[null,"Ruangan ini sekarang tak-anonim"],"This room is now semi-anonymous":[null,"Ruangan ini sekarang semi-anonim"],"This room is now fully-anonymous":[null,"Ruangan ini sekarang anonim"],"A new room has been created":[null,"Ruangan baru telah dibuat"],"Your nickname has been changed":[null,"Nama panggilan anda telah diubah"],"<strong>%1$s</strong> has been banned":[null,"<strong>%1$s</strong> telah dicekal"],"<strong>%1$s</strong> has been kicked out":[null,"<strong>%1$s</strong> telah ditendang keluar"],"<strong>%1$s</strong> has been removed because of an affiliation change":[null,"<strong>%1$s</strong> telah dihapus karena perubahan afiliasi"],"<strong>%1$s</strong> has been removed for not being a member":[null,"<strong>%1$s</strong> telah dihapus karena bukan anggota"],"You have been banned from this room":[null,"Anda telah dicekal dari ruangan ini"],"You have been kicked from this room":[null,"Anda telah ditendang dari ruangan ini"],"You have been removed from this room because of an affiliation change":[null,"Anda telah dihapus dari ruangan ini karena perubahan afiliasi"],"You have been removed from this room because the room has changed to members-only and you're not a member":[null,"Anda telah dihapus dari ruangan ini karena ruangan ini hanya terbuka untuk anggota dan anda bukan anggota"],"You have been removed from this room because the MUC (Multi-user chat) service is being shut down.":[null,"Anda telah dihapus dari ruangan ini karena layanan MUC (Multi-user chat) telah dimatikan."],"You are not on the member list of this room":[null,"Anda bukan anggota dari ruangan ini"],"No nickname was specified":[null,"Nama panggilan belum ditentukan"],"You are not allowed to create new rooms":[null,"Anda tak diizinkan untuk membuat ruangan baru"],"Your nickname doesn't conform to this room's policies":[null,"Nama panggilan anda tidak sesuai aturan ruangan ini"],"Your nickname is already taken":[null,"Nama panggilan anda telah digunakan orang lain"],"This room does not (yet) exist":[null,"Ruangan ini belum dibuat"],"This room has reached it's maximum number of occupants":[null,"Ruangan ini telah mencapai jumlah penghuni maksimum"],"Topic set by %1$s to: %2$s":[null,"Topik diganti oleh %1$s menjadi: %2$s"],"This user is a moderator":[null,"Pengguna ini adalah moderator"],"This user can send messages in this room":[null,"Pengguna ini dapat mengirim pesan di ruangan ini"],"This user can NOT send messages in this room":[null,"Pengguna ini tak dapat mengirim pesan di ruangan ini"],"Click to chat with this contact":[null,"Klik untuk mulai perbinjangan dengan teman ini"],"Click to remove this contact":[null,"Klik untuk menghapus teman ini"],"Contact requests":[null,"Permintaan pertemanan"],"My contacts":[null,"Teman saya"],"Pending contacts":[null,"Teman yang menunggu"],"Custom status":[null,"Status kustom"],"Click to change your chat status":[null,"Klik untuk mengganti status"],"Click here to write a custom status message":[null,"Klik untuk menulis status kustom"],online:[null,"terhubung"],busy:[null,"sibuk"],"away for long":[null,"lama tak di tempat"],away:[null,"tak di tempat"],"I am %1$s":[null,"Saya %1$s"],"Sign in":[null,"Masuk"],"XMPP/Jabber Username:":[null,"Nama pengguna XMPP/Jabber:"],"Password:":[null,"Kata sandi:"],"Log In":[null,"Masuk"],"BOSH Service URL:":[null,"URL Layanan BOSH:"]}}};typeof define=="function"&&define.amd?define("id",["jed"],function(){return t(new Jed(n))}):(window.locales||(window.locales={}),window.locales.id=t(new Jed(n)))}(this,function(e){return e}),function(e,t){var n={domain:"converse",locale_data:{converse:{"":{"Project-Id-Version":"Converse.js 0.4","Report-Msgid-Bugs-To":"","POT-Creation-Date":"2013-09-15 21:55+0200","PO-Revision-Date":"2013-09-15 22:00+0200","Last-Translator":"Fabio Bas <ctrlaltca@gmail.com>","Language-Team":"Italian",Language:"it","MIME-Version":"1.0","Content-Type":"text/plain; charset=UTF-8","Content-Transfer-Encoding":"8bit","Plural-Forms":"nplurals=2; plural=(n != 1);",domain:"converse",lang:"it",plural_forms:"nplurals=2; plural=(n != 1);"},unencrypted:[null,""],unverified:[null,""],verified:[null,""],finished:[null,""],Disconnected:[null,"Disconnesso"],Error:[null,"Errore"],Connecting:[null,"Connessione in corso"],"Connection Failed":[null,"Connessione fallita"],Authenticating:[null,"Autenticazione in corso"],"Authentication Failed":[null,"Autenticazione fallita"],Disconnecting:[null,"Disconnessione in corso"],"Re-establishing encrypted session":[null,""],"Your browser needs to generate a private key, which will be used in your encrypted chat session. This can take up to 30 seconds during which your browser might freeze and become unresponsive.":[null,""],"Private key generated.":[null,""],"Authentication request from %1$s\n\nYour buddy is attempting to verify your identity, by asking you the question below.\n\n%2$s":[null,""],"Could not verify this user's identify.":[null,""],"Personal message":[null,"Messaggio personale"],"Start encrypted conversation":[null,""],"Refresh encrypted conversation":[null,""],"End encrypted conversation":[null,""],"Verify with SMP":[null,""],"Verify with fingerprints":[null,""],"What's this?":[null,""],me:[null,""],"Show this menu":[null,"Mostra questo menu"],"Write in the third person":[null,"Scrivi in terza persona"],"Remove messages":[null,"Rimuovi messaggi"],"Your message could not be sent":[null,""],"We received an unencrypted message":[null,""],"We received an unreadable encrypted message":[null,""],"This user has requested an encrypted session.":[null,""],"Here are the fingerprints, please confirm them with %1$s, outside of this chat.\n\nFingerprint for you, %2$s: %3$s\n\nFingerprint for %1$s: %4$s\n\nIf you have confirmed that the fingerprints match, click OK, otherwise click Cancel.":[null,""],"You will be prompted to provide a security question and then an answer to that question.\n\nYour buddy will then be prompted the same question and if they type the exact same answer (case sensitive), their identity will have been verified.":[null,""],"What is your security question?":[null,""],"What is the answer to the security question?":[null,""],"Invalid authentication scheme provided":[null,""],"Your messages are not encrypted anymore":[null,""],"Your messages are now encrypted but your buddy's identity has not been verified.":[null,""],"Your buddy's identify has been verified.":[null,""],"Your buddy has ended encryption on their end, you should do the same.":[null,""],"Your messages are not encrypted. Click here to enable OTR encryption.":[null,""],"Your messages are encrypted, but your buddy has not been verified.":[null,""],"Your messages are encrypted and your buddy verified.":[null,""],"Your buddy has closed their end of the private session, you should do the same":[null,""],Contacts:[null,"Contatti"],Online:[null,"In linea"],Busy:[null,"Occupato"],Away:[null,"Assente"],Offline:[null,"Non in linea"],"Click to add new chat contacts":[null,"Clicca per aggiungere nuovi contatti alla chat"],"Add a contact":[null,"Aggiungi contatti"],"Contact username":[null,"Nome utente del contatto"],Add:[null,"Aggiungi"],"Contact name":[null,"Nome del contatto"],Search:[null,"Cerca"],"No users found":[null,"Nessun utente trovato"],"Click to add as a chat contact":[null,"Clicca per aggiungere il contatto alla chat"],"Click to open this room":[null,"Clicca per aprire questa stanza"],"Show more information on this room":[null,"Mostra più informazioni su questa stanza"],"Description:":[null,"Descrizione:"],"Occupants:":[null,"Utenti presenti:"],"Features:":[null,"Funzionalità:"],"Requires authentication":[null,"Richiede autenticazione"],Hidden:[null,"Nascosta"],"Requires an invitation":[null,"Richiede un invito"],Moderated:[null,"Moderata"],"Non-anonymous":[null,"Non-anonima"],"Open room":[null,"Stanza aperta"],"Permanent room":[null,"Stanza permanente"],Public:[null,"Pubblica"],"Semi-anonymous":[null,"Semi-anonima"],"Temporary room":[null,"Stanza temporanea"],Unmoderated:[null,"Non moderata"],Rooms:[null,"Stanze"],"Room name":[null,"Nome stanza"],Nickname:[null,"Soprannome"],Server:[null,"Server"],Join:[null,"Entra"],"Show rooms":[null,"Mostra stanze"],"No rooms on %1$s":[null,"Nessuna stanza su %1$s"],"Rooms on %1$s":[null,"Stanze su %1$s"],"Set chatroom topic":[null,"Cambia oggetto della stanza"],"Kick user from chatroom":[null,"Espelli utente dalla stanza"],"Ban user from chatroom":[null,"Bandisci utente dalla stanza"],Message:[null,"Messaggio"],Save:[null,"Salva"],Cancel:[null,"Annulla"],"An error occurred while trying to save the form.":[null,"Errore durante il salvataggio del modulo"],"This chatroom requires a password":[null,"Questa stanza richiede una password"],"Password: ":[null,"Password: "],Submit:[null,"Invia"],"This room is not anonymous":[null,"Questa stanza non è anonima"],"This room now shows unavailable members":[null,"Questa stanza mostra i membri non disponibili al momento"],"This room does not show unavailable members":[null,"Questa stanza non mostra i membri non disponibili"],"Non-privacy-related room configuration has changed":[null,"Una configurazione della stanza non legata alla privacy è stata modificata"],"Room logging is now enabled":[null,"La registrazione è abilitata nella stanza"],"Room logging is now disabled":[null,"La registrazione è disabilitata nella stanza"],"This room is now non-anonymous":[null,"Questa stanza è non-anonima"],"This room is now semi-anonymous":[null,"Questa stanza è semi-anonima"],"This room is now fully-anonymous":[null,"Questa stanza è completamente-anonima"],"A new room has been created":[null,"Una nuova stanza è stata creata"],"Your nickname has been changed":[null,"Il tuo soprannome è stato cambiato"],"<strong>%1$s</strong> has been banned":[null,"<strong>%1$s</strong> è stato bandito"],"<strong>%1$s</strong> has been kicked out":[null,"<strong>%1$s</strong> è stato espulso"],"<strong>%1$s</strong> has been removed because of an affiliation change":[null,"<strong>%1$s</strong> è stato rimosso a causa di un cambio di affiliazione"],"<strong>%1$s</strong> has been removed for not being a member":[null,"<strong>%1$s</strong> è stato rimosso in quanto non membro"],"You have been banned from this room":[null,"Sei stato bandito da questa stanza"],"You have been kicked from this room":[null,"Sei stato espulso da questa stanza"],"You have been removed from this room because of an affiliation change":[null,"Sei stato rimosso da questa stanza a causa di un cambio di affiliazione"],"You have been removed from this room because the room has changed to members-only and you're not a member":[null,"Sei stato rimosso da questa stanza poiché ora la stanza accetta solo membri"],"You have been removed from this room because the MUC (Multi-user chat) service is being shut down.":[null,"Sei stato rimosso da questa stanza poiché il servizio MUC (Chat multi utente) è in fase di spegnimento"],"You are not on the member list of this room":[null,"Non sei nella lista dei membri di questa stanza"],"No nickname was specified":[null,"Nessun soprannome specificato"],"You are not allowed to create new rooms":[null,"Non ti è permesso creare nuove stanze"],"Your nickname doesn't conform to this room's policies":[null,"Il tuo soprannome non è conforme alle regole di questa stanza"],"Your nickname is already taken":[null,"Il tuo soprannome è già utilizzato"],"This room does not (yet) exist":[null,"Questa stanza non esiste (per ora)"],"This room has reached it's maximum number of occupants":[null,"Questa stanza ha raggiunto il limite massimo di utenti"],"Topic set by %1$s to: %2$s":[null,"Topic impostato da %1$s a: %2$s"],"This user is a moderator":[null,"Questo utente è un moderatore"],"This user can send messages in this room":[null,"Questo utente può inviare messaggi in questa stanza"],"This user can NOT send messages in this room":[null,"Questo utente NON può inviare messaggi in questa stanza"],"Click to chat with this contact":[null,"Clicca per parlare con questo contatto"],"Click to remove this contact":[null,"Clicca per rimuovere questo contatto"],"This contact is busy":[null,""],"This contact is online":[null,""],"This contact is offline":[null,""],"This contact is unavailable":[null,"Questa stanza mostra i membri non disponibili al momento"],"This contact is away for an extended period":[null,""],"This contact is away":[null,""],"Contact requests":[null,"Richieste dei contatti"],"My contacts":[null,"I miei contatti"],"Pending contacts":[null,"Contatti in attesa"],"Custom status":[null,"Stato personalizzato"],"Click to change your chat status":[null,"Clicca per cambiare il tuo stato"],"Click here to write a custom status message":[null,"Clicca qui per scrivere un messaggio di stato personalizzato"],online:[null,"in linea"],busy:[null,"occupato"],"away for long":[null,"assente da molto"],away:[null,"assente"],"I am %1$s":[null,"Sono %1$s"],"Sign in":[null,"Accesso"],"XMPP/Jabber Username:":[null,"Nome utente:"],"Password:":[null,"Password:"],"Log In":[null,"Entra"],"BOSH Service URL:":[null,"Indirizzo servizio BOSH:"],"Online Contacts":[null,"Contatti in linea"],Connected:[null,"Connesso"],Attached:[null,"Allegato"]}}};typeof define=="function"&&define.amd?define("it",["jed"],function(){return t(new Jed(n))}):(window.locales||(window.locales={}),window.locales.it=t(new Jed(n)))}(this,function(e){return e}),function(e,t){var n={domain:"converse",locale_data:{converse:{"":{"Project-Id-Version":"Converse.js 0.4","Report-Msgid-Bugs-To":"","POT-Creation-Date":"2014-01-07 11:12+0900","PO-Revision-Date":"2014-01-07 11:32+0900","Last-Translator":"Mako N <mako@pasero.net>","Language-Team":"Language JA",Language:"JA","MIME-Version":"1.0","Content-Type":"text/plain; charset=UTF-8","Content-Transfer-Encoding":"8bit","Plural-Forms":"nplurals=1; plural=0;"},unencrypted:[null,"暗号化されていません"],unverified:[null,"検証されていません"],verified:[null,"検証されました"],finished:[null,"完了"],"This contact is busy":[null,"この相手先は取り込み中です"],"This contact is online":[null,"この相手先は在席しています"],"This contact is offline":[null,"この相手先はオフラインです"],"This contact is unavailable":[null,"この相手先は不通です"],"This contact is away for an extended period":[null,"この相手先は不在です"],"This contact is away":[null,"この相手先は離席中です"],Disconnected:[null,"切断中"],Error:[null,"エラー"],Connecting:[null,"接続中です"],"Connection Failed":[null,"接続に失敗しました"],Authenticating:[null,"認証中"],"Authentication Failed":[null,"認証に失敗"],Disconnecting:[null,"切断"],"Online Contacts":[null,"オンラインの相手先"],"Re-establishing encrypted session":[null,"暗号化セッションの再接続"],"Your browser needs to generate a private key, which will be used in your encrypted chat session. This can take up to 30 seconds during which your browser might freeze and become unresponsive.":[null,"暗号化チャットで使用する秘密鍵を生成する必要があります。これには30秒ほどかかり、そのあいだブラウザがフリーズして反応しないかもしれません。"],"Private key generated.":[null,"秘密鍵を生成しました。"],"Authentication request from %1$s\n\nYour buddy is attempting to verify your identity, by asking you the question below.\n\n%2$s":[null,"%1$s からの認証のリクエスト\n\n相手はあなたの本人性を検証しようとしています。次の質問に答えてください。\n\n%2$s"],"Could not verify this user's identify.":[null,"このユーザーの本人性を検証できませんでした。"],"Personal message":[null,"私信"],"Start encrypted conversation":[null,"暗号化された会話を開始"],"Refresh encrypted conversation":[null,"暗号化された会話をリフレッシュ"],"End encrypted conversation":[null,"暗号化された会話を終了"],"Verify with SMP":[null,"SMP で検証"],"Verify with fingerprints":[null,"鍵指紋で検証"],"What's this?":[null,"これは何ですか?"],me:[null,"私"],"Show this menu":[null,"このメニューを表示"],"Write in the third person":[null,"第三者に書く"],"Remove messages":[null,"メッセージを削除"],"Your message could not be sent":[null,"メッセージを送信できませんでした"],"We received an unencrypted message":[null,"暗号化されていないメッセージを受信しました"],"We received an unreadable encrypted message":[null,"読めない暗号化メッセージを受信しました"],"This user has requested an encrypted session.":[null,"このユーザーは暗号化セッションを求めています。"],"Here are the fingerprints, please confirm them with %1$s, outside of this chat.\n\nFingerprint for you, %2$s: %3$s\n\nFingerprint for %1$s: %4$s\n\nIf you have confirmed that the fingerprints match, click OK, otherwise click Cancel.":[null,"これは鍵指紋です。チャット以外の方法でこれらを %1$s と確認してください。\n\nあなた %2$s の鍵指紋: %3$s\n\n%1$s の鍵指紋: %4$s\n\n確認して、鍵指紋が正しければ「OK」を、正しくなければ「キャンセル」をクリックしてください。"],"You will be prompted to provide a security question and then an answer to that question.\n\nYour buddy will then be prompted the same question and if they type the exact same answer (case sensitive), their identity will have been verified.":[null,"秘密の質問を入力し、それに対して答えるように促されます。\n\n相手にも、同じ質問が表示され、正しく同じ答(大文字・小文字は区別されます)を入力することで、本人性を検証します。"],"What is your security question?":[null,"秘密の質問はなんですか?"],"What is the answer to the security question?":[null,"秘密の質問の答はなんですか?"],"Invalid authentication scheme provided":[null,"認証の方式が正しくありません"],"Your messages are not encrypted anymore":[null,"メッセージはもう暗号化されません"],"Your messages are now encrypted but your buddy's identity has not been verified.":[null,"メッセージは暗号化されますが、相手が本人であることは検証されていません。"],"Your buddy's identify has been verified.":[null,"相手の本人性を検証しました。"],"Your buddy has ended encryption on their end, you should do the same.":[null,"相手は、暗号化を終了しました。あなたもそれに合わせる必要があります。"],"Your messages are not encrypted. Click here to enable OTR encryption.":[null,"メッセージは暗号化されません。OTR 暗号化を有効にするにはここをクリックしてください。"],"Your messages are encrypted, but your buddy has not been verified.":[null,"メッセージは暗号化されますが、相手は検証されていません。"],"Your messages are encrypted and your buddy verified.":[null,"メッセージは暗号化され、相手も検証されています。"],"Your buddy has closed their end of the private session, you should do the same":[null,"相手は私信を終了しました。あなたも同じようにしてください"],Contacts:[null,"相手先"],Online:[null,"オンライン"],Busy:[null,"取り込み中"],Away:[null,"離席中"],Offline:[null,"オフライン"],"Click to add new chat contacts":[null,"クリックして新しいチャットの相手先を追加"],"Add a contact":[null,"相手先を追加"],"Contact username":[null,"相手先の名前"],Add:[null,"追加"],"Contact name":[null,"名前"],Search:[null,"検索"],"No users found":[null,"ユーザーが見つかりません"],"Click to add as a chat contact":[null,"クリックしてチャットの相手先として追加"],"Click to open this room":[null,"クリックしてこの談話室を開く"],"Show more information on this room":[null,"この談話室についての詳細を見る"],"Description:":[null,"説明: "],"Occupants:":[null,"入室者:"],"Features:":[null,"特徴:"],"Requires authentication":[null,"認証の要求"],Hidden:[null,"非表示"],"Requires an invitation":[null,"招待の要求"],Moderated:[null,"発言制限"],"Non-anonymous":[null,"非匿名"],"Open room":[null,"開放談話室"],"Permanent room":[null,"常設談話室"],Public:[null,"公開談話室"],"Semi-anonymous":[null,"半匿名"],"Temporary room":[null,"臨時談話室"],Unmoderated:[null,"発言制限なし"],Rooms:[null,"談話室"],"Room name":[null,"談話室の名前"],Nickname:[null,"ニックネーム"],Server:[null,"サーバー"],Join:[null,"入室"],"Show rooms":[null,"談話室一覧を見る"],"No rooms on %1$s":[null,"%1$s に談話室はありません"],"Rooms on %1$s":[null,"%1$s の談話室一覧"],"Set chatroom topic":[null,"談話室の話題を設定"],"Kick user from chatroom":[null,"ユーザーを談話室から蹴り出す"],"Ban user from chatroom":[null,"ユーザーを談話室から締め出す"],Message:[null,"メッセージ"],Save:[null,"保存"],Cancel:[null,"キャンセル"],"An error occurred while trying to save the form.":[null,"フォームを保存する際にエラーが発生しました。"],"This chatroom requires a password":[null,"この談話室にはパスワードが必要です"],"Password: ":[null,"パスワード:"],Submit:[null,"送信"],"This room is not anonymous":[null,"この談話室は非匿名です"],"This room now shows unavailable members":[null,"この談話室はメンバー以外にも見えます"],"This room does not show unavailable members":[null,"この談話室はメンバー以外には見えません"],"Non-privacy-related room configuration has changed":[null,"談話室の設定(プライバシーに無関係)が変更されました"],"Room logging is now enabled":[null,"談話室の記録を取りはじめます"],"Room logging is now disabled":[null,"談話室の記録を止めます"],"This room is now non-anonymous":[null,"この談話室はただいま非匿名です"],"This room is now semi-anonymous":[null,"この談話室はただいま半匿名です"],"This room is now fully-anonymous":[null,"この談話室はただいま匿名です"],"A new room has been created":[null,"新しい談話室が作成されました"],"Your nickname has been changed":[null,"ニックネームを変更しました"],"<strong>%1$s</strong> has been banned":[null,"<strong>%1$s</strong> を締め出しました"],"<strong>%1$s</strong> has been kicked out":[null,"<strong>%1$s</strong> を蹴り出しました"],"<strong>%1$s</strong> has been removed because of an affiliation change":[null,"分掌の変更のため、<strong>%1$s</strong> を削除しました"],"<strong>%1$s</strong> has been removed for not being a member":[null,"メンバーでなくなったため、<strong>%1$s</strong> を削除しました"],"You have been banned from this room":[null,"この談話室から締め出されました"],"You have been kicked from this room":[null,"この談話室から蹴り出されました"],"You have been removed from this room because of an affiliation change":[null,"分掌の変更のため、この談話室から削除されました"],"You have been removed from this room because the room has changed to members-only and you're not a member":[null,"談話室がメンバー制に変更されました。メンバーではないため、この談話室から削除されました"],"You have been removed from this room because the MUC (Multi-user chat) service is being shut down.":[null,"MUC(グループチャット)のサービスが停止したため、この談話室から削除されました。"],"You are not on the member list of this room":[null,"この談話室のメンバー一覧にいません"],"No nickname was specified":[null,"ニックネームがありません"],"You are not allowed to create new rooms":[null,"新しい談話室を作成する権限がありません"],"Your nickname doesn't conform to this room's policies":[null,"ニックネームがこの談話室のポリシーに従っていません"],"Your nickname is already taken":[null,"ニックネームは既に使われています"],"This room does not (yet) exist":[null,"この談話室は存在しません"],"This room has reached it's maximum number of occupants":[null,"この談話室は入室者数の上限に達しています"],"Topic set by %1$s to: %2$s":[null,"%1$s が話題を設定しました: %2$s"],"This user is a moderator":[null,"このユーザーは司会者です"],"This user can send messages in this room":[null,"このユーザーはこの談話室で発言できます"],"This user can NOT send messages in this room":[null,"このユーザーはこの談話室で発言できません"],"Click to chat with this contact":[null,"クリックしてこの相手先とチャット"],"Click to remove this contact":[null,"クリックしてこの相手先を削除"],"Contact requests":[null,"会話に呼び出し"],"My contacts":[null,"相手先一覧"],"Pending contacts":[null,"保留中の相手先"],"Custom status":[null,"独自の在席状況"],"Click to change your chat status":[null,"クリックして、在席状況を変更"],"Click here to write a custom status message":[null,"状況メッセージを入力するには、ここをクリック"],online:[null,"在席"],busy:[null,"取り込み中"],"away for long":[null,"不在"],away:[null,"離席中"],"I am %1$s":[null,"私はいま %1$s"],"Sign in":[null,"サインイン"],"XMPP/Jabber Username:":[null,"XMPP/Jabber ユーザー名:"],"Password:":[null,"パスワード:"],"Log In":[null,"ログイン"],"BOSH Service URL:":[null,"BOSH サービス URL:"]}}};typeof define=="function"&&define.amd?define("ja",["jed"],function(){return t(new Jed(n))}):(window.locales||(window.locales={}),window.locales.ja=t(new Jed(n)))}(this,function(e){return e}),function(e,t){var n={domain:"converse",locale_data:{converse:{"":{"Project-Id-Version":"Converse.js 0.4","Report-Msgid-Bugs-To":"","POT-Creation-Date":"2013-09-15 21:55+0200","PO-Revision-Date":"2013-09-15 22:03+0200","Last-Translator":"Maarten Kling <maarten@fourdigits.nl>","Language-Team":"Dutch",Language:"nl","MIME-Version":"1.0","Content-Type":"text/plain; charset=UTF-8","Content-Transfer-Encoding":"8bit","Plural-Forms":"nplurals=2; plural=(n != 1);",domain:"converse",lang:"nl",plural_forms:"nplurals=2; plural=(n != 1);"},unencrypted:[null,"ongecodeerde"],unverified:[null,"niet geverifieerd"],verified:[null,"geverifieerd"],finished:[null,"klaar"],Disconnected:[null,"Verbinding verbroken."],Error:[null,"Error"],Connecting:[null,"Verbinden"],"Connection Failed":[null,"Verbinden mislukt"],Authenticating:[null,"Authenticeren"],"Authentication Failed":[null,"Authenticeren mislukt"],Disconnecting:[null,""],"Re-establishing encrypted session":[null,"Bezig versleutelde sessie te herstellen"],"Your browser needs to generate a private key, which will be used in your encrypted chat session. This can take up to 30 seconds during which your browser might freeze and become unresponsive.":[null,""],"Private key generated.":[null,"Private key gegenereerd."],"Authentication request from %1$s\n\nYour buddy is attempting to verify your identity, by asking you the question below.\n\n%2$s":[null,""],"Could not verify this user's identify.":[null,"Niet kon de identiteit van deze gebruiker niet identificeren."],"Personal message":[null,"Persoonlijk bericht"],"Start encrypted conversation":[null,"Start encrypted gesprek"],"Refresh encrypted conversation":[null,"Ververs encrypted gesprek"],"End encrypted conversation":[null,"Beeindig encrypted gesprek"],"Verify with SMP":[null,""],"Verify with fingerprints":[null,""],"What's this?":[null,"Wat is dit?"],me:[null,"ikzelf"],"Show this menu":[null,"Toon dit menu"],"Write in the third person":[null,"Schrijf in de 3de persoon"],"Remove messages":[null,"Verwijder bericht"],"Your message could not be sent":[null,"Je bericht kon niet worden verzonden"],"We received an unencrypted message":[null,"We ontvingen een unencrypted bericht "],"We received an unreadable encrypted message":[null,"We ontvangen een onleesbaar unencrypted bericht"],"This user has requested an encrypted session.":[null,"Deze gebruiker heeft een encrypted sessie aangevraagd."],"Here are the fingerprints, please confirm them with %1$s, outside of this chat.\n\nFingerprint for you, %2$s: %3$s\n\nFingerprint for %1$s: %4$s\n\nIf you have confirmed that the fingerprints match, click OK, otherwise click Cancel.":[null,""],"You will be prompted to provide a security question and then an answer to that question.\n\nYour buddy will then be prompted the same question and if they type the exact same answer (case sensitive), their identity will have been verified.":[null,""],"What is your security question?":[null,"Wat is jou sericury vraag?"],"What is the answer to the security question?":[null,"Wat is het antwoord op de security vraag?"],"Invalid authentication scheme provided":[null,""],"Your messages are not encrypted anymore":[null,"Je berichten zijn niet meer encrypted"],"Your messages are now encrypted but your buddy's identity has not been verified.":[null,""],"Your buddy's identify has been verified.":[null,"Jou contact is geverifieerd"],"Your buddy has ended encryption on their end, you should do the same.":[null,"Jou contact heeft encryption aanstaan, je moet het zelfde doen."],"Your messages are not encrypted. Click here to enable OTR encryption.":[null,"Jou bericht is niet encrypted. KLik hier om ORC encrytion aan te zetten."],"Your messages are encrypted, but your buddy has not been verified.":[null,"Jou berichten zijn encrypted, maar je contact is niet geverifieerd."],"Your messages are encrypted and your buddy verified.":[null,"Jou bericht is encrypted en jou contact is geverifieerd."],"Your buddy has closed their end of the private session, you should do the same":[null,""],Contacts:[null,"Contacten"],Online:[null,"Online"],Busy:[null,"Bezet"],Away:[null,"Afwezig"],Offline:[null,""],"Click to add new chat contacts":[null,"Klik om nieuwe contacten toe te voegen"],"Add a contact":[null,"Voeg contact toe"],"Contact username":[null,"Contact gebruikernaam"],Add:[null,"Toevoegen"],"Contact name":[null,"Contact naam"],Search:[null,"Zoeken"],"No users found":[null,"Geen gebruikers gevonden"],"Click to add as a chat contact":[null,"Klik om contact toe te voegen"],"Click to open this room":[null,"Klik om room te openen"],"Show more information on this room":[null,"Toon meer informatie over deze room"],"Description:":[null,"Beschrijving"],"Occupants:":[null,"Deelnemers:"],"Features:":[null,"Functies:"],"Requires authentication":[null,"Verificatie vereist"],Hidden:[null,"Verborgen"],"Requires an invitation":[null,"Veriest een uitnodiging"],Moderated:[null,"Gemodereerd"],"Non-anonymous":[null,"Niet annoniem"],"Open room":[null,"Open room"],"Permanent room":[null,"Blijvend room"],Public:[null,"Publiek"],"Semi-anonymous":[null,"Semi annoniem"],"Temporary room":[null,"Tijdelijke room"],Unmoderated:[null,"Niet gemodereerd"],Rooms:[null,"Rooms"],"Room name":[null,"Room naam"],Nickname:[null,"Nickname"],Server:[null,"Server"],Join:[null,"Deelnemen"],"Show rooms":[null,"Toon rooms"],"No rooms on %1$s":[null,"Geen room op %1$s"],"Rooms on %1$s":[null,"Room op %1$s"],"Set chatroom topic":[null,"Zet chatroom topic"],"Kick user from chatroom":[null,"Goei gebruiker uit chatroom"],"Ban user from chatroom":[null,"Ban gebruiker van chatroom"],Message:[null,"Bericht"],Save:[null,"Opslaan"],Cancel:[null,"Annuleren"],"An error occurred while trying to save the form.":[null,"Een error tijdens het opslaan van het formulier."],"This chatroom requires a password":[null,"Chatroom heeft een wachtwoord"],"Password: ":[null,"Wachtwoord: "],Submit:[null,"Indienen"],"This room is not anonymous":[null,"Deze room is niet annoniem"],"This room now shows unavailable members":[null,""],"This room does not show unavailable members":[null,""],"Non-privacy-related room configuration has changed":[null,""],"Room logging is now enabled":[null,""],"Room logging is now disabled":[null,""],"This room is now non-anonymous":[null,"Deze room is nu niet annoniem"],"This room is now semi-anonymous":[null,"Deze room is nu semie annoniem"],"This room is now fully-anonymous":[null,"Deze room is nu volledig annoniem"],"A new room has been created":[null,"Een nieuwe room is gemaakt"],"Your nickname has been changed":[null,"Je nickname is veranderd"],"<strong>%1$s</strong> has been banned":[null,"<strong>%1$s</strong> is verbannen"],"<strong>%1$s</strong> has been kicked out":[null,"<strong>%1$s</strong> has been kicked out"],"<strong>%1$s</strong> has been removed because of an affiliation change":[null,""],"<strong>%1$s</strong> has been removed for not being a member":[null,""],"You have been banned from this room":[null,"Je bent verbannen uit deze room"],"You have been kicked from this room":[null,"Je bent uit de room gegooid"],"You have been removed from this room because of an affiliation change":[null,""],"You have been removed from this room because the room has changed to members-only and you're not a member":[null,""],"You have been removed from this room because the MUC (Multi-user chat) service is being shut down.":[null,""],"You are not on the member list of this room":[null,"Je bent niet een gebruiker van deze room"],"No nickname was specified":[null,"Geen nickname ingegeven"],"You are not allowed to create new rooms":[null,"Je bent niet toegestaan nieuwe rooms te maken"],"Your nickname doesn't conform to this room's policies":[null,"Je nickname is niet conform policy"],"Your nickname is already taken":[null,"Je nickname bestaat al"],"This room does not (yet) exist":[null,"Deze room bestaat niet"],"This room has reached it's maximum number of occupants":[null,"Deze room heeft het maximale aantal gebruikers"],"Topic set by %1$s to: %2$s":[null,""],"This user is a moderator":[null,"Dit is een moderator"],"This user can send messages in this room":[null,"Deze gebruiker kan berichten sturen in deze room"],"This user can NOT send messages in this room":[null,"Deze gebruiker kan NIET een bericht sturen in deze room"],"Click to chat with this contact":[null,"Klik om te chatten met contact"],"Click to remove this contact":[null,"Klik om contact te verwijderen"],"This contact is busy":[null,"Contact is bezet"],"This contact is online":[null,"Contact is online"],"This contact is offline":[null,"Contact is offline"],"This contact is unavailable":[null,"Contact is niet beschikbaar"],"This contact is away for an extended period":[null,"Contact is afwezig voor lange periode"],"This contact is away":[null,"Conact is afwezig"],"Contact requests":[null,"Contact uitnodiging"],"My contacts":[null,"Mijn contacts"],"Pending contacts":[null,"Conacten in afwachting van"],"Custom status":[null,""],"Click to change your chat status":[null,"Klik hier om status te wijzigen"],"Click here to write a custom status message":[null,"Klik hier om custom status bericht te maken"],online:[null,"online"],busy:[null,"bezet"],"away for long":[null,"afwezig lange tijd"],away:[null,"afwezig"],"I am %1$s":[null,"Ik ben %1$s"],"Sign in":[null,"Aanmelden"],"XMPP/Jabber Username:":[null,"XMPP/Jabber Username:"],"Password:":[null,"Wachtwoord:"],"Log In":[null,"Aanmelden"],"BOSH Service URL:":[null,""],"Online Contacts":[null,"Online Contacten"],"%1$s is typing":[null,"%1$s is aan typen"],Connected:[null,"Verbonden"],Attached:[null,"Bijlage"]}}};typeof define=="function"&&define.amd?define("nl",["jed"],function(){return t(new Jed(n))}):(window.locales||(window.locales={}),window.locales.nl=t(new Jed(n)))}(this,function(e){return e}),function(e,t){var n={domain:"converse",locale_data:{converse:{"":{"Project-Id-Version":"Converse.js 0.6.3","Report-Msgid-Bugs-To":"","POT-Creation-Date":"2013-09-15 21:55+0200","PO-Revision-Date":"2013-09-15 22:02+0200","Last-Translator":"Sergio Oliveira <sergio@tracy.com.br>","Language-Team":"Brazilian Portuguese",Language:"pt_BR","MIME-Version":"1.0","Content-Type":"text/plain; charset=UTF-8","Content-Transfer-Encoding":"8bit","Plural-Forms":"nplurals=2; plural=(n > 1);",domain:"converse",lang:"pt_BR",plural_forms:"nplurals=2; plural=(n != 1);"},unencrypted:[null,""],unverified:[null,""],verified:[null,""],finished:[null,""],Disconnected:[null,"Desconectado"],Error:[null,"Erro"],Connecting:[null,"Conectando"],"Connection Failed":[null,"Falha de conexão"],Authenticating:[null,"Autenticando"],"Authentication Failed":[null,"Falha de autenticação"],Disconnecting:[null,"Desconectando"],"Re-establishing encrypted session":[null,""],"Your browser needs to generate a private key, which will be used in your encrypted chat session. This can take up to 30 seconds during which your browser might freeze and become unresponsive.":[null,""],"Private key generated.":[null,""],"Authentication request from %1$s\n\nYour buddy is attempting to verify your identity, by asking you the question below.\n\n%2$s":[null,""],"Could not verify this user's identify.":[null,""],"Personal message":[null,"Mensagem pessoal"],"Start encrypted conversation":[null,""],"Refresh encrypted conversation":[null,""],"End encrypted conversation":[null,""],"Verify with SMP":[null,""],"Verify with fingerprints":[null,""],"What's this?":[null,""],me:[null,"eu"],"Show this menu":[null,"Mostrar o menu"],"Write in the third person":[null,"Escrever em terceira pessoa"],"Remove messages":[null,"Remover mensagens"],"Your message could not be sent":[null,""],"We received an unencrypted message":[null,""],"We received an unreadable encrypted message":[null,""],"This user has requested an encrypted session.":[null,""],"Here are the fingerprints, please confirm them with %1$s, outside of this chat.\n\nFingerprint for you, %2$s: %3$s\n\nFingerprint for %1$s: %4$s\n\nIf you have confirmed that the fingerprints match, click OK, otherwise click Cancel.":[null,""],"You will be prompted to provide a security question and then an answer to that question.\n\nYour buddy will then be prompted the same question and if they type the exact same answer (case sensitive), their identity will have been verified.":[null,""],"What is your security question?":[null,""],"What is the answer to the security question?":[null,""],"Invalid authentication scheme provided":[null,""],"Your messages are not encrypted anymore":[null,""],"Your messages are now encrypted but your buddy's identity has not been verified.":[null,""],"Your buddy's identify has been verified.":[null,""],"Your buddy has ended encryption on their end, you should do the same.":[null,""],"Your messages are not encrypted. Click here to enable OTR encryption.":[null,""],"Your messages are encrypted, but your buddy has not been verified.":[null,""],"Your messages are encrypted and your buddy verified.":[null,""],"Your buddy has closed their end of the private session, you should do the same":[null,""],Contacts:[null,"Contatos"],Online:[null,"Online"],Busy:[null,"Ocupado"],Away:[null,"Ausente"],Offline:[null,"Offline"],"Click to add new chat contacts":[null,"Clique para adicionar novos contatos ao chat"],"Add a contact":[null,"Adicionar contato"],"Contact username":[null,"Usuário do contatt"],Add:[null,"Adicionar"],"Contact name":[null,"Nome do contato"],Search:[null,"Procurar"],"No users found":[null,"Não foram encontrados usuários"],"Click to add as a chat contact":[null,"Clique para adicionar como um contato do chat"],"Click to open this room":[null,"CLique para abrir a sala"],"Show more information on this room":[null,"Mostrar mais informações nessa sala"],"Description:":[null,"Descrição:"],"Occupants:":[null,"Ocupantes:"],"Features:":[null,"Recursos:"],"Requires authentication":[null,"Requer autenticação"],Hidden:[null,"Escondido"],"Requires an invitation":[null,"Requer um convite"],Moderated:[null,"Moderado"],"Non-anonymous":[null,"Não anônimo"],"Open room":[null,"Sala aberta"],"Permanent room":[null,"Sala permanente"],Public:[null,"Público"],"Semi-anonymous":[null,"Semi anônimo"],"Temporary room":[null,"Sala temporária"],Unmoderated:[null,"Sem moderação"],Rooms:[null,"Salas"],"Room name":[null,"Nome da sala"],Nickname:[null,"Apelido"],Server:[null,"Server"],Join:[null,"Entrar"],"Show rooms":[null,"Mostar salas"],"No rooms on %1$s":[null,"Sem salas em %1$s"],"Rooms on %1$s":[null,"Salas em %1$s"],"Set chatroom topic":[null,"Definir tópico do chat"],"Kick user from chatroom":[null,"Expulsar usuário do chat"],"Ban user from chatroom":[null,"Banir usuário do chat"],Message:[null,"Mensagem"],Save:[null,"Salvar"],Cancel:[null,"Cancelar"],"An error occurred while trying to save the form.":[null,"Ocorreu um erro enquanto tentava salvar o formulário"],"This chatroom requires a password":[null,"Esse chat precisa de senha"],"Password: ":[null,"Senha: "],Submit:[null,"Enviar"],"This room is not anonymous":[null,"Essa sala não é anônima"],"This room now shows unavailable members":[null,"Agora esta sala mostra membros indisponíveis"],"This room does not show unavailable members":[null,"Essa sala não mostra membros indisponíveis"],"Non-privacy-related room configuration has changed":[null,"Configuraçõs não relacionadas à privacidade mudaram"],"Room logging is now enabled":[null,"O log da sala está ativado"],"Room logging is now disabled":[null,"O log da sala está desativado"],"This room is now non-anonymous":[null,"Esse sala é não anônima"],"This room is now semi-anonymous":[null,"Essa sala agora é semi anônima"],"This room is now fully-anonymous":[null,"Essa sala agora é totalmente anônima"],"A new room has been created":[null,"Uma nova sala foi criada"],"Your nickname has been changed":[null,"Seu apelido foi mudado"],"<strong>%1$s</strong> has been banned":[null,"<strong>%1$s</strong> foi banido"],"<strong>%1$s</strong> has been kicked out":[null,"<strong>%1$s</strong> foi expulso"],"<strong>%1$s</strong> has been removed because of an affiliation change":[null,"<srtong>%1$s</strong> foi removido por causa de troca de associação"],"<strong>%1$s</strong> has been removed for not being a member":[null,"<strong>%1$s</strong> foi removido por não ser um membro"],"You have been banned from this room":[null,"Você foi banido dessa sala"],"You have been kicked from this room":[null,"Você foi expulso dessa sala"],"You have been removed from this room because of an affiliation change":[null,"Você foi removido da sala devido a uma mudança de associação"],"You have been removed from this room because the room has changed to members-only and you're not a member":[null,"Você foi removido da sala porque ela foi mudada para somente membrose você não é um membro"],"You have been removed from this room because the MUC (Multi-user chat) service is being shut down.":[null,"Você foi removido da sala devido a MUC (Multi-user chat)o serviço está sendo desligado"],"You are not on the member list of this room":[null,"Você não é membro dessa sala"],"No nickname was specified":[null,"Você não escolheu um apelido "],"You are not allowed to create new rooms":[null,"Você não tem permitição de criar novas salas"],"Your nickname doesn't conform to this room's policies":[null,"Seu apelido não está de acordo com as regras da sala"],"Your nickname is already taken":[null,"Seu apelido já foi escolhido"],"This room does not (yet) exist":[null,"A sala não existe (ainda)"],"This room has reached it's maximum number of occupants":[null,"A sala atingiu o número máximo de ocupantes"],"Topic set by %1$s to: %2$s":[null,"Topico definido por %1$s para: %2$s"],"This user is a moderator":[null,"Esse usuário é o moderador"],"This user can send messages in this room":[null,"Esse usuário pode enviar mensagens nessa sala"],"This user can NOT send messages in this room":[null,"Esse usuário NÃO pode enviar mensagens nessa sala"],"Click to chat with this contact":[null,"Clique para conversar com o contato"],"Click to remove this contact":[null,"Clique para remover o contato"],"This contact is busy":[null,"Este contato está ocupado"],"This contact is online":[null,"Este contato está online"],"This contact is offline":[null,"Este contato está offline"],"This contact is unavailable":[null,"Este contato está indisponível"],"This contact is away for an extended period":[null,"Este contato está ausente por um longo período"],"This contact is away":[null,"Este contato está ausente"],"Contact requests":[null,"Solicitação de contatos"],"My contacts":[null,"Meus contatos"],"Pending contacts":[null,"Contados pendentes"],"Custom status":[null,"Status customizado"],"Click to change your chat status":[null,"Clique para mudar seu status no chat"],"Click here to write a custom status message":[null,"Clique aqui para customizar a mensagem de status"],online:[null,"online"],busy:[null,"ocupado"],"away for long":[null,"ausente a bastante tempo"],away:[null,"ausente"],"I am %1$s":[null,"Estou %1$s"],"Sign in":[null,"Conectar-se"],"XMPP/Jabber Username:":[null,"Usuário XMPP/Jabber:"],"Password:":[null,"Senha:"],"Log In":[null,"Entrar"],"BOSH Service URL:":[null,"URL de serviço BOSH:"],"Online Contacts":[null,"Contatos online"],"%1$s is typing":[null,"%1$s está digitando"],Connected:[null,"Conectado"],Attached:[null,"Anexado"]}}};typeof define=="function"&&define.amd?define("pt_BR",["jed"],function(){return t(new Jed(n))}):(window.locales||(window.locales={}),window.locales.pt_BR=t(new Jed(n)))}(this,function(e){return e}),function(e,t){var n={domain:"converse",locale_data:{converse:{"":{"Project-Id-Version":"Converse.js 0.4","Report-Msgid-Bugs-To":"","POT-Creation-Date":"2013-09-15 22:06+0200","PO-Revision-Date":"2013-09-29 17:24+0300","Last-Translator":"Boris Kocherov <bk@raskon.org>","Language-Team":"<bk@raskon.ru>",Language:"ru","MIME-Version":"1.0","Content-Type":"text/plain; charset=UTF-8","Content-Transfer-Encoding":"8bit","X-Generator":"Poedit 1.5.5"},unencrypted:[null,"не зашифровано"],unverified:[null,"непроверено"],verified:[null,"проверено"],finished:[null,"закончено"],Disconnected:[null,"Отключено"],Error:[null,"Ошибка"],Connecting:[null,"Соединение"],"Connection Failed":[null,"Не удалось соединится"],Authenticating:[null,"Авторизация"],"Authentication Failed":[null,"Не удалось авторизоваться"],Disconnecting:[null,"Отключаемся"],"Private key generated.":[null,"Приватный ключ сгенерирован."],"Personal message":[null,"Введите сообщение"],"What's this?":[null,"Что это?"],me:[null,"Я"],"Show this menu":[null,"Показать это меню"],"Remove messages":[null,"Удалить сообщения"],"Your message could not be sent":[null,"Ваше сообщение не послано"],"Your messages are not encrypted anymore":[null,"Ваши сообщения больше не шифруются"],"Your messages are now encrypted but your buddy's identity has not been verified.":[null,"Ваши сообщения шифруются, но ваша учётная запись не проверена вашим собеседником."],"Your buddy's identify has been verified.":[null,"Ваша учётная запись проверена вашим собеседником."],"Your messages are not encrypted. Click here to enable OTR encryption.":[null,"Ваши сообщения не шифруются. Нажмите здесь чтобы настроить шифрование."],"Your messages are encrypted, but your buddy has not been verified.":[null,"Ваши сообщения шифруются, но ваш контакт не проверен."],"Your messages are encrypted and your buddy verified.":[null,"Ваши сообщения шифруются и ваш контакт проверен"],Contacts:[null,"Контакты"],Online:[null,"В сети"],Busy:[null,"Занят"],Away:[null,"Отошёл"],Offline:[null,"Не в сети"],"Click to add new chat contacts":[null,"Добавить новую конференцию"],"Add a contact":[null,"Добавть контакт"],"Contact username":[null,"Имя пользователя"],Add:[null,"Добавить"],"Contact name":[null,"Имя контакта"],Search:[null,"Поиск"],"No users found":[null,"Пользователи не найдены"],"Click to add as a chat contact":[null,"Добавить контакт"],"Click to open this room":[null,"Зайти в конференцию"],"Show more information on this room":[null,"Показать больше информации об этой конференции"],"Description:":[null,"Описание:"],"Occupants:":[null,"Участники:"],"Features:":[null,"Свойства:"],"Requires authentication":[null,"Требуется авторизация"],Hidden:[null,"Скрыто"],"Requires an invitation":[null,"Требуется приглашение"],Moderated:[null,"Модерируемая"],"Non-anonymous":[null,"Не анонимная"],"Open room":[null,"Открыть конференцию"],"Permanent room":[null,"Перманентная конференция"],Public:[null,"Публичный"],"Semi-anonymous":[null,"Частично анонимная"],"Temporary room":[null,"Временная конференция"],Unmoderated:[null,"Немодерируемая"],Rooms:[null,"Конфер."],"Room name":[null,"Имя конференции"],Nickname:[null,"Псевдоним"],Server:[null,"Сервер"],Join:[null,"Подключиться"],"Show rooms":[null,"Обновить"],"No rooms on %1$s":[null,"Нет доступных конференций %1$s"],"Rooms on %1$s":[null,"Конференции %1$s:"],"Set chatroom topic":[null,"Установить тему"],"Kick user from chatroom":[null,"Отключить пользователя от кнофер."],"Ban user from chatroom":[null,"Забанить пользователя в этой конф."],Message:[null,"Сообщение"],Save:[null,"Сохранить"],Cancel:[null,"Отменить"],"An error occurred while trying to save the form.":[null,"При сохранение формы произошла ошибка."],"This chatroom requires a password":[null,"Для доступа в конфер. необходим пароль."],"Password: ":[null,"Пароль: "],Submit:[null,"Отправить"],"This room is not anonymous":[null,"Эта комната не анонимная"],"This room now shows unavailable members":[null,"Эта комната показывает доступных собеседников"],"This room does not show unavailable members":[null,"Эта комната не показывает недоступных собеседников"],"This room is now non-anonymous":[null,"Эта комната не анонимная"],"This room is now semi-anonymous":[null,"Эта комната частично анонимная"],"This room is now fully-anonymous":[null,"Эта комната стала полностью анонимной"],"A new room has been created":[null,"Новая комната была создана"],"Your nickname has been changed":[null,"Ваш псевдоним уже используется другим пользователем"],"<strong>%1$s</strong> has been banned":[null,"<strong>%1$s</strong> забанен"],"<strong>%1$s</strong> has been kicked out":[null,"<strong>%1$s</strong> выдворен"],"<strong>%1$s</strong> has been removed because of an affiliation change":[null,"<strong>%1$s</strong> has been removed because of an affiliation change"],"<strong>%1$s</strong> has been removed for not being a member":[null,"<strong>%1$s</strong> удалён потому что не участник"],"You have been banned from this room":[null,"Вам запрещено подключатся к этой конференции"],"You have been kicked from this room":[null,"Вам запрещено подключатся к этой конференции"],"You have been removed from this room because of an affiliation change":[null,"<strong>%1$s</strong> удалён потому что изменились права"],"You have been removed from this room because the room has changed to members-only and you're not a member":[null,"Вы отключены от этой конференции потому что режим изменился: только-участники"],"You have been removed from this room because the MUC (Multi-user chat) service is being shut down.":[null,"Вы отключены от этой конференции потому что сервись конференций выключен."],"You are not on the member list of this room":[null,"Вас нет в списке этой конференции"],"No nickname was specified":[null,"Вы не указали псевдоним"],"You are not allowed to create new rooms":[null,"Вы не имеете права создавать конфер."],"Your nickname doesn't conform to this room's policies":[null,"Псевдоним не согласуется с правилами конфер."],"Your nickname is already taken":[null,"Ваш ник уже используется другим пользователем"],"This room does not (yet) exist":[null,"Эта комната не существует"],"This room has reached it's maximum number of occupants":[null,"Конференция достигла максимального количества участников"],"Topic set by %1$s to: %2$s":[null,"Тема %2$s устатновлена %1$s"],"This user is a moderator":[null,"Модератор"],"This user can send messages in this room":[null,"Собеседник"],"This user can NOT send messages in this room":[null,"Пользователь не может посылать сообщения в эту комнату"],"Click to chat with this contact":[null,"Начать общение"],"Click to remove this contact":[null,"Удалить контакт"],"This contact is busy":[null,"Занят"],"This contact is online":[null,"В сети"],"This contact is offline":[null,"Не в сети"],"This contact is unavailable":[null,"Не доступен"],"This contact is away for an extended period":[null,"На долго отошёл"],"This contact is away":[null,"Отошёл"],"Contact requests":[null,"Запросы на авторизацию"],"My contacts":[null,"Контакты"],"Pending contacts":[null,"Собеседники ожидающие авторизации"],"Custom status":[null,"Произвольный статус"],"Click to change your chat status":[null,"Изменить ваш статус"],"Click here to write a custom status message":[null,"Редактировать произвольный статус"],online:[null,"на связи"],busy:[null,"занят"],"away for long":[null,"отошёл на долго"],away:[null,"отошёл"],"I am %1$s":[null,"%1$s"],"Sign in":[null,"Подписать"],"XMPP/Jabber Username:":[null,"JID:"],"Password:":[null,"Пароль:"],"Log In":[null,"Войти"],"Online Contacts":[null,"Cписок собеседников"]}}};typeof define=="function"&&define.amd?define("ru",["jed"],function(){return t(new Jed(n))}):(window.locales||(window.locales={}),window.locales.ru=t(new Jed(n)))}(this,function(e){return e}),function(e,t){require.config({paths:{jed:"components/jed/jed",af:"locale/af/LC_MESSAGES/af",de:"locale/de/LC_MESSAGES/de",en:"locale/en/LC_MESSAGES/en",es:"locale/es/LC_MESSAGES/es",fr:"locale/fr/LC_MESSAGES/fr",he:"locale/he/LC_MESSAGES/he",hu:"locale/hu/LC_MESSAGES/hu",id:"locale/id/LC_MESSAGES/id",it:"locale/it/LC_MESSAGES/it",ja:"locale/ja/LC_MESSAGES/ja",nl:"locale/nl/LC_MESSAGES/nl",pt_BR:"locale/pt_BR/LC_MESSAGES/pt_BR",ru:"locale/ru/LC_MESSAGES/ru"}}),define("locales",["jed","af","de","en","es","fr","he","hu","id","it","ja","nl","pt_BR","ru"],function(t,n,r,i,s,o,u,a,f,l,c,h,p,d){e.locales={af:n,de:r,en:i,es:s,fr:o,he:u,hu:a,id:f,it:l,ja:c,nl:h,"pt-br":p,ru:d}})}(this),function(){var e=this,t=e._,n={},r=Array.prototype,i=Object.prototype,s=Function.prototype,o=r.push,u=r.slice,a=r.concat,f=i.toString,l=i.hasOwnProperty,c=r.forEach,h=r.map,p=r.reduce,d=r.reduceRight,v=r.filter,m=r.every,g=r.some,y=r.indexOf,b=r.lastIndexOf,w=Array.isArray,E=Object.keys,S=s.bind,x=function(e){if(e instanceof x)return e;if(!(this instanceof x))return new x(e);this._wrapped=e};typeof exports!="undefined"?(typeof module!="undefined"&&module.exports&&(exports=module.exports=x),exports._=x):e._=x,x.VERSION="1.5.1";var T=x.each=x.forEach=function(e,t,r){if(e==null)return;if(c&&e.forEach===c)e.forEach(t,r);else if(e.length===+e.length){for(var i=0,s=e.length;i<s;i++)if(t.call(r,e[i],i,e)===n)return}else for(var o in e)if(x.has(e,o)&&t.call(r,e[o],o,e)===n)return};x.map=x.collect=function(e,t,n){var r=[];return e==null?r:h&&e.map===h?e.map(t,n):(T(e,function(e,i,s){r.push(t.call(n,e,i,s))}),r)};var N="Reduce of empty array with no initial value";x.reduce=x.foldl=x.inject=function(e,t,n,r){var i=arguments.length>2;e==null&&(e=[]);if(p&&e.reduce===p)return r&&(t=x.bind(t,r)),i?e.reduce(t,n):e.reduce(t);T(e,function(e,s,o){i?n=t.call(r,n,e,s,o):(n=e,i=!0)});if(!i)throw new TypeError(N);return n},x.reduceRight=x.foldr=function(e,t,n,r){var i=arguments.length>2;e==null&&(e=[]);if(d&&e.reduceRight===d)return r&&(t=x.bind(t,r)),i?e.reduceRight(t,n):e.reduceRight(t);var s=e.length;if(s!==+s){var o=x.keys(e);s=o.length}T(e,function(u,a,f){a=o?o[--s]:--s,i?n=t.call(r,n,e[a],a,f):(n=e[a],i=!0)});if(!i)throw new TypeError(N);return n},x.find=x.detect=function(e,t,n){var r;return C(e,function(e,i,s){if(t.call(n,e,i,s))return r=e,!0}),r},x.filter=x.select=function(e,t,n){var r=[];return e==null?r:v&&e.filter===v?e.filter(t,n):(T(e,function(e,i,s){t.call(n,e,i,s)&&r.push(e)}),r)},x.reject=function(e,t,n){return x.filter(e,function(e,r,i){return!t.call(n,e,r,i)},n)},x.every=x.all=function(e,t,r){t||(t=x.identity);var i=!0;return e==null?i:m&&e.every===m?e.every(t,r):(T(e,function(e,s,o){if(!(i=i&&t.call(r,e,s,o)))return n}),!!i)};var C=x.some=x.any=function(e,t,r){t||(t=x.identity);var i=!1;return e==null?i:g&&e.some===g?e.some(t,r):(T(e,function(e,s,o){if(i||(i=t.call(r,e,s,o)))return n}),!!i)};x.contains=x.include=function(e,t){return e==null?!1:y&&e.indexOf===y?e.indexOf(t)!=-1:C(e,function(e){return e===t})},x.invoke=function(e,t){var n=u.call(arguments,2),r=x.isFunction(t);return x.map(e,function(e){return(r?t:e[t]).apply(e,n)})},x.pluck=function(e,t){return x.map(e,function(e){return e[t]})},x.where=function(e,t,n){return x.isEmpty(t)?n?void 0:[]:x[n?"find":"filter"](e,function(e){for(var n in t)if(t[n]!==e[n])return!1;return!0})},x.findWhere=function(e,t){return x.where(e,t,!0)},x.max=function(e,t,n){if(!t&&x.isArray(e)&&e[0]===+e[0]&&e.length<65535)return Math.max.apply(Math,e);if(!t&&x.isEmpty(e))return-Infinity;var r={computed:-Infinity,value:-Infinity};return T(e,function(e,i,s){var o=t?t.call(n,e,i,s):e;o>r.computed&&(r={value:e,computed:o})}),r.value},x.min=function(e,t,n){if(!t&&x.isArray(e)&&e[0]===+e[0]&&e.length<65535)return Math.min.apply(Math,e);if(!t&&x.isEmpty(e))return Infinity;var r={computed:Infinity,value:Infinity};return T(e,function(e,i,s){var o=t?t.call(n,e,i,s):e;o<r.computed&&(r={value:e,computed:o})}),r.value},x.shuffle=function(e){var t,n=0,r=[];return T(e,function(e){t=x.random(n++),r[n-1]=r[t],r[t]=e}),r};var k=function(e){return x.isFunction(e)?e:function(t){return t[e]}};x.sortBy=function(e,t,n){var r=k(t);return x.pluck(x.map(e,function(e,t,i){return{value:e,index:t,criteria:r.call(n,e,t,i)}}).sort(function(e,t){var n=e.criteria,r=t.criteria;if(n!==r){if(n>r||n===void 0)return 1;if(n<r||r===void 0)return-1}return e.index<t.index?-1:1}),"value")};var L=function(e,t,n,r){var i={},s=k(t==null?x.identity:t);return T(e,function(t,o){var u=s.call(n,t,o,e);r(i,u,t)}),i};x.groupBy=function(e,t,n){return L(e,t,n,function(e,t,n){(x.has(e,t)?e[t]:e[t]=[]).push(n)})},x.countBy=function(e,t,n){return L(e,t,n,function(e,t){x.has(e,t)||(e[t]=0),e[t]++})},x.sortedIndex=function(e,t,n,r){n=n==null?x.identity:k(n);var i=n.call(r,t),s=0,o=e.length;while(s<o){var u=s+o>>>1;n.call(r,e[u])<i?s=u+1:o=u}return s},x.toArray=function(e){return e?x.isArray(e)?u.call(e):e.length===+e.length?x.map(e,x.identity):x.values(e):[]},x.size=function(e){return e==null?0:e.length===+e.length?e.length:x.keys(e).length},x.first=x.head=x.take=function(e,t,n){return e==null?void 0:t!=null&&!n?u.call(e,0,t):e[0]},x.initial=function(e,t,n){return u.call(e,0,e.length-(t==null||n?1:t))},x.last=function(e,t,n){return e==null?void 0:t!=null&&!n?u.call(e,Math.max(e.length-t,0)):e[e.length-1]},x.rest=x.tail=x.drop=function(e,t,n){return u.call(e,t==null||n?1:t)},x.compact=function(e){return x.filter(e,x.identity)};var A=function(e,t,n){return t&&x.every(e,x.isArray)?a.apply(n,e):(T(e,function(e){x.isArray(e)||x.isArguments(e)?t?o.apply(n,e):A(e,t,n):n.push(e)}),n)};x.flatten=function(e,t){return A(e,t,[])},x.without=function(e){return x.difference(e,u.call(arguments,1))},x.uniq=x.unique=function(e,t,n,r){x.isFunction(t)&&(r=n,n=t,t=!1);var i=n?x.map(e,n,r):e,s=[],o=[];return T(i,function(n,r){if(t?!r||o[o.length-1]!==n:!x.contains(o,n))o.push(n),s.push(e[r])}),s},x.union=function(){return x.uniq(x.flatten(arguments,!0))},x.intersection=function(e){var t=u.call(arguments,1);return x.filter(x.uniq(e),function(e){return x.every(t,function(t){return x.indexOf(t,e)>=0})})},x.difference=function(e){var t=a.apply(r,u.call(arguments,1));return x.filter(e,function(e){return!x.contains(t,e)})},x.zip=function(){var e=x.max(x.pluck(arguments,"length").concat(0)),t=new Array(e);for(var n=0;n<e;n++)t[n]=x.pluck(arguments,""+n);return t},x.object=function(e,t){if(e==null)return{};var n={};for(var r=0,i=e.length;r<i;r++)t?n[e[r]]=t[r]:n[e[r][0]]=e[r][1];return n},x.indexOf=function(e,t,n){if(e==null)return-1;var r=0,i=e.length;if(n){if(typeof n!="number")return r=x.sortedIndex(e,t),e[r]===t?r:-1;r=n<0?Math.max(0,i+n):n}if(y&&e.indexOf===y)return e.indexOf(t,n);for(;r<i;r++)if(e[r]===t)return r;return-1},x.lastIndexOf=function(e,t,n){if(e==null)return-1;var r=n!=null;if(b&&e.lastIndexOf===b)return r?e.lastIndexOf(t,n):e.lastIndexOf(t);var i=r?n:e.length;while(i--)if(e[i]===t)return i;return-1},x.range=function(e,t,n){arguments.length<=1&&(t=e||0,e=0),n=arguments[2]||1;var r=Math.max(Math.ceil((t-e)/n),0),i=0,s=new Array(r);while(i<r)s[i++]=e,e+=n;return s};var O=function(){};x.bind=function(e,t){var n,r;if(S&&e.bind===S)return S.apply(e,u.call(arguments,1));if(!x.isFunction(e))throw new TypeError;return n=u.call(arguments,2),r=function(){if(this instanceof r){O.prototype=e.prototype;var i=new O;O.prototype=null;var s=e.apply(i,n.concat(u.call(arguments)));return Object(s)===s?s:i}return e.apply(t,n.concat(u.call(arguments)))}},x.partial=function(e){var t=u.call(arguments,1);return function(){return e.apply(this,t.concat(u.call(arguments)))}},x.bindAll=function(e){var t=u.call(arguments,1);if(t.length===0)throw new Error("bindAll must be passed function names");return T(t,function(t){e[t]=x.bind(e[t],e)}),e},x.memoize=function(e,t){var n={};return t||(t=x.identity),function(){var r=t.apply(this,arguments);return x.has(n,r)?n[r]:n[r]=e.apply(this,arguments)}},x.delay=function(e,t){var n=u.call(arguments,2);return setTimeout(function(){return e.apply(null,n)},t)},x.defer=function(e){return x.delay.apply(x,[e,1].concat(u.call(arguments,1)))},x.throttle=function(e,t,n){var r,i,s,o=null,u=0;n||(n={});var a=function(){u=n.leading===!1?0:new Date,o=null,s=e.apply(r,i)};return function(){var f=new Date;!u&&n.leading===!1&&(u=f);var l=t-(f-u);return r=this,i=arguments,l<=0?(clearTimeout(o),o=null,u=f,s=e.apply(r,i)):!o&&n.trailing!==!1&&(o=setTimeout(a,l)),s}},x.debounce=function(e,t,n){var r,i=null;return function(){var s=this,o=arguments,u=function(){i=null,n||(r=e.apply(s,o))},a=n&&!i;return clearTimeout(i),i=setTimeout(u,t),a&&(r=e.apply(s,o)),r}},x.once=function(e){var t=!1,n;return function(){return t?n:(t=!0,n=e.apply(this,arguments),e=null,n)}},x.wrap=function(e,t){return function(){var n=[e];return o.apply(n,arguments),t.apply(this,n)}},x.compose=function(){var e=arguments;return function(){var t=arguments;for(var n=e.length-1;n>=0;n--)t=[e[n].apply(this,t)];return t[0]}},x.after=function(e,t){return function(){if(--e<1)return t.apply(this,arguments)}},x.keys=E||function(e){if(e!==Object(e))throw new TypeError("Invalid object");var t=[];for(var n in e)x.has(e,n)&&t.push(n);return t},x.values=function(e){var t=[];for(var n in e)x.has(e,n)&&t.push(e[n]);return t},x.pairs=function(e){var t=[];for(var n in e)x.has(e,n)&&t.push([n,e[n]]);return t},x.invert=function(e){var t={};for(var n in e)x.has(e,n)&&(t[e[n]]=n);return t},x.functions=x.methods=function(e){var t=[];for(var n in e)x.isFunction(e[n])&&t.push(n);return t.sort()},x.extend=function(e){return T(u.call(arguments,1),function(t){if(t)for(var n in t)e[n]=t[n]}),e},x.pick=function(e){var t={},n=a.apply(r,u.call(arguments,1));return T(n,function(n){n in e&&(t[n]=e[n])}),t},x.omit=function(e){var t={},n=a.apply(r,u.call(arguments,1));for(var i in e)x.contains(n,i)||(t[i]=e[i]);return t},x.defaults=function(e){return T(u.call(arguments,1),function(t){if(t)for(var n in t)e[n]===void 0&&(e[n]=t[n])}),e},x.clone=function(e){return x.isObject(e)?x.isArray(e)?e.slice():x.extend({},e):e},x.tap=function(e,t){return t(e),e};var M=function(e,t,n,r){if(e===t)return e!==0||1/e==1/t;if(e==null||t==null)return e===t;e instanceof x&&(e=e._wrapped),t instanceof x&&(t=t._wrapped);var i=f.call(e);if(i!=f.call(t))return!1;switch(i){case"[object String]":return e==String(t);case"[object Number]":return e!=+e?t!=+t:e==0?1/e==1/t:e==+t;case"[object Date]":case"[object Boolean]":return+e==+t;case"[object RegExp]":return e.source==t.source&&e.global==t.global&&e.multiline==t.multiline&&e.ignoreCase==t.ignoreCase}if(typeof e!="object"||typeof t!="object")return!1;var s=n.length;while(s--)if(n[s]==e)return r[s]==t;var o=e.constructor,u=t.constructor;if(o!==u&&!(x.isFunction(o)&&o instanceof o&&x.isFunction(u)&&u instanceof u))return!1;n.push(e),r.push(t);var a=0,l=!0;if(i=="[object Array]"){a=e.length,l=a==t.length;if(l)while(a--)if(!(l=M(e[a],t[a],n,r)))break}else{for(var c in e)if(x.has(e,c)){a++;if(!(l=x.has(t,c)&&M(e[c],t[c],n,r)))break}if(l){for(c in t)if(x.has(t,c)&&!(a--))break;l=!a}}return n.pop(),r.pop(),l};x.isEqual=function(e,t){return M(e,t,[],[])},x.isEmpty=function(e){if(e==null)return!0;if(x.isArray(e)||x.isString(e))return e.length===0;for(var t in e)if(x.has(e,t))return!1;return!0},x.isElement=function(e){return!!e&&e.nodeType===1},x.isArray=w||function(e){return f.call(e)=="[object Array]"},x.isObject=function(e){return e===Object(e)},T(["Arguments","Function","String","Number","Date","RegExp"],function(e){x["is"+e]=function(t){return f.call(t)=="[object "+e+"]"}}),x.isArguments(arguments)||(x.isArguments=function(e){return!!e&&!!x.has(e,"callee")}),typeof /./!="function"&&(x.isFunction=function(e){return typeof e=="function"}),x.isFinite=function(e){return isFinite(e)&&!isNaN(parseFloat(e))},x.isNaN=function(e){return x.isNumber(e)&&e!=+e},x.isBoolean=function(e){return e===!0||e===!1||f.call(e)=="[object Boolean]"},x.isNull=function(e){return e===null},x.isUndefined=function(e){return e===void 0},x.has=function(e,t){return l.call(e,t)},x.noConflict=function(){return e._=t,this},x.identity=function(e){return e},x.times=function(e,t,n){var r=Array(Math.max(0,e));for(var i=0;i<e;i++)r[i]=t.call(n,i);return r},x.random=function(e,t){return t==null&&(t=e,e=0),e+Math.floor(Math.random()*(t-e+1))};var _={escape:{"&":"&","<":"<",">":">",'"':""","'":"'","/":"/"}};_.unescape=x.invert(_.escape);var D={escape:new RegExp("["+x.keys(_.escape).join("")+"]","g"),unescape:new RegExp("("+x.keys(_.unescape).join("|")+")","g")};x.each(["escape","unescape"],function(e){x[e]=function(t){return t==null?"":(""+t).replace(D[e],function(t){return _[e][t]})}}),x.result=function(e,t){if(e==null)return void 0;var n=e[t];return x.isFunction(n)?n.call(e):n},x.mixin=function(e){T(x.functions(e),function(t){var n=x[t]=e[t];x.prototype[t]=function(){var e=[this._wrapped];return o.apply(e,arguments),F.call(this,n.apply(x,e))}})};var P=0;x.uniqueId=function(e){var t=++P+"";return e?e+t:t},x.templateSettings={evaluate:/<%([\s\S]+?)%>/g,interpolate:/<%=([\s\S]+?)%>/g,escape:/<%-([\s\S]+?)%>/g};var H=/(.)^/,B={"'":"'","\\":"\\","\r":"r","\n":"n"," ":"t","\u2028":"u2028","\u2029":"u2029"},j=/\\|'|\r|\n|\t|\u2028|\u2029/g;x.template=function(e,t,n){var r;n=x.defaults({},n,x.templateSettings);var i=new RegExp([(n.escape||H).source,(n.interpolate||H).source,(n.evaluate||H).source].join("|")+"|$","g"),s=0,o="__p+='";e.replace(i,function(t,n,r,i,u){return o+=e.slice(s,u).replace(j,function(e){return"\\"+B[e]}),n&&(o+="'+\n((__t=("+n+"))==null?'':_.escape(__t))+\n'"),r&&(o+="'+\n((__t=("+r+"))==null?'':__t)+\n'"),i&&(o+="';\n"+i+"\n__p+='"),s=u+t.length,t}),o+="';\n",n.variable||(o="with(obj||{}){\n"+o+"}\n"),o="var __t,__p='',__j=Array.prototype.join,print=function(){__p+=__j.call(arguments,'');};\n"+o+"return __p;\n";try{r=new Function(n.variable||"obj","_",o)}catch(u){throw u.source=o,u}if(t)return r(t,x);var a=function(e){return r.call(this,e,x)};return a.source="function("+(n.variable||"obj")+"){\n"+o+"}",a},x.chain=function(e){return x(e).chain()};var F=function(e){return this._chain?x(e).chain():e};x.mixin(x),T(["pop","push","reverse","shift","sort","splice","unshift"],function(e){var t=r[e];x.prototype[e]=function(){var n=this._wrapped;return t.apply(n,arguments),(e=="shift"||e=="splice")&&n.length===0&&delete n[0],F.call(this,n)}}),T(["concat","join","slice"],function(e){var t=r[e];x.prototype[e]=function(){return F.call(this,t.apply(this._wrapped,arguments))}}),x.extend(x.prototype,{chain:function(){return this._chain=!0,this},value:function(){return this._wrapped}})}.call(this),define("underscore",function(){}),function(){var e=this,t=e.Backbone,n=[],r=n.push,i=n.slice,s=n.splice,o;typeof exports!="undefined"?o=exports:o=e.Backbone={},o.VERSION="1.0.0";var u=e._;!u&&typeof require!="undefined"&&(u=require("underscore")),o.$=e.jQuery||e.Zepto||e.ender||e.$,o.noConflict=function(){return e.Backbone=t,this},o.emulateHTTP=!1,o.emulateJSON=!1;var a=o.Events={on:function(e,t,n){if(!l(this,"on",e,[t,n])||!t)return this;this._events||(this._events={});var r=this._events[e]||(this._events[e]=[]);return r.push({callback:t,context:n,ctx:n||this}),this},once:function(e,t,n){if(!l(this,"once",e,[t,n])||!t)return this;var r=this,i=u.once(function(){r.off(e,i),t.apply(this,arguments)});return i._callback=t,this.on(e,i,n)},off:function(e,t,n){var r,i,s,o,a,f,c,h;if(!this._events||!l(this,"off",e,[t,n]))return this;if(!e&&!t&&!n)return this._events={},this;o=e?[e]:u.keys(this._events);for(a=0,f=o.length;a<f;a++){e=o[a];if(s=this._events[e]){this._events[e]=r=[];if(t||n)for(c=0,h=s.length;c<h;c++)i=s[c],(t&&t!==i.callback&&t!==i.callback._callback||n&&n!==i.context)&&r.push(i);r.length||delete this._events[e]}}return this},trigger:function(e){if(!this._events)return this;var t=i.call(arguments,1);if(!l(this,"trigger",e,t))return this;var n=this._events[e],r=this._events.all;return n&&c(n,t),r&&c(r,arguments),this},stopListening:function(e,t,n){var r=this._listeners;if(!r)return this;var i=!t&&!n;typeof t=="object"&&(n=this),e&&((r={})[e._listenerId]=e);for(var s in r)r[s].off(t,n,this),i&&delete this._listeners[s];return this}},f=/\s+/,l=function(e,t,n,r){if(!n)return!0;if(typeof n=="object"){for(var i in n)e[t].apply(e,[i,n[i]].concat(r));return!1}if(f.test(n)){var s=n.split(f);for(var o=0,u=s.length;o<u;o++)e[t].apply(e,[s[o]].concat(r));return!1}return!0},c=function(e,t){var n,r=-1,i=e.length,s=t[0],o=t[1],u=t[2];switch(t.length){case 0:while(++r<i)(n=e[r]).callback.call(n.ctx);return;case 1:while(++r<i)(n=e[r]).callback.call(n.ctx,s);return;case 2:while(++r<i)(n=e[r]).callback.call(n.ctx,s,o);return;case 3:while(++r<i)(n=e[r]).callback.call(n.ctx,s,o,u);return;default:while(++r<i)(n=e[r]).callback.apply(n.ctx,t)}},h={listenTo:"on",listenToOnce:"once"};u.each(h,function(e,t){a[t]=function(t,n,r){var i=this._listeners||(this._listeners={}),s=t._listenerId||(t._listenerId=u.uniqueId("l"));return i[s]=t,typeof n=="object"&&(r=this),t[e](n,r,this),this}}),a.bind=a.on,a.unbind=a.off,u.extend(o,a);var p=o.Model=function(e,t){var n,r=e||{};t||(t={}),this.cid=u.uniqueId("c"),this.attributes={},u.extend(this,u.pick(t,d)),t.parse&&(r=this.parse(r,t)||{});if(n=u.result(this,"defaults"))r=u.defaults({},r,n);this.set(r,t),this.changed={},this.initialize.apply(this,arguments)},d=["url","urlRoot","collection"];u.extend(p.prototype,a,{changed:null,validationError:null,idAttribute:"id",initialize:function(){},toJSON:function(e){return u.clone(this.attributes)},sync:function(){return o.sync.apply(this,arguments)},get:function(e){return this.attributes[e]},escape:function(e){return u.escape(this.get(e))},has:function(e){return this.get(e)!=null},set:function(e,t,n){var r,i,s,o,a,f,l,c;if(e==null)return this;typeof e=="object"?(i=e,n=t):(i={})[e]=t,n||(n={});if(!this._validate(i,n))return!1;s=n.unset,a=n.silent,o=[],f=this._changing,this._changing=!0,f||(this._previousAttributes=u.clone(this.attributes),this.changed={}),c=this.attributes,l=this._previousAttributes,this.idAttribute in i&&(this.id=i[this.idAttribute]);for(r in i)t=i[r],u.isEqual(c[r],t)||o.push(r),u.isEqual(l[r],t)?delete this.changed[r]:this.changed[r]=t,s?delete c[r]:c[r]=t;if(!a){o.length&&(this._pending=!0);for(var h=0,p=o.length;h<p;h++)this.trigger("change:"+o[h],this,c[o[h]],n)}if(f)return this;if(!a)while(this._pending)this._pending=!1,this.trigger("change",this,n);return this._pending=!1,this._changing=!1,this},unset:function(e,t){return this.set(e,void 0,u.extend({},t,{unset:!0}))},clear:function(e){var t={};for(var n in this.attributes)t[n]=void 0;return this.set(t,u.extend({},e,{unset:!0}))},hasChanged:function(e){return e==null?!u.isEmpty(this.changed):u.has(this.changed,e)},changedAttributes:function(e){if(!e)return this.hasChanged()?u.clone(this.changed):!1;var t,n=!1,r=this._changing?this._previousAttributes:this.attributes;for(var i in e){if(u.isEqual(r[i],t=e[i]))continue;(n||(n={}))[i]=t}return n},previous:function(e){return e==null||!this._previousAttributes?null:this._previousAttributes[e]},previousAttributes:function(){return u.clone(this._previousAttributes)},fetch:function(e){e=e?u.clone(e):{},e.parse===void 0&&(e.parse=!0);var t=this,n=e.success;return e.success=function(r){if(!t.set(t.parse(r,e),e))return!1;n&&n(t,r,e),t.trigger("sync",t,r,e)},j(this,e),this.sync("read",this,e)},save:function(e,t,n){var r,i,s,o=this.attributes;e==null||typeof e=="object"?(r=e,n=t):(r={})[e]=t;if(r&&(!n||!n.wait)&&!this.set(r,n))return!1;n=u.extend({validate:!0},n);if(!this._validate(r,n))return!1;r&&n.wait&&(this.attributes=u.extend({},o,r)),n.parse===void 0&&(n.parse=!0);var a=this,f=n.success;return n.success=function(e){a.attributes=o;var t=a.parse(e,n);n.wait&&(t=u.extend(r||{},t));if(u.isObject(t)&&!a.set(t,n))return!1;f&&f(a,e,n),a.trigger("sync",a,e,n)},j(this,n),i=this.isNew()?"create":n.patch?"patch":"update",i==="patch"&&(n.attrs=r),s=this.sync(i,this,n),r&&n.wait&&(this.attributes=o),s},destroy:function(e){e=e?u.clone(e):{};var t=this,n=e.success,r=function(){t.trigger("destroy",t,t.collection,e)};e.success=function(i){(e.wait||t.isNew())&&r(),n&&n(t,i,e),t.isNew()||t.trigger("sync",t,i,e)};if(this.isNew())return e.success(),!1;j(this,e);var i=this.sync("delete",this,e);return e.wait||r(),i},url:function(){var e=u.result(this,"urlRoot")||u.result(this.collection,"url")||B();return this.isNew()?e:e+(e.charAt(e.length-1)==="/"?"":"/")+encodeURIComponent(this.id)},parse:function(e,t){return e},clone:function(){return new this.constructor(this.attributes)},isNew:function(){return this.id==null},isValid:function(e){return this._validate({},u.extend(e||{},{validate:!0}))},_validate:function(e,t){if(!t.validate||!this.validate)return!0;e=u.extend({},this.attributes,e);var n=this.validationError=this.validate(e,t)||null;return n?(this.trigger("invalid",this,n,u.extend(t||{},{validationError:n})),!1):!0}});var v=["keys","values","pairs","invert","pick","omit"];u.each(v,function(e){p.prototype[e]=function(){var t=i.call(arguments);return t.unshift(this.attributes),u[e].apply(u,t)}});var m=o.Collection=function(e,t){t||(t={}),t.url&&(this.url=t.url),t.model&&(this.model=t.model),t.comparator!==void 0&&(this.comparator=t.comparator),this._reset(),this.initialize.apply(this,arguments),e&&this.reset(e,u.extend({silent:!0},t))},g={add:!0,remove:!0,merge:!0},y={add:!0,merge:!1,remove:!1};u.extend(m.prototype,a,{model:p,initialize:function(){},toJSON:function(e){return this.map(function(t){return t.toJSON(e)})},sync:function(){return o.sync.apply(this,arguments)},add:function(e,t){return this.set(e,u.defaults(t||{},y))},remove:function(e,t){e=u.isArray(e)?e.slice():[e],t||(t={});var n,r,i,s;for(n=0,r=e.length;n<r;n++){s=this.get(e[n]);if(!s)continue;delete this._byId[s.id],delete this._byId[s.cid],i=this.indexOf(s),this.models.splice(i,1),this.length--,t.silent||(t.index=i,s.trigger("remove",s,this,t)),this._removeReference(s)}return this},set:function(e,t){t=u.defaults(t||{},g),t.parse&&(e=this.parse(e,t)),u.isArray(e)||(e=e?[e]:[]);var n,i,o,a,f,l,c=t.at,h=this.comparator&&c==null&&t.sort!==!1,p=u.isString(this.comparator)?this.comparator:null,d=[],v=[],m={};for(n=0,i=e.length;n<i;n++){if(!(o=this._prepareModel(e[n],t)))continue;(f=this.get(o))?(t.remove&&(m[f.cid]=!0),t.merge&&(f.set(o.attributes,t),h&&!l&&f.hasChanged(p)&&(l=!0))):t.add&&(d.push(o),o.on("all",this._onModelEvent,this),this._byId[o.cid]=o,o.id!=null&&(this._byId[o.id]=o))}if(t.remove){for(n=0,i=this.length;n<i;++n)m[(o=this.models[n]).cid]||v.push(o);v.length&&this.remove(v,t)}d.length&&(h&&(l=!0),this.length+=d.length,c!=null?s.apply(this.models,[c,0].concat(d)):r.apply(this.models,d)),l&&this.sort({silent:!0});if(t.silent)return this;for(n=0,i=d.length;n<i;n++)(o=d[n]).trigger("add",o,this,t);return l&&this.trigger("sort",this,t),this},reset:function(e,t){t||(t={});for(var n=0,r=this.models.length;n<r;n++)this._removeReference(this.models[n]);return t.previousModels=this.models,this._reset(),this.add(e,u.extend({silent:!0},t)),t.silent||this.trigger("reset",this,t),this},push:function(e,t){return e=this._prepareModel(e,t),this.add(e,u.extend({at:this.length},t)),e},pop:function(e){var t=this.at(this.length-1);return this.remove(t,e),t},unshift:function(e,t){return e=this._prepareModel(e,t),this.add(e,u.extend({at:0},t)),e},shift:function(e){var t=this.at(0);return this.remove(t,e),t},slice:function(e,t){return this.models.slice(e,t)},get:function(e){return e==null?void 0:this._byId[e.id!=null?e.id:e.cid||e]},at:function(e){return this.models[e]},where:function(e,t){return u.isEmpty(e)?t?void 0:[]:this[t?"find":"filter"](function(t){for(var n in e)if(e[n]!==t.get(n))return!1;return!0})},findWhere:function(e){return this.where(e,!0)},sort:function(e){if(!this.comparator)throw new Error("Cannot sort a set without a comparator");return e||(e={}),u.isString(this.comparator)||this.comparator.length===1?this.models=this.sortBy(this.comparator,this):this.models.sort(u.bind(this.comparator,this)),e.silent||this.trigger("sort",this,e),this},sortedIndex:function(e,t,n){t||(t=this.comparator);var r=u.isFunction(t)?t:function(e){return e.get(t)};return u.sortedIndex(this.models,e,r,n)},pluck:function(e){return u.invoke(this.models,"get",e)},fetch:function(e){e=e?u.clone(e):{},e.parse===void 0&&(e.parse=!0);var t=e.success,n=this;return e.success=function(r){var i=e.reset?"reset":"set";n[i](r,e),t&&t(n,r,e),n.trigger("sync",n,r,e)},j(this,e),this.sync("read",this,e)},create:function(e,t){t=t?u.clone(t):{};if(!(e=this._prepareModel(e,t)))return!1;t.wait||this.add(e,t);var n=this,r=t.success;return t.success=function(i){t.wait&&n.add(e,t),r&&r(e,i,t)},e.save(null,t),e},parse:function(e,t){return e},clone:function(){return new this.constructor(this.models)},_reset:function(){this.length=0,this.models=[],this._byId={}},_prepareModel:function(e,t){if(e instanceof p)return e.collection||(e.collection=this),e;t||(t={}),t.collection=this;var n=new this.model(e,t);return n._validate(e,t)?n:(this.trigger("invalid",this,e,t),!1)},_removeReference:function(e){this===e.collection&&delete e.collection,e.off("all",this._onModelEvent,this)},_onModelEvent:function(e,t,n,r){if((e==="add"||e==="remove")&&n!==this)return;e==="destroy"&&this.remove(t,r),t&&e==="change:"+t.idAttribute&&(delete this._byId[t.previous(t.idAttribute)],t.id!=null&&(this._byId[t.id]=t)),this.trigger.apply(this,arguments)}});var b=["forEach","each","map","collect","reduce","foldl","inject","reduceRight","foldr","find","detect","filter","select","reject","every","all","some","any","include","contains","invoke","max","min","toArray","size","first","head","take","initial","rest","tail","drop","last","without","indexOf","shuffle","lastIndexOf","isEmpty","chain"];u.each(b,function(e){m.prototype[e]=function(){var t=i.call(arguments);return t.unshift(this.models),u[e].apply(u,t)}});var w=["groupBy","countBy","sortBy"];u.each(w,function(e){m.prototype[e]=function(t,n){var r=u.isFunction(t)?t:function(e){return e.get(t)};return u[e](this.models,r,n)}});var E=o.View=function(e){this.cid=u.uniqueId("view"),this._configure(e||{}),this._ensureElement(),this.initialize.apply(this,arguments),this.delegateEvents()},S=/^(\S+)\s*(.*)$/,x=["model","collection","el","id","attributes","className","tagName","events"];u.extend(E.prototype,a,{tagName:"div",$:function(e){return this.$el.find(e)},initialize:function(){},render:function(){return this},remove:function(){return this.$el.remove(),this.stopListening(),this},setElement:function(e,t){return this.$el&&this.undelegateEvents(),this.$el=e instanceof o.$?e:o.$(e),this.el=this.$el[0],t!==!1&&this.delegateEvents(),this},delegateEvents:function(e){if(!e&&!(e=u.result(this,"events")))return this;this.undelegateEvents();for(var t in e){var n=e[t];u.isFunction(n)||(n=this[e[t]]);if(!n)continue;var r=t.match(S),i=r[1],s=r[2];n=u.bind(n,this),i+=".delegateEvents"+this.cid,s===""?this.$el.on(i,n):this.$el.on(i,s,n)}return this},undelegateEvents:function(){return this.$el.off(".delegateEvents"+this.cid),this},_configure:function(e){this.options&&(e=u.extend({},u.result(this,"options"),e)),u.extend(this,u.pick(e,x)),this.options=e},_ensureElement:function(){if(!this.el){var e=u.extend({},u.result(this,"attributes"));this.id&&(e.id=u.result(this,"id")),this.className&&(e["class"]=u.result(this,"className"));var t=o.$("<"+u.result(this,"tagName")+">").attr(e);this.setElement(t,!1)}else this.setElement(u.result(this,"el"),!1)}}),o.sync=function(e,t,n){var r=T[e];u.defaults(n||(n={}),{emulateHTTP:o.emulateHTTP,emulateJSON:o.emulateJSON});var i={type:r,dataType:"json"};n.url||(i.url=u.result(t,"url")||B()),n.data==null&&t&&(e==="create"||e==="update"||e==="patch")&&(i.contentType="application/json",i.data=JSON.stringify(n.attrs||t.toJSON(n))),n.emulateJSON&&(i.contentType="application/x-www-form-urlencoded",i.data=i.data?{model:i.data}:{});if(n.emulateHTTP&&(r==="PUT"||r==="DELETE"||r==="PATCH")){i.type="POST",n.emulateJSON&&(i.data._method=r);var s=n.beforeSend;n.beforeSend=function(e){e.setRequestHeader("X-HTTP-Method-Override",r);if(s)return s.apply(this,arguments)}}i.type!=="GET"&&!n.emulateJSON&&(i.processData=!1),i.type==="PATCH"&&window.ActiveXObject&&(!window.external||!window.external.msActiveXFilteringEnabled)&&(i.xhr=function(){return new ActiveXObject("Microsoft.XMLHTTP")});var a=n.xhr=o.ajax(u.extend(i,n));return t.trigger("request",t,a,n),a};var T={create:"POST",update:"PUT",patch:"PATCH","delete":"DELETE",read:"GET"};o.ajax=function(){return o.$.ajax.apply(o.$,arguments)};var N=o.Router=function(e){e||(e={}),e.routes&&(this.routes=e.routes),this._bindRoutes(),this.initialize.apply(this,arguments)},C=/\((.*?)\)/g,k=/(\(\?)?:\w+/g,L=/\*\w+/g,A=/[\-{}\[\]+?.,\\\^$|#\s]/g;u.extend(N.prototype,a,{initialize:function(){},route:function(e,t,n){u.isRegExp(e)||(e=this._routeToRegExp(e)),u.isFunction(t)&&(n=t,t=""),n||(n=this[t]);var r=this;return o.history.route(e,function(i){var s=r._extractParameters(e,i);n&&n.apply(r,s),r.trigger.apply(r,["route:"+t].concat(s)),r.trigger("route",t,s),o.history.trigger("route",r,t,s)}),this},navigate:function(e,t){return o.history.navigate(e,t),this},_bindRoutes:function(){if(!this.routes)return;this.routes=u.result(this,"routes");var e,t=u.keys(this.routes);while((e=t.pop())!=null)this.route(e,this.routes[e])},_routeToRegExp:function(e){return e=e.replace(A,"\\$&").replace(C,"(?:$1)?").replace(k,function(e,t){return t?e:"([^/]+)"}).replace(L,"(.*?)"),new RegExp("^"+e+"$")},_extractParameters:function(e,t){var n=e.exec(t).slice(1);return u.map(n,function(e){return e?decodeURIComponent(e):null})}});var O=o.History=function(){this.handlers=[],u.bindAll(this,"checkUrl"),typeof window!="undefined"&&(this.location=window.location,this.history=window.history)},M=/^[#\/]|\s+$/g,_=/^\/+|\/+$/g,D=/msie [\w.]+/,P=/\/$/;O.started=!1,u.extend(O.prototype,a,{interval:50,getHash:function(e){var t=(e||this).location.href.match(/#(.*)$/);return t?t[1]:""},getFragment:function(e,t){if(e==null)if(this._hasPushState||!this._wantsHashChange||t){e=this.location.pathname;var n=this.root.replace(P,"");e.indexOf(n)||(e=e.substr(n.length))}else e=this.getHash();return e.replace(M,"")},start:function(e){if(O.started)throw new Error("Backbone.history has already been started");O.started=!0,this.options=u.extend({},{root:"/"},this.options,e),this.root=this.options.root,this._wantsHashChange=this.options.hashChange!==!1,this._wantsPushState=!!this.options.pushState,this._hasPushState=!!(this.options.pushState&&this.history&&this.history.pushState);var t=this.getFragment(),n=document.documentMode,r=D.exec(navigator.userAgent.toLowerCase())&&(!n||n<=7);this.root=("/"+this.root+"/").replace(_,"/"),r&&this._wantsHashChange&&(this.iframe=o.$('<iframe src="javascript:0" tabindex="-1" />').hide().appendTo("body")[0].contentWindow,this.navigate(t)),this._hasPushState?o.$(window).on("popstate",this.checkUrl):this._wantsHashChange&&"onhashchange"in window&&!r?o.$(window).on("hashchange",this.checkUrl):this._wantsHashChange&&(this._checkUrlInterval=setInterval(this.checkUrl,this.interval)),this.fragment=t;var i=this.location,s=i.pathname.replace(/[^\/]$/,"$&/")===this.root;if(this._wantsHashChange&&this._wantsPushState&&!this._hasPushState&&!s)return this.fragment=this.getFragment(null,!0),this.location.replace(this.root+this.location.search+"#"+this.fragment),!0;this._wantsPushState&&this._hasPushState&&s&&i.hash&&(this.fragment=this.getHash().replace(M,""),this.history.replaceState({},document.title,this.root+this.fragment+i.search));if(!this.options.silent)return this.loadUrl()},stop:function(){o.$(window).off("popstate",this.checkUrl).off("hashchange",this.checkUrl),clearInterval(this._checkUrlInterval),O.started=!1},route:function(e,t){this.handlers.unshift({route:e,callback:t})},checkUrl:function(e){var t=this.getFragment();t===this.fragment&&this.iframe&&(t=this.getFragment(this.getHash(this.iframe)));if(t===this.fragment)return!1;this.iframe&&this.navigate(t),this.loadUrl()||this.loadUrl(this.getHash())},loadUrl:function(e){var t=this.fragment=this.getFragment(e),n=u.any(this.handlers,function(e){if(e.route.test(t))return e.callback(t),!0});return n},navigate:function(e,t){if(!O.started)return!1;if(!t||t===!0)t={trigger:t};e=this.getFragment(e||"");if(this.fragment===e)return;this.fragment=e;var n=this.root+e;if(this._hasPushState)this.history[t.replace?"replaceState":"pushState"]({},document.title,n);else{if(!this._wantsHashChange)return this.location.assign(n);this._updateHash(this.location,e,t.replace),this.iframe&&e!==this.getFragment(this.getHash(this.iframe))&&(t.replace||this.iframe.document.open().close(),this._updateHash(this.iframe.location,e,t.replace))}t.trigger&&this.loadUrl(e)},_updateHash:function(e,t,n){if(n){var r=e.href.replace(/(javascript:|#).*$/,"");e.replace(r+"#"+t)}else e.hash="#"+t}}),o.history=new O;var H=function(e,t){var n=this,r;e&&u.has(e,"constructor")?r=e.constructor:r=function(){return n.apply(this,arguments)},u.extend(r,n,t);var i=function(){this.constructor=r};return i.prototype=n.prototype,r.prototype=new i,e&&u.extend(r.prototype,e),r.__super__=n.prototype,r};p.extend=m.extend=N.extend=E.extend=O.extend=H;var B=function(){throw new Error('A "url" property or function must be specified')},j=function(e,t){var n=t.error;t.error=function(r){n&&n(e,r,t),e.trigger("error",e,r,t)}}}.call(this),define("backbone",function(){}),function(e,t){typeof exports=="object"&&e.require?module.exports=t(require("underscore"),require("backbone")):typeof define=="function"&&define.amd?define("backbone.localStorage",["underscore","backbone"],function(n,r){return t(n||e._,r||e.Backbone)}):t(_,Backbone)}(this,function(e,t){function n(){return((1+Math.random())*65536|0).toString(16).substring(1)}function r(){return n()+n()+"-"+n()+"-"+n()+"-"+n()+"-"+n()+n()+n()}return t.LocalStorage=window.Store=function(e){if(!this.localStorage)throw"Backbone.localStorage: Environment does not support localStorage.";this.name=e;var t=this.localStorage().getItem(this.name);this.records=t&&t.split(",")||[]},e.extend(t.LocalStorage.prototype,{save:function(){this.localStorage().setItem(this.name,this.records.join(","))},create:function(e){return e.id||(e.id=r(),e.set(e.idAttribute,e.id)),this.localStorage().setItem(this.name+"-"+e.id,JSON.stringify(e)),this.records.push(e.id.toString()),this.save(),this.find(e)},update:function(t){return this.localStorage().setItem(this.name+"-"+t.id,JSON.stringify(t)),e.include(this.records,t.id.toString())||this.records.push(t.id.toString()),this.save(),this.find(t)},find:function(e){return this.jsonData(this.localStorage().getItem(this.name+"-"+e.id))},findAll:function(){return(e.chain||e)(this.records).map(function(e){return this.jsonData(this.localStorage().getItem(this.name+"-"+e))},this).compact().value()},destroy:function(t){return t.isNew()?!1:(this.localStorage().removeItem(this.name+"-"+t.id),this.records=e.reject(this.records,function(e){return e===t.id.toString()}),this.save(),t)},localStorage:function(){return localStorage},jsonData:function(e){return e&&JSON.parse(e)},_clear:function(){var t=this.localStorage(),n=new RegExp("^"+this.name+"-");t.removeItem(this.name),(e.chain||e)(t).keys().filter(function(e){return n.test(e)}).each(function(e){t.removeItem(e)}),this.records.length=0},_storageSize:function(){return this.localStorage().length}}),t.LocalStorage.sync=window.Store.sync=t.localSync=function(e,n,r){var i=n.localStorage||n.collection.localStorage,s,o,u=t.$.Deferred&&t.$.Deferred();try{switch(e){case"read":s=n.id!=undefined?i.find(n):i.findAll();break;case"create":s=i.create(n);break;case"update":s=i.update(n);break;case"delete":s=i.destroy(n)}}catch(a){a.code===22&&i._storageSize()===0?o="Private browsing is unsupported":o=a.message}return s?(r&&r.success&&(t.VERSION==="0.9.10"?r.success(n,s,r):r.success(s)),u&&u.resolve(s)):(o=o?o:"Record Not Found",r&&r.error&&(t.VERSION==="0.9.10"?r.error(n,o,r):r.error(o)),u&&u.reject(o)),r&&r.complete&&r.complete(s),u&&u.promise()},t.ajaxSync=t.sync,t.getSyncMethod=function(e){return e.localStorage||e.collection&&e.collection.localStorage?t.localSync:t.ajaxSync},t.sync=function(e,n,r){return t.getSyncMethod(n).apply(this,[e,n,r])},t.LocalStorage}),function(e,t){function p(e){return e&&e.toLowerCase?e.toLowerCase():e}function d(e,t){for(var r=0,i=e.length;r<i;r++)if(e[r]==t)return!n;return n}var n=!1,r=null,i=parseFloat,s=Math.min,o=/(-?\d+\.?\d*)$/g,u=/(\d+\.?\d*)$/g,a=[],f=[],l=function(e){return typeof e=="string"},c=function(e,t){var n=e.length,r=n,i;while(r--)i=n-r-1,t(e[i],i)},h=Array.prototype.indexOf||function(e){var t=this.length,n=Number(arguments[1])||0;n=n<0?Math.ceil(n):Math.floor(n),n<0&&(n+=t);for(;n<t;n++)if(n in this&&this[n]===e)return n;return-1};e.tinysort={id:"TinySort",version:"1.5.6",copyright:"Copyright (c) 2008-2013 Ron Valstar",uri:"http://tinysort.sjeiti.com/",licensed:{MIT:"http://www.opensource.org/licenses/mit-license.php",GPL:"http://www.gnu.org/licenses/gpl.html"},plugin:function(){var e=function(e,t){a.push(e),f.push(t)};return e.indexOf=h,e}(),defaults:{order:"asc",attr:r,data:r,useVal:n,place:"start",returns:n,cases:n,forceStrings:n,ignoreDashes:n,sortFunction:r}},e.fn.extend({tinysort:function(){var v,m,g,y=this,b=[],w=[],E=[],S=[],x=0,T,N=[],C=[],k=function(e){c(a,function(t){t.call(t,e)})},L=function(e,t){return typeof t=="string"&&(e.cases||(t=p(t)),t=t.replace(/^\s*(.*?)\s*$/i,"$1")),t},A=function(e,t){var r=0;x!==0&&(x=0);while(r===0&&x<T){var s=S[x],a=s.oSettings,h=a.ignoreDashes?u:o;k(a);if(a.sortFunction)r=a.sortFunction(e,t);else if(a.order=="rand")r=Math.random()<.5?1:-1;else{var p=n,d=L(a,e.s[x]),v=L(a,t.s[x]);if(!a.forceStrings){var m=l(d)?d&&d.match(h):n,g=l(v)?v&&v.match(h):n;if(m&&g){var y=d.substr(0,d.length-m[0].length),b=v.substr(0,v.length-g[0].length);y==b&&(p=!n,d=i(m[0]),v=i(g[0]))}}r=s.iAsc*(d<v?-1:d>v?1:0)}c(f,function(e){r=e.call(e,p,d,v,r)}),r===0&&x++}return r};for(v=0,g=arguments.length;v<g;v++){var O=arguments[v];l(O)?N.push(O)-1>C.length&&(C.length=N.length-1):C.push(O)>N.length&&(N.length=C.length)}N.length>C.length&&(C.length=N.length),T=N.length,T===0&&(T=N.length=1,C.push({}));for(v=0,g=T;v<g;v++){var M=N[v],_=e.extend({},e.tinysort.defaults,C[v]),D=!!M&&M!=="",P=D&&M[0]===":";S.push({sFind:M,oSettings:_,bFind:D,bAttr:_.attr!==r&&_.attr!=="",bData:_.data!==r,bFilter:P,$Filter:P?y.filter(M):y,fnSort:_.sortFunction,iAsc:_.order=="asc"?1:-1})}return y.each(function(n,r){var i=e(r),s=i.parent().get(0),o,u=[];for(m=0;m<T;m++){var a=S[m],f=a.bFind?a.bFilter?a.$Filter.filter(r):i.find(a.sFind):i;u.push(a.bData?f.data(a.oSettings.data):a.bAttr?f.attr(a.oSettings.attr):a.oSettings.useVal?f.val():f.text()),o===t&&(o=f)}var l=h.call(E,s);l<0&&(l=E.push(s)-1,w[l]={s:[],n:[]}),o.length>0?w[l].s.push({s:u,e:i,n:n}):w[l].n.push({e:i,n:n})}),c(w,function(e){e.s.sort(A)}),c(w,function(e){var t=e.s,r=e.n,i=t.length,o=r.length,u=i+o,a=[],f=u,l=[0,0];switch(_.place){case"first":c(t,function(e){f=s(f,e.n)});break;case"org":c(t,function(e){a.push(e.n)});break;case"end":f=o;break;default:f=0}for(v=0;v<u;v++){var h=d(a,v)?!n:v>=f&&v<f+i,p=h?0:1,m=(h?t:r)[l[p]].e;m.parent().append(m),(h||!_.returns)&&b.push(m.get(0)),l[p]++}}),y.length=0,Array.prototype.push.apply(y,b),y}}),e.fn.TinySort=e.fn.Tinysort=e.fn.tsort=e.fn.tinysort}(jQuery),define("jquery.tinysort",function(){});var Base64=function(){var e="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",t={encode:function(t){var n="",r,i,s,o,u,a,f,l=0;do r=t.charCodeAt(l++),i=t.charCodeAt(l++),s=t.charCodeAt(l++),o=r>>2,u=(r&3)<<4|i>>4,a=(i&15)<<2|s>>6,f=s&63,isNaN(i)?a=f=64:isNaN(s)&&(f=64),n=n+e.charAt(o)+e.charAt(u)+e.charAt(a)+e.charAt(f);while(l<t.length);return n},decode:function(t){var n="",r,i,s,o,u,a,f,l=0;t=t.replace(/[^A-Za-z0-9\+\/\=]/g,"");do o=e.indexOf(t.charAt(l++)),u=e.indexOf(t.charAt(l++)),a=e.indexOf(t.charAt(l++)),f=e.indexOf(t.charAt(l++)),r=o<<2|u>>4,i=(u&15)<<4|a>>2,s=(a&3)<<6|f,n+=String.fromCharCode(r),a!=64&&(n+=String.fromCharCode(i)),f!=64&&(n+=String.fromCharCode(s));while(l<t.length);return n}};return t}(),hexcase=0,b64pad="=",chrsz=8,MD5=function(){var e=0,t="",n=8,r=function(e,t){var n=(e&65535)+(t&65535),r=(e>>16)+(t>>16)+(n>>16);return r<<16|n&65535},i=function(e,t){return e<<t|e>>>32-t},s=function(e){var t=[],r=(1<<n)-1;for(var i=0;i<e.length*n;i+=n)t[i>>5]|=(e.charCodeAt(i/n)&r)<<i%32;return t},o=function(e){var t="",r=(1<<n)-1;for(var i=0;i<e.length*32;i+=n)t+=String.fromCharCode(e[i>>5]>>>i%32&r);return t},u=function(t){var n=e?"0123456789ABCDEF":"0123456789abcdef",r="";for(var i=0;i<t.length*4;i++)r+=n.charAt(t[i>>2]>>i%4*8+4&15)+n.charAt(t[i>>2]>>i%4*8&15);return r},a=function(e){var n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",r="",i,s;for(var o=0;o<e.length*4;o+=3){i=(e[o>>2]>>8*(o%4)&255)<<16|(e[o+1>>2]>>8*((o+1)%4)&255)<<8|e[o+2>>2]>>8*((o+2)%4)&255;for(s=0;s<4;s++)o*8+s*6>e.length*32?r+=t:r+=n.charAt(i>>6*(3-s)&63)}return r},f=function(e,t,n,s,o,u){return r(i(r(r(t,e),r(s,u)),o),n)},l=function(e,t,n,r,i,s,o){return f(t&n|~t&r,e,t,i,s,o)},c=function(e,t,n,r,i,s,o){return f(t&r|n&~r,e,t,i,s,o)},h=function(e,t,n,r,i,s,o){return f(t^n^r,e,t,i,s,o)},p=function(e,t,n,r,i,s,o){return f(n^(t|~r),e,t,i,s,o)},d=function(e,t){e[t>>5]|=128<<t%32,e[(t+64>>>9<<4)+14]=t;var n=1732584193,i=-271733879,s=-1732584194,o=271733878,u,a,f,d;for(var v=0;v<e.length;v+=16)u=n,a=i,f=s,d=o,n=l(n,i,s,o,e[v+0],7,-680876936),o=l(o,n,i,s,e[v+1],12,-389564586),s=l(s,o,n,i,e[v+2],17,606105819),i=l(i,s,o,n,e[v+3],22,-1044525330),n=l(n,i,s,o,e[v+4],7,-176418897),o=l(o,n,i,s,e[v+5],12,1200080426),s=l(s,o,n,i,e[v+6],17,-1473231341),i=l(i,s,o,n,e[v+7],22,-45705983),n=l(n,i,s,o,e[v+8],7,1770035416),o=l(o,n,i,s,e[v+9],12,-1958414417),s=l(s,o,n,i,e[v+10],17,-42063),i=l(i,s,o,n,e[v+11],22,-1990404162),n=l(n,i,s,o,e[v+12],7,1804603682),o=l(o,n,i,s,e[v+13],12,-40341101),s=l(s,o,n,i,e[v+14],17,-1502002290),i=l(i,s,o,n,e[v+15],22,1236535329),n=c(n,i,s,o,e[v+1],5,-165796510),o=c(o,n,i,s,e[v+6],9,-1069501632),s=c(s,o,n,i,e[v+11],14,643717713),i=c(i,s,o,n,e[v+0],20,-373897302),n=c(n,i,s,o,e[v+5],5,-701558691),o=c(o,n,i,s,e[v+10],9,38016083),s=c(s,o,n,i,e[v+15],14,-660478335),i=c(i,s,o,n,e[v+4],20,-405537848),n=c(n,i,s,o,e[v+9],5,568446438),o=c(o,n,i,s,e[v+14],9,-1019803690),s=c(s,o,n,i,e[v+3],14,-187363961),i=c(i,s,o,n,e[v+8],20,1163531501),n=c(n,i,s,o,e[v+13],5,-1444681467),o=c(o,n,i,s,e[v+2],9,-51403784),s=c(s,o,n,i,e[v+7],14,1735328473),i=c(i,s,o,n,e[v+12],20,-1926607734),n=h(n,i,s,o,e[v+5],4,-378558),o=h(o,n,i,s,e[v+8],11,-2022574463),s=h(s,o,n,i,e[v+11],16,1839030562),i=h(i,s,o,n,e[v+14],23,-35309556),n=h(n,i,s,o,e[v+1],4,-1530992060),o=h(o,n,i,s,e[v+4],11,1272893353),s=h(s,o,n,i,e[v+7],16,-155497632),i=h(i,s,o,n,e[v+10],23,-1094730640),n=h(n,i,s,o,e[v+13],4,681279174),o=h(o,n,i,s,e[v+0],11,-358537222),s=h(s,o,n,i,e[v+3],16,-722521979),i=h(i,s,o,n,e[v+6],23,76029189),n=h(n,i,s,o,e[v+9],4,-640364487),o=h(o,n,i,s,e[v+12],11,-421815835),s=h(s,o,n,i,e[v+15],16,530742520),i=h(i,s,o,n,e[v+2],23,-995338651),n=p(n,i,s,o,e[v+0],6,-198630844),o=p(o,n,i,s,e[v+7],10,1126891415),s=p(s,o,n,i,e[v+14],15,-1416354905),i=p(i,s,o,n,e[v+5],21,-57434055),n=p(n,i,s,o,e[v+12],6,1700485571),o=p(o,n,i,s,e[v+3],10,-1894986606),s=p(s,o,n,i,e[v+10],15,-1051523),i=p(i,s,o,n,e[v+1],21,-2054922799),n=p(n,i,s,o,e[v+8],6,1873313359),o=p(o,n,i,s,e[v+15],10,-30611744),s=p(s,o,n,i,e[v+6],15,-1560198380),i=p(i,s,o,n,e[v+13],21,1309151649),n=p(n,i,s,o,e[v+4],6,-145523070),o=p(o,n,i,s,e[v+11],10,-1120210379),s=p(s,o,n,i,e[v+2],15,718787259),i=p(i,s,o,n,e[v+9],21,-343485551),n=r(n,u),i=r(i,a),s=r(s,f),o=r(o,d);return[n,i,s,o]},v=function(e,t){var r=s(e);r.length>16&&(r=d(r,e.length*n));var i=new Array(16),o=new Array(16);for(var u=0;u<16;u++)i[u]=r[u]^909522486,o[u]=r[u]^1549556828;var a=d(i.concat(s(t)),512+t.length*n);return d(o.concat(a),640)},m={hexdigest:function(e){return u(d(s(e),e.length*n))},b64digest:function(e){return a(d(s(e),e.length*n))},hash:function(e){return o(d(s(e),e.length*n))},hmac_hexdigest:function(e,t){return u(v(e,t))},hmac_b64digest:function(e,t){return a(v(e,t))},hmac_hash:function(e,t){return o(v(e,t))},test:function(){return MD5.hexdigest("abc")==="900150983cd24fb0d6963f7d28e17f72"}};return m}();Function.prototype.bind||(Function.prototype.bind=function(e){var t=this,n=Array.prototype.slice,r=Array.prototype.concat,i=n.call(arguments,1);return function(){return t.apply(e?e:this,r.call(i,n.call(arguments,0)))}}),Array.prototype.indexOf||(Array.prototype.indexOf=function(e){var t=this.length,n=Number(arguments[1])||0;n=n<0?Math.ceil(n):Math.floor(n),n<0&&(n+=t);for(;n<t;n++)if(n in this&&this[n]===e)return n;return-1}),function(e){function n(e,n){return new t.Builder(e,n)}function r(e){return new t.Builder("message",e)}function s(e){return new t.Builder("iq",e)}function o(e){return new t.Builder("presence",e)}var t;t={VERSION:"e85eb66",NS:{HTTPBIND:"http://jabber.org/protocol/httpbind",BOSH:"urn:xmpp:xbosh",CLIENT:"jabber:client",AUTH:"jabber:iq:auth",ROSTER:"jabber:iq:roster",PROFILE:"jabber:iq:profile",DISCO_INFO:"http://jabber.org/protocol/disco#info",DISCO_ITEMS:"http://jabber.org/protocol/disco#items",MUC:"http://jabber.org/protocol/muc",SASL:"urn:ietf:params:xml:ns:xmpp-sasl",STREAM:"http://etherx.jabber.org/streams",BIND:"urn:ietf:params:xml:ns:xmpp-bind",SESSION:"urn:ietf:params:xml:ns:xmpp-session",VERSION:"jabber:iq:version",STANZAS:"urn:ietf:params:xml:ns:xmpp-stanzas",XHTML_IM:"http://jabber.org/protocol/xhtml-im",XHTML:"http://www.w3.org/1999/xhtml"},XHTML:{tags:["a","blockquote","br","cite","em","img","li","ol","p","span","strong","ul","body"],attributes:{a:["href"],blockquote:["style"],br:[],cite:["style"],em:[],img:["src","alt","style","height","width"],li:["style"],ol:["style"],p:["style"],span:["style"],strong:[],ul:["style"],body:[]},css:["background-color","color","font-family","font-size","font-style","font-weight","margin-left","margin-right","text-align","text-decoration"],validTag:function(e){for(var n=0;n<t.XHTML.tags.length;n++)if(e==t.XHTML.tags[n])return!0;return!1},validAttribute:function(e,n){if(typeof t.XHTML.attributes[e]!="undefined"&&t.XHTML.attributes[e].length>0)for(var r=0;r<t.XHTML.attributes[e].length;r++)if(n==t.XHTML.attributes[e][r])return!0;return!1},validCSS:function(e){for(var n=0;n<t.XHTML.css.length;n++)if(e==t.XHTML.css[n])return!0;return!1}},addNamespace:function(e,n){t.NS[e]=n},Status:{ERROR:0,CONNECTING:1,CONNFAIL:2,AUTHENTICATING:3,AUTHFAIL:4,CONNECTED:5,DISCONNECTED:6,DISCONNECTING:7,ATTACHED:8},LogLevel:{DEBUG:0,INFO:1,WARN:2,ERROR:3,FATAL:4},ElementType:{NORMAL:1,TEXT:3,CDATA:4,FRAGMENT:11},TIMEOUT:1.1,SECONDARY_TIMEOUT:.1,forEachChild:function(e,n,r){var i,s;for(i=0;i<e.childNodes.length;i++)s=e.childNodes[i],s.nodeType==t.ElementType.NORMAL&&(!n||this.isTagEqual(s,n))&&r(s)},isTagEqual:function(e,t){return e.tagName.toLowerCase()==t.toLowerCase()},_xmlGenerator:null,_makeGenerator:function(){var e;return document.implementation.createDocument===undefined||document.implementation.createDocument&&document.documentMode&&document.documentMode<10?(e=this._getIEXmlDom(),e.appendChild(e.createElement("strophe"))):e=document.implementation.createDocument("jabber:client","strophe",null),e},xmlGenerator:function(){return t._xmlGenerator||(t._xmlGenerator=t._makeGenerator()),t._xmlGenerator},_getIEXmlDom:function(){var e=null,t=["Msxml2.DOMDocument.6.0","Msxml2.DOMDocument.5.0","Msxml2.DOMDocument.4.0","MSXML2.DOMDocument.3.0","MSXML2.DOMDocument","MSXML.DOMDocument","Microsoft.XMLDOM"];for(var n=0;n<t.length;n++){if(e!==null)break;try{e=new ActiveXObject(t[n])}catch(r){e=null}}return e},xmlElement:function(e){if(!e)return null;var n=t.xmlGenerator().createElement(e),r,i,s;for(r=1;r<arguments.length;r++){if(!arguments[r])continue;if(typeof arguments[r]=="string"||typeof arguments[r]=="number")n.appendChild(t.xmlTextNode(arguments[r]));else if(typeof arguments[r]=="object"&&typeof arguments[r].sort=="function")for(i=0;i<arguments[r].length;i++)typeof arguments[r][i]=="object"&&typeof arguments[r][i].sort=="function"&&n.setAttribute(arguments[r][i][0],arguments[r][i][1]);else if(typeof arguments[r]=="object")for(s in arguments[r])arguments[r].hasOwnProperty(s)&&n.setAttribute(s,arguments[r][s])}return n},xmlescape:function(e){return e=e.replace(/\&/g,"&"),e=e.replace(/</g,"<"),e=e.replace(/>/g,">"),e=e.replace(/'/g,"'"),e=e.replace(/"/g,"""),e},xmlTextNode:function(e){return t.xmlGenerator().createTextNode(e)},xmlHtmlNode:function(e){return window.DOMParser?(parser=new DOMParser,node=parser.parseFromString(e,"text/xml")):(node=new ActiveXObject("Microsoft.XMLDOM"),node.async="false",node.loadXML(e)),node},getText:function(e){if(!e)return null;var n="";e.childNodes.length===0&&e.nodeType==t.ElementType.TEXT&&(n+=e.nodeValue);for(var r=0;r<e.childNodes.length;r++)e.childNodes[r].nodeType==t.ElementType.TEXT&&(n+=e.childNodes[r].nodeValue);return t.xmlescape(n)},copyElement:function(e){var n,r;if(e.nodeType==t.ElementType.NORMAL){r=t.xmlElement(e.tagName);for(n=0;n<e.attributes.length;n++)r.setAttribute(e.attributes[n].nodeName.toLowerCase(),e.attributes[n].value);for(n=0;n<e.childNodes.length;n++)r.appendChild(t.copyElement(e.childNodes[n]))}else e.nodeType==t.ElementType.TEXT&&(r=t.xmlGenerator().createTextNode(e.nodeValue));return r},createHtml:function(e){var n,r,i,s,o,u,a,f,l,c,h,p,d;if(e.nodeType==t.ElementType.NORMAL){s=e.nodeName.toLowerCase();if(t.XHTML.validTag(s))try{r=t.xmlElement(s);for(n=0;n<t.XHTML.attributes[s].length;n++){o=t.XHTML.attributes[s][n],u=e.getAttribute(o);if(typeof u=="undefined"||u===null||u===""||u===!1||u===0)continue;o=="style"&&typeof u=="object"&&typeof u.cssText!="undefined"&&(u=u.cssText);if(o=="style"){a=[],f=u.split(";");for(i=0;i<f.length;i++)l=f[i].split(":"),c=l[0].replace(/^\s*/,"").replace(/\s*$/,"").toLowerCase(),t.XHTML.validCSS(c)&&(h=l[1].replace(/^\s*/,"").replace(/\s*$/,""),a.push(c+": "+h));a.length>0&&(u=a.join("; "),r.setAttribute(o,u))}else r.setAttribute(o,u)}for(n=0;n<e.childNodes.length;n++)r.appendChild(t.createHtml(e.childNodes[n]))}catch(v){r=t.xmlTextNode("")}else{r=t.xmlGenerator().createDocumentFragment();for(n=0;n<e.childNodes.length;n++)r.appendChild(t.createHtml(e.childNodes[n]))}}else if(e.nodeType==t.ElementType.FRAGMENT){r=t.xmlGenerator().createDocumentFragment();for(n=0;n<e.childNodes.length;n++)r.appendChild(t.createHtml(e.childNodes[n]))}else e.nodeType==t.ElementType.TEXT&&(r=t.xmlTextNode(e.nodeValue));return r},escapeNode:function(e){return e.replace(/^\s+|\s+$/g,"").replace(/\\/g,"\\5c").replace(/ /g,"\\20").replace(/\"/g,"\\22").replace(/\&/g,"\\26").replace(/\'/g,"\\27").replace(/\//g,"\\2f").replace(/:/g,"\\3a").replace(/</g,"\\3c").replace(/>/g,"\\3e").replace(/@/g,"\\40")},unescapeNode:function(e){return e.replace(/\\20/g," ").replace(/\\22/g,'"').replace(/\\26/g,"&").replace(/\\27/g,"'").replace(/\\2f/g,"/").replace(/\\3a/g,":").replace(/\\3c/g,"<").replace(/\\3e/g,">").replace(/\\40/g,"@").replace(/\\5c/g,"\\")},getNodeFromJid:function(e){return e.indexOf("@")<0?null:e.split("@")[0]},getDomainFromJid:function(e){var n=t.getBareJidFromJid(e);if(n.indexOf("@")<0)return n;var r=n.split("@");return r.splice(0,1),r.join("@")},getResourceFromJid:function(e){var t=e.split("/");return t.length<2?null:(t.splice(0,1),t.join("/"))},getBareJidFromJid:function(e){return e?e.split("/")[0]:null},log:function(e,t){return},debug:function(e){this.log(this.LogLevel.DEBUG,e)},info:function(e){this.log(this.LogLevel.INFO,e)},warn:function(e){this.log(this.LogLevel.WARN,e)},error:function(e){this.log(this.LogLevel.ERROR,e)},fatal:function(e){this.log(this.LogLevel.FATAL,e)},serialize:function(e){var n;if(!e)return null;typeof e.tree=="function"&&(e=e.tree());var r=e.nodeName,i,s;e.getAttribute("_realname")&&(r=e.getAttribute("_realname")),n="<"+r;for(i=0;i<e.attributes.length;i++)e.attributes[i].nodeName!="_realname"&&(n+=" "+e.attributes[i].nodeName.toLowerCase()+"='"+e.attributes[i].value.replace(/&/g,"&").replace(/\'/g,"'").replace(/>/g,">").replace(/</g,"<")+"'");if(e.childNodes.length>0){n+=">";for(i=0;i<e.childNodes.length;i++){s=e.childNodes[i];switch(s.nodeType){case t.ElementType.NORMAL:n+=t.serialize(s);break;case t.ElementType.TEXT:n+=t.xmlescape(s.nodeValue);break;case t.ElementType.CDATA:n+="<![CDATA["+s.nodeValue+"]]>"}}n+="</"+r+">"}else n+="/>";return n},_requestId:0,_connectionPlugins:{},addConnectionPlugin:function(e,n){t._connectionPlugins[e]=n}},t.Builder=function(e,n){if(e=="presence"||e=="message"||e=="iq")n&&!n.xmlns?n.xmlns=t.NS.CLIENT:n||(n={xmlns:t.NS.CLIENT});this.nodeTree=t.xmlElement(e,n),this.node=this.nodeTree},t.Builder.prototype={tree:function(){return this.nodeTree},toString:function(){return t.serialize(this.nodeTree)},up:function(){return this.node=this.node.parentNode,this},attrs:function(e){for(var t in e)e.hasOwnProperty(t)&&this.node.setAttribute(t,e[t]);return this},c:function(e,n,r){var i=t.xmlElement(e,n,r);return this.node.appendChild(i),r||(this.node=i),this},cnode:function(e){var n=t.xmlGenerator();try{var r=n.importNode!==undefined}catch(i){var r=!1}var s=r?n.importNode(e,!0):t.copyElement(e);return this.node.appendChild(s),this.node=s,this},t:function(e){var n=t.xmlTextNode(e);return this.node.appendChild(n),this},h:function(e){var n=document.createElement("body");n.innerHTML=e;var r=t.createHtml(n);while(r.childNodes.length>0)this.node.appendChild(r.childNodes[0]);return this}},t.Handler=function(e,n,r,i,s,o,u){this.handler=e,this.ns=n,this.name=r,this.type=i,this.id=s,this.options=u||{matchBare:!1},this.options.matchBare||(this.options.matchBare=!1),this.options.matchBare?this.from=o?t.getBareJidFromJid(o):null:this.from=o,this.user=!0},t.Handler.prototype={isMatch:function(e){var n,r=null;this.options.matchBare?r=t.getBareJidFromJid(e.getAttribute("from")):r=e.getAttribute("from"),n=!1;if(!this.ns)n=!0;else{var i=this;t.forEachChild(e,null,function(e){e.getAttribute("xmlns")==i.ns&&(n=!0)}),n=n||e.getAttribute("xmlns")==this.ns}return!n||!!this.name&&!t.isTagEqual(e,this.name)||!!this.type&&e.getAttribute("type")!=this.type||!!this.id&&e.getAttribute("id")!=this.id||!!this.from&&r!=this.from?!1:!0},run:function(e){var n=null;try{n=this.handler(e)}catch(r){throw r.sourceURL?t.fatal("error: "+this.handler+" "+r.sourceURL+":"+r.line+" - "+r.name+": "+r.message):r.fileName?(typeof console!="undefined"&&(console.trace(),console.error(this.handler," - error - ",r,r.message)),t.fatal("error: "+this.handler+" "+r.fileName+":"+r.lineNumber+" - "+r.name+": "+r.message)):t.fatal("error: "+r.message+"\n"+r.stack),r}return n},toString:function(){return"{Handler: "+this.handler+"("+this.name+","+this.id+","+this.ns+")}"}},t.TimedHandler=function(e,t){this.period=e,this.handler=t,this.lastCalled=(new Date).getTime(),this.user=!0},t.TimedHandler.prototype={run:function(){return this.lastCalled=(new Date).getTime(),this.handler()},reset:function(){this.lastCalled=(new Date).getTime()},toString:function(){return"{TimedHandler: "+this.handler+"("+this.period+")}"}},t.Request=function(e,n,r,i){this.id=++t._requestId,this.xmlData=e,this.data=t.serialize(e),this.origFunc=n,this.func=n,this.rid=r,this.date=NaN,this.sends=i||0,this.abort=!1,this.dead=null,this.age=function(){if(!this.date)return 0;var e=new Date;return(e-this.date)/1e3},this.timeDead=function(){if(!this.dead)return 0;var e=new Date;return(e-this.dead)/1e3},this.xhr=this._newXHR()},t.Request.prototype={getResponse:function(){var e=null;if(this.xhr.responseXML&&this.xhr.responseXML.documentElement){e=this.xhr.responseXML.documentElement;if(e.tagName=="parsererror")throw t.error("invalid response received"),t.error("responseText: "+this.xhr.responseText),t.error("responseXML: "+t.serialize(this.xhr.responseXML)),"parsererror"}else this.xhr.responseText&&(t.error("invalid response received"),t.error("responseText: "+this.xhr.responseText),t.error("responseXML: "+t.serialize(this.xhr.responseXML)));return e},_newXHR:function(){var e=null;return window.XMLHttpRequest?(e=new XMLHttpRequest,e.overrideMimeType&&e.overrideMimeType("text/xml")):window.ActiveXObject&&(e=new ActiveXObject("Microsoft.XMLHTTP")),e.onreadystatechange=this.func.bind(null,this),e}},t.Connection=function(e){this.service=e,this.jid="",this.domain=null,this.rid=Math.floor(Math.random()*4294967295),this.sid=null,this.streamId=null,this.features=null,this._sasl_data=[],this.do_session=!1,this.do_bind=!1,this.timedHandlers=[],this.handlers=[],this.removeTimeds=[],this.removeHandlers=[],this.addTimeds=[],this.addHandlers=[],this._authentication={},this._idleTimeout=null,this._disconnectTimeout=null,this.do_authentication=!0,this.authenticated=!1,this.disconnecting=!1,this.connected=!1,this.errors=0,this.paused=!1,this.hold=1,this.wait=60,this.window=5,this._data=[],this._requests=[],this._uniqueId=Math.round(Math.random()*1e4),this._sasl_success_handler=null,this._sasl_failure_handler=null,this._sasl_challenge_handler=null,this.maxRetries=5,this._idleTimeout=setTimeout(this._onIdle.bind(this),100);for(var n in t._connectionPlugins)if(t._connectionPlugins.hasOwnProperty(n)){var r=t._connectionPlugins[n],i=function(){};i.prototype=r,this[n]=new i,this[n].init(this)}},t.Connection.prototype={reset:function(){this.rid=Math.floor(Math.random()*4294967295),this.sid=null,this.streamId=null,this.do_session=!1,this.do_bind=!1,this.timedHandlers=[],this.handlers=[],this.removeTimeds=[],this.removeHandlers=[],this.addTimeds=[],this.addHandlers=[],this._authentication={},this.authenticated=!1,this.disconnecting=!1,this.connected=!1,this.errors=0,this._requests=[],this._uniqueId=Math.round(Math.random()*1e4)},pause:function(){this.paused=!0},resume:function(){this.paused=!1},getUniqueId:function(e){return typeof e=="string"||typeof e=="number"?++this._uniqueId+":"+e:++this._uniqueId+""},connect:function(e,n,r,i,s,o){this.jid=e,this.pass=n,this.connect_callback=r,this.disconnecting=!1,this.connected=!1,this.authenticated=!1,this.errors=0,this.wait=i||this.wait,this.hold=s||this.hold,this.domain=this.domain||t.getDomainFromJid(this.jid);var u=this._buildBody().attrs({to:this.domain,"xml:lang":"en",wait:this.wait,hold:this.hold,content:"text/xml; charset=utf-8",ver:"1.6","xmpp:version":"1.0","xmlns:xmpp":t.NS.BOSH});o&&u.attrs({route:o}),this._changeConnectStatus(t.Status.CONNECTING,null);var a=this._connect_callback||this._connect_cb;this._connect_callback=null,this._requests.push(new t.Request(u.tree(),this._onRequestStateChange.bind(this,a.bind(this)),u.tree().getAttribute("rid"))),this._throttledRequestHandler()},attach:function(e,n,r,i,s,o,u){this.jid=e,this.sid=n,this.rid=r,this.connect_callback=i,this.domain=t.getDomainFromJid(this.jid),this.authenticated=!0,this.connected=!0,this.wait=s||this.wait,this.hold=o||this.hold,this.window=u||this.window,this._changeConnectStatus(t.Status.ATTACHED,null)},xmlInput:function(e){return},xmlOutput:function(e){return},rawInput:function(e){return},rawOutput:function(e){return},send:function(e){if(e===null)return;if(typeof e.sort=="function")for(var t=0;t<e.length;t++)this._queueData(e[t]);else typeof e.tree=="function"?this._queueData(e.tree()):this._queueData(e);this._throttledRequestHandler(),clearTimeout(this._idleTimeout),this._idleTimeout=setTimeout(this._onIdle.bind(this),100)},flush:function(){clearTimeout(this._idleTimeout),this._onIdle()},sendIQ:function(e,t,n,r){var i=null,s=this;typeof e.tree=="function"&&(e=e.tree());var o=e.getAttribute("id");o||(o=this.getUniqueId("sendIQ"),e.setAttribute("id",o));var u=this.addHandler(function(e){i&&s.deleteTimedHandler(i);var r=e.getAttribute("type");if(r=="result")t&&t(e);else{if(r!="error")throw{name:"StropheError",message:"Got bad IQ type of "+r};n&&n(e)}},null,"iq",null,o);return r&&(i=this.addTimedHandler(r,function(){return s.deleteHandler(u),n&&n(null),!1})),this.send(e),o},_queueData:function(e){if(e===null||!e.tagName||!e.childNodes)throw{name:"StropheError",message:"Cannot queue non-DOMElement."};this._data.push(e)},_sendRestart:function(){this._data.push("restart"),this._throttledRequestHandler(),clearTimeout(this._idleTimeout),this._idleTimeout=setTimeout(this._onIdle.bind(this),100)},addTimedHandler:function(e,n){var r=new t.TimedHandler(e,n);return this.addTimeds.push(r),r},deleteTimedHandler:function(e){this.removeTimeds.push(e)},addHandler:function(e,n,r,i,s,o,u){var a=new t.Handler(e,n,r,i,s,o,u);return this.addHandlers.push(a),a},deleteHandler:function(e){this.removeHandlers.push(e)},disconnect:function(e){this._changeConnectStatus(t.Status.DISCONNECTING,e),t.info("Disconnect was called because: "+e),this.connected&&(this._disconnectTimeout=this._addSysTimedHandler(3e3,this._onDisconnectTimeout.bind(this)),this._sendTerminate())},_changeConnectStatus:function(e,n){for(var r in t._connectionPlugins)if(t._connectionPlugins.hasOwnProperty(r)){var i=this[r];if(i.statusChanged)try{i.statusChanged(e,n)}catch(s){t.error(""+r+" plugin caused an exception "+"changing status: "+s)}}if(this.connect_callback)try{this.connect_callback(e,n)}catch(o){t.error("User connection callback caused an exception: "+o)}},_buildBody:function(){var e=n("body",{rid:this.rid++,xmlns:t.NS.HTTPBIND});return this.sid!==null&&e.attrs({sid:this.sid}),e},_removeRequest:function(e){t.debug("removing request");var n;for(n=this._requests.length-1;n>=0;n--)e==this._requests[n]&&this._requests.splice(n,1);e.xhr.onreadystatechange=function(){},this._throttledRequestHandler()},_restartRequest:function(e){var t=this._requests[e];t.dead===null&&(t.dead=new Date),this._processRequest(e)},_processRequest:function(e){var n=this._requests[e],r=-1;try{n.xhr.readyState==4&&(r=n.xhr.status)}catch(i){t.error("caught an error in _requests["+e+"], reqStatus: "+r)}typeof r=="undefined"&&(r=-1);if(n.sends>this.maxRetries){this._onDisconnectTimeout();return}var s=n.age(),o=!isNaN(s)&&s>Math.floor(t.TIMEOUT*this.wait),u=n.dead!==null&&n.timeDead()>Math.floor(t.SECONDARY_TIMEOUT*this.wait),a=n.xhr.readyState==4&&(r<1||r>=500);if(o||u||a)u&&t.error("Request "+this._requests[e].id+" timed out (secondary), restarting"),n.abort=!0,n.xhr.abort(),n.xhr.onreadystatechange=function(){},this._requests[e]=new t.Request(n.xmlData,n.origFunc,n.rid,n.sends),n=this._requests[e];if(n.xhr.readyState===0){t.debug("request id "+n.id+"."+n.sends+" posting");try{n.xhr.open("POST",this.service,!0)}catch(f){t.error("XHR open failed."),this.connected||this._changeConnectStatus(t.Status.CONNFAIL,"bad-service"),this.disconnect();return}var l=function(){n.date=new Date,n.xhr.send(n.data)};if(n.sends>1){var c=Math.min(Math.floor(t.TIMEOUT*this.wait),Math.pow(n.sends,3))*1e3;setTimeout(l,c)}else l();n.sends++,this.xmlOutput!==t.Connection.prototype.xmlOutput&&this.xmlOutput(n.xmlData),this.rawOutput!==t.Connection.prototype.rawOutput&&this.rawOutput(n.data)}else t.debug("_processRequest: "+(e===0?"first":"second")+" request has readyState of "+n.xhr.readyState)},_throttledRequestHandler:function(){this._requests?t.debug("_throttledRequestHandler called with "+this._requests.length+" requests"):t.debug("_throttledRequestHandler called with undefined requests");if(!this._requests||this._requests.length===0)return;this._requests.length>0&&this._processRequest(0),this._requests.length>1&&Math.abs(this._requests[0].rid-this._requests[1].rid)<this.window&&this._processRequest(1)},_onRequestStateChange:function(e,n){t.debug("request id "+n.id+"."+n.sends+" state changed to "+n.xhr.readyState);if(n.abort){n.abort=!1;return}var r;if(n.xhr.readyState==4){r=0;try{r=n.xhr.status}catch(i){}typeof r=="undefined"&&(r=0);if(this.disconnecting&&r>=400){this._hitError(r);return}var s=this._requests[0]==n,o=this._requests[1]==n;if(r>0&&r<500||n.sends>5)this._removeRequest(n),t.debug("request id "+n.id+" should now be removed");if(r==200)(o||s&&this._requests.length>0&&this._requests[0].age()>Math.floor(t.SECONDARY_TIMEOUT*this.wait))&&this._restartRequest(0),t.debug("request id "+n.id+"."+n.sends+" got 200"),e(n),this.errors=0;else{t.error("request id "+n.id+"."+n.sends+" error "+r+" happened");if(r===0||r>=400&&r<600||r>=12e3)this._hitError(r),r>=400&&r<500&&(this._changeConnectStatus(t.Status.DISCONNECTING,null),this._doDisconnect())}r>0&&r<500||n.sends>5||this._throttledRequestHandler()}},_hitError:function(e){this.errors++,t.warn("request errored, status: "+e+", number of errors: "+this.errors),this.errors>4&&this._onDisconnectTimeout()},_doDisconnect:function(){t.info("_doDisconnect was called"),this.authenticated=!1,this.disconnecting=!1,this.sid=null,this.streamId=null,this.rid=Math.floor(Math.random()*4294967295),this.connected&&(this._changeConnectStatus(t.Status.DISCONNECTED,null),this.connected=!1),this.handlers=[],this.timedHandlers=[],this.removeTimeds=[],this.removeHandlers=[],this.addTimeds=[],this.addHandlers=[]},_dataRecv:function(e){try{var n=e.getResponse()}catch(r){if(r!="parsererror")throw r;this.disconnect("strophe-parsererror")}if(n===null)return;this.xmlInput!==t.Connection.prototype.xmlInput&&this.xmlInput(n),this.rawInput!==t.Connection.prototype.rawInput&&this.rawInput(t.serialize(n));var i,s;while(this.removeHandlers.length>0)s=this.removeHandlers.pop(),i=this.handlers.indexOf(s),i>=0&&this.handlers.splice(i,1);while(this.addHandlers.length>0)this.handlers.push(this.addHandlers.pop());if(this.disconnecting&&this._requests.length===0){this.deleteTimedHandler(this._disconnectTimeout),this._disconnectTimeout=null,this._doDisconnect();return}var o=n.getAttribute("type"),u,a;if(o!==null&&o=="terminate"){if(this.disconnecting)return;u=n.getAttribute("condition"),a=n.getElementsByTagName("conflict"),u!==null?(u=="remote-stream-error"&&a.length>0&&(u="conflict"),this._changeConnectStatus(t.Status.CONNFAIL,u)):this._changeConnectStatus(t.Status.CONNFAIL,"unknown"),this.disconnect();return}var f=this;t.forEachChild(n,null,function(e){var t,n;n=f.handlers,f.handlers=[];for(t=0;t<n.length;t++){var r=n[t];try{r.isMatch(e)&&(f.authenticated||!r.user)?r.run(e)&&f.handlers.push(r):f.handlers.push(r)}catch(i){}}})},_sendTerminate:function(){t.info("_sendTerminate was called");var e=this._buildBody().attrs({type:"terminate"});this.authenticated&&e.c("presence",{xmlns:t.NS.CLIENT,type:"unavailable"}),this.disconnecting=!0;var n=new t.Request(e.tree(),this._onRequestStateChange.bind(this,this._dataRecv.bind(this)),e.tree().getAttribute("rid"));this._requests.push(n),this._throttledRequestHandler()},_connect_cb:function(e,n){t.info("_connect_cb was called"),this.connected=!0;var r=e.getResponse();if(!r)return;this.xmlInput!==t.Connection.prototype.xmlInput&&this.xmlInput(r),this.rawInput!==t.Connection.prototype.rawInput&&this.rawInput(t.serialize(r));var i=r.getAttribute("type"),s,o;if(i!==null&&i=="terminate"){s=r.getAttribute("condition"),o=r.getElementsByTagName("conflict"),s!==null?(s=="remote-stream-error"&&o.length>0&&(s="conflict"),this._changeConnectStatus(t.Status.CONNFAIL,s)):this._changeConnectStatus(t.Status.CONNFAIL,"unknown");return}this.sid||(this.sid=r.getAttribute("sid")),this.stream_id||(this.stream_id=r.getAttribute("authid"));var u=r.getAttribute("requests");u&&(this.window=parseInt(u,10));var a=r.getAttribute("hold");a&&(this.hold=parseInt(a,10));var f=r.getAttribute("wait");f&&(this.wait=parseInt(f,10)),this._authentication.sasl_scram_sha1=!1,this._authentication.sasl_plain=!1,this._authentication.sasl_digest_md5=!1,this._authentication.sasl_anonymous=!1,this._authentication.legacy_auth=!1;var l=r.getElementsByTagName("stream:features").length>0;l||(l=r.getElementsByTagName("features").length>0);var c=r.getElementsByTagName("mechanism"),h,p,d,v,m=!1;if(l&&c.length>0){var g=0;for(h=0;h<c.length;h++)p=t.getText(c[h]),p=="SCRAM-SHA-1"?this._authentication.sasl_scram_sha1=!0:p=="DIGEST-MD5"?this._authentication.sasl_digest_md5=!0:p=="PLAIN"?this._authentication.sasl_plain=!0:p=="ANONYMOUS"?this._authentication.sasl_anonymous=!0:g++;this._authentication.legacy_auth=r.getElementsByTagName("auth").length>0,m=this._authentication.legacy_auth||g<c.length}if(!m){n=n||this._connect_cb;var y=this._buildBody();this._requests.push(new t.Request(y.tree(),this._onRequestStateChange.bind(this,n.bind(this)),y.tree().getAttribute("rid"))),this._throttledRequestHandler();return}this.do_authentication!==!1&&this.authenticate()},authenticate:function(){if(t.getNodeFromJid(this.jid)===null&&this._authentication.sasl_anonymous)this._changeConnectStatus(t.Status.AUTHENTICATING,null),this._sasl_success_handler=this._addSysHandler(this._sasl_success_cb.bind(this),null,"success",null,null),this._sasl_failure_handler=this._addSysHandler(this._sasl_failure_cb.bind(this),null,"failure",null,null),this.send(n("auth",{xmlns:t.NS.SASL,mechanism:"ANONYMOUS"}).tree());else if(t.getNodeFromJid(this.jid)===null)this._changeConnectStatus(t.Status.CONNFAIL,"x-strophe-bad-non-anon-jid"),this.disconnect();else if(this._authentication.sasl_scram_sha1){var e=MD5.hexdigest(Math.random()*1234567890),r="n="+t.getNodeFromJid(this.jid);r+=",r=",r+=e,this._sasl_data.cnonce=e,this._sasl_data["client-first-message-bare"]=r,r="n,,"+r,this._changeConnectStatus(t.Status.AUTHENTICATING,null),this._sasl_challenge_handler=this._addSysHandler(this._sasl_scram_challenge_cb.bind(this),null,"challenge",null,null),this._sasl_failure_handler=this._addSysHandler(this._sasl_failure_cb.bind(this),null,"failure",null,null),this.send(n("auth",{xmlns:t.NS.SASL,mechanism:"SCRAM-SHA-1"}).t(Base64.encode(r)).tree())}else this._authentication.sasl_digest_md5?(this._changeConnectStatus(t.Status.AUTHENTICATING,null),this._sasl_challenge_handler=this._addSysHandler(this._sasl_digest_challenge1_cb.bind(this),null,"challenge",null,null),this._sasl_failure_handler=this._addSysHandler(this._sasl_failure_cb.bind(this),null,"failure",null,null),this.send(n("auth",{xmlns:t.NS.SASL,mechanism:"DIGEST-MD5"}).tree())):this._authentication.sasl_plain?(r=t.getBareJidFromJid(this.jid),r+="\0",r+=t.getNodeFromJid(this.jid),r+="\0",r+=this.pass,this._changeConnectStatus(t.Status.AUTHENTICATING,null),this._sasl_success_handler=this._addSysHandler(this._sasl_success_cb.bind(this),null,"success",null,null),this._sasl_failure_handler=this._addSysHandler(this._sasl_failure_cb.bind(this),null,"failure",null,null),hashed_auth_str=Base64.encode(r),this.send(n("auth",{xmlns:t.NS.SASL,mechanism:"PLAIN"}).t(hashed_auth_str).tree())):(this._changeConnectStatus(t.Status.AUTHENTICATING,null),this._addSysHandler(this._auth1_cb.bind(this),null,null,null,"_auth_1"),this.send(s({type:"get",to:this.domain,id:"_auth_1"}).c("query",{xmlns:t.NS.AUTH}).c("username",{}).t(t.getNodeFromJid(this.jid)).tree()))},_sasl_digest_challenge1_cb:function(e){var r=/([a-z]+)=("[^"]+"|[^,"]+)(?:,|$)/,i=Base64.decode(t.getText(e)),s=MD5.hexdigest(""+Math.random()*1234567890),o="",u=null,a="",f="",l;this.deleteHandler(this._sasl_failure_handler);while(i.match(r)){l=i.match(r),i=i.replace(l[0],""),l[2]=l[2].replace(/^"(.+)"$/,"$1");switch(l[1]){case"realm":o=l[2];break;case"nonce":a=l[2];break;case"qop":f=l[2];break;case"host":u=l[2]}}var c="xmpp/"+this.domain;u!==null&&(c=c+"/"+u);var h=MD5.hash(t.getNodeFromJid(this.jid)+":"+o+":"+this.pass)+":"+a+":"+s,p="AUTHENTICATE:"+c,d="";return d+="username="+this._quote(t.getNodeFromJid(this.jid))+",",d+="realm="+this._quote(o)+",",d+="nonce="+this._quote(a)+",",d+="cnonce="+this._quote(s)+",",d+='nc="00000001",',d+='qop="auth",',d+="digest-uri="+this._quote(c)+",",d+="response="+this._quote(MD5.hexdigest(MD5.hexdigest(h)+":"+a+":00000001:"+s+":auth:"+MD5.hexdigest(p)))+",",d+='charset="utf-8"',this._sasl_challenge_handler=this._addSysHandler(this._sasl_digest_challenge2_cb.bind(this),null,"challenge",null,null),this._sasl_success_handler=this._addSysHandler(this._sasl_success_cb.bind(this),null,"success",null,null),this._sasl_failure_handler=this._addSysHandler(this._sasl_failure_cb.bind(this),null,"failure",null,null),this.send(n("response",{xmlns:t.NS.SASL}).t(Base64.encode(d)).tree()),!1},_quote:function(e){return'"'+e.replace(/\\/g,"\\\\").replace(/"/g,'\\"')+'"'},_sasl_digest_challenge2_cb:function(e){return this.deleteHandler(this._sasl_success_handler),this.deleteHandler(this._sasl_failure_handler),this._sasl_success_handler=this._addSysHandler(this._sasl_success_cb.bind(this),null,"success",null,null),this._sasl_failure_handler=this._addSysHandler(this._sasl_failure_cb.bind(this),null,"failure",null,null),this.send(n("response",{xmlns:t.NS.SASL}).tree()),!1},_sasl_scram_challenge_cb:function(e){var r,s,o,u,a,f,l,c,h,p="c=biws,",d=Base64.decode(t.getText(e)),v=this._sasl_data["client-first-message-bare"]+","+d+",",m=this._sasl_data.cnonce,g=/([a-z]+)=([^,]+)(,|$)/;this.deleteHandler(this._sasl_failure_handler);while(d.match(g)){matches=d.match(g),d=d.replace(matches[0],"");switch(matches[1]){case"r":r=matches[2];break;case"s":s=matches[2];break;case"i":o=matches[2]}}if(r.substr(0,m.length)!==m)return this._sasl_data=[],this._sasl_failure_cb(null);p+="r="+r,v+=p,s=Base64.decode(s),s+="\0\0\0",u=f=core_hmac_sha1(this.pass,s);for(i=1;i<o;i++){a=core_hmac_sha1(this.pass,binb2str(f));for(k=0;k<5;k++)u[k]^=a[k];f=a}u=binb2str(u),l=core_hmac_sha1(u,"Client Key"),c=str_hmac_sha1(u,"Server Key"),h=core_hmac_sha1(str_sha1(binb2str(l)),v),this._sasl_data["server-signature"]=b64_hmac_sha1(c,v);for(k=0;k<5;k++)l[k]^=h[k];return p+=",p="+Base64.encode(binb2str(l)),this._sasl_success_handler=this._addSysHandler(this._sasl_success_cb.bind(this),null,"success",null,null),this._sasl_failure_handler=this._addSysHandler(this._sasl_failure_cb.bind(this),null,"failure",null,null),this.send(n("response",{xmlns:t.NS.SASL}).t(Base64.encode(p)).tree()),!1},_auth1_cb:function(e){var n=s({type:"set",id:"_auth_2"}).c("query",{xmlns:t.NS.AUTH}).c("username",{}).t(t.getNodeFromJid(this.jid)).up().c("password").t(this.pass);return t.getResourceFromJid(this.jid)||(this.jid=t.getBareJidFromJid(this.jid)+"/strophe"),n.up().c("resource",{}).t(t.getResourceFromJid(this.jid)),this._addSysHandler(this._auth2_cb.bind(this),null,null,null,"_auth_2"),this.send(n.tree()),!1},_sasl_success_cb:function(e){if(this._sasl_data["server-signature"]){var n,r=Base64.decode(t.getText(e)),i=/([a-z]+)=([^,]+)(,|$)/;matches=r.match(i),matches[1]=="v"&&(n=matches[2]);if(n!=this._sasl_data["server-signature"])return this.deleteHandler(this._sasl_failure_handler),this._sasl_failure_handler=null,this._sasl_challenge_handler&&(this.deleteHandler(this._sasl_challenge_handler),this._sasl_challenge_handler=null),this._sasl_data=[],this._sasl_failure_cb(null)}return t.info("SASL authentication succeeded."),this.deleteHandler(this._sasl_failure_handler),this._sasl_failure_handler=null,this._sasl_challenge_handler&&(this.deleteHandler(this._sasl_challenge_handler),this._sasl_challenge_handler=null),this._addSysHandler(this._sasl_auth1_cb.bind(this),null,"stream:features",null,null),this._sendRestart(),!1},_sasl_auth1_cb:function(e){this.features=e;var n,r;for(n=0;n<e.childNodes.length;n++)r=e.childNodes[n],r.nodeName=="bind"&&(this.do_bind=!0),r.nodeName=="session"&&(this.do_session=!0);if(!this.do_bind)return this._changeConnectStatus(t.Status.AUTHFAIL,null),!1;this._addSysHandler(this._sasl_bind_cb.bind(this),null,null,null,"_bind_auth_2");var i=t.getResourceFromJid(this.jid);return i?this.send(s({type:"set",id:"_bind_auth_2"}).c("bind",{xmlns:t.NS.BIND}).c("resource",{}).t(i).tree()):this.send(s({type:"set",id:"_bind_auth_2"}).c("bind",{xmlns:t.NS.BIND}).tree()),!1},_sasl_bind_cb:function(e){if(e.getAttribute("type")=="error"){t.info("SASL binding failed.");var n=e.getElementsByTagName("conflict"),r;return n.length>0&&(r="conflict"),this._changeConnectStatus(t.Status.AUTHFAIL,r),!1}var i=e.getElementsByTagName("bind"),o;if(!(i.length>0))return t.info("SASL binding failed."),this._changeConnectStatus(t.Status.AUTHFAIL,null),!1;o=i[0].getElementsByTagName("jid"),o.length>0&&(this.jid=t.getText(o[0]),this.do_session?(this._addSysHandler(this._sasl_session_cb.bind(this),null,null,null,"_session_auth_2"),this.send(s({type:"set",id:"_session_auth_2"}).c("session",{xmlns:t.NS.SESSION}).tree())):(this.authenticated=!0,this._changeConnectStatus(t.Status.CONNECTED,null)))},_sasl_session_cb:function(e){if(e.getAttribute("type")=="result")this.authenticated=!0,this._changeConnectStatus(t.Status.CONNECTED,null);else if(e.getAttribute("type")=="error")return t.info("Session creation failed."),this._changeConnectStatus(t.Status.AUTHFAIL,null),!1;return!1},_sasl_failure_cb:function(e){return this._sasl_success_handler&&(this.deleteHandler(this._sasl_success_handler),this._sasl_success_handler=null),this._sasl_challenge_handler&&(this.deleteHandler(this._sasl_challenge_handler),this._sasl_challenge_handler=null),this._changeConnectStatus(t.Status.AUTHFAIL,null),!1},_auth2_cb:function(e){return e.getAttribute("type")=="result"?(this.authenticated=!0,this._changeConnectStatus(t.Status.CONNECTED,null)):e.getAttribute("type")=="error"&&(this._changeConnectStatus(t.Status.AUTHFAIL,null),this.disconnect()),!1},_addSysTimedHandler:function(e,n){var r=new t.TimedHandler(e,n);return r.user=!1,this.addTimeds.push(r),r},_addSysHandler:function(e,n,r,i,s){var o=new t.Handler(e,n,r,i,s);return o.user=!1,this.addHandlers.push(o),o},_onDisconnectTimeout:function(){t.info("_onDisconnectTimeout was called");var e;while(this._requests.length>0)e=this._requests.pop(),e.abort=!0,e.xhr.abort(),e.xhr.onreadystatechange=function(){};return this._doDisconnect(),!1},_onIdle:function(){var e,n,r,i;while(this.addTimeds.length>0)this.timedHandlers.push(this.addTimeds.pop());while(this.removeTimeds.length>0)n=this.removeTimeds.pop(),e=this.timedHandlers.indexOf(n),e>=0&&this.timedHandlers.splice(e,1);var s=(new Date).getTime();i=[];for(e=0;e<this.timedHandlers.length;e++){n=this.timedHandlers[e];if(this.authenticated||!n.user)r=n.lastCalled+n.period,r-s<=0?n.run()&&i.push(n):i.push(n)}this.timedHandlers=i;var o,u;this.authenticated&&this._requests.length===0&&this._data.length===0&&!this.disconnecting&&(t.info("no requests during idle cycle, sending blank request"),this._data.push(null));if(this._requests.length<2&&this._data.length>0&&!this.paused){o=this._buildBody();for(e=0;e<this._data.length;e++)this._data[e]!==null&&(this._data[e]==="restart"?o.attrs({to:this.domain,"xml:lang":"en","xmpp:restart":"true","xmlns:xmpp":t.NS.BOSH}):o.cnode(this._data[e]).up());delete this._data,this._data=[],this._requests.push(new t.Request(o.tree(),this._onRequestStateChange.bind(this,this._dataRecv.bind(this)),o.tree().getAttribute("rid"))),this._processRequest(this._requests.length-1)}this._requests.length>0&&(u=this._requests[0].age(),this._requests[0].dead!==null&&this._requests[0].timeDead()>Math.floor(t.SECONDARY_TIMEOUT*this.wait)&&this._throttledRequestHandler(),u>Math.floor(t.TIMEOUT*this.wait)&&(t.warn("Request "+this._requests[0].id+" timed out, over "+Math.floor(t.TIMEOUT*this.wait)+" seconds since last activity"),this._throttledRequestHandler())),clearTimeout(this._idleTimeout),this.connected&&(this._idleTimeout=setTimeout(this._onIdle.bind(this),100))}},e&&e(t,n,r,s,o)}(function(){window.Strophe=arguments[0],window.$build=arguments[1],window.$msg=arguments[2],window.$iq=arguments[3],window.$pres=arguments[4]}),define("strophe",function(){}),function(){var e,t,n,r=function(e,t){return function(){return e.apply(t,arguments)}};Strophe.addConnectionPlugin("muc",{_connection:null,rooms:{},roomNames:[],init:function(e){return this._connection=e,this._muc_handler=null,Strophe.addNamespace("MUC_OWNER",Strophe.NS.MUC+"#owner"),Strophe.addNamespace("MUC_ADMIN",Strophe.NS.MUC+"#admin"),Strophe.addNamespace("MUC_USER",Strophe.NS.MUC+"#user"),Strophe.addNamespace("MUC_ROOMCONF",Strophe.NS.MUC+"#roomconfig")},join:function(e,t,r,i,s,o,u){var a,f,l=this;return f=this.test_append_nick(e,t),a=$pres({from:this._connection.jid,to:f}).c("x",{xmlns:Strophe.NS.MUC}),u!=null&&(a=a.c("history",u).up),o!=null&&a.cnode(Strophe.xmlElement("password",[],o)),typeof extended_presence!="undefined"&&extended_presence!==null&&a.up.cnode(extended_presence),this._muc_handler==null&&(this._muc_handler=this._connection.addHandler(function(t){var n,r,i,s,o,u,a,f,c,h;n=t.getAttribute("from");if(!n)return!0;o=n.split("/")[0];if(!l.rooms[o])return!0;e=l.rooms[o],i={};if(t.nodeName==="message")i=e._message_handlers;else if(t.nodeName==="presence"){f=t.getElementsByTagName("x");if(f.length>0)for(c=0,h=f.length;c<h;c++){u=f[c],a=u.getAttribute("xmlns");if(a&&a.match(Strophe.NS.MUC)){i=e._presence_handlers;break}}}for(s in i)r=i[s],r(t,e)||delete i[s];return!0})),this.rooms.hasOwnProperty(e)||(this.rooms[e]=new n(this,e,t,o),this.roomNames.push(e)),i&&this.rooms[e].addHandler("presence",i),r&&this.rooms[e].addHandler("message",r),s&&this.rooms[e].addHandler("roster",s),this._connection.send(a)},leave:function(e,t,n,r){var i,s,o,u;return i=this.roomNames.indexOf(e),delete this.rooms[e],i>=0&&(this.roomNames.splice(i,1),this.roomNames.length===0&&(this._connection.deleteHandler(this._muc_handler),this._muc_handler=null)),u=this.test_append_nick(e,t),o=this._connection.getUniqueId(),s=$pres({type:"unavailable",id:o,from:this._connection.jid,to:u}),r!=null&&s.c("status",r),n!=null&&this._connection.addHandler(n,null,"presence",null,o),this._connection.send(s),o},message:function(e,t,n,r,i){var s,o,u,a;return a=this.test_append_nick(e,t),i=i||(t!=null?"chat":"groupchat"),o=this._connection.getUniqueId(),s=$msg({to:a,from:this._connection.jid,type:i,id:o}).c("body",{xmlns:Strophe.NS.CLIENT}).t(n),s.up(),r!=null&&(s.c("html",{xmlns:Strophe.NS.XHTML_IM}).c("body",{xmlns:Strophe.NS.XHTML}).t(r),s.node.childNodes.length===0?(u=s.node.parentNode,s.up().up(),s.node.removeChild(u)):s.up().up()),s.c("x",{xmlns:"jabber:x:event"}).c("composing"),this._connection.send(s),o},groupchat:function(e,t,n){return this.message(e,null,t,n)},invite:function(e,t,n){var r,i;return i=this._connection.getUniqueId(),r=$msg({from:this._connection.jid,to:e,id:i}).c("x",{xmlns:Strophe.NS.MUC_USER}).c("invite",{to:t}),n!=null&&r.c("reason",n),this._connection.send(r),i},directInvite:function(e,t,n,r){var i,s,o;return o=this._connection.getUniqueId(),i={xmlns:"jabber:x:conference",jid:e},n!=null&&(i.reason=n),r!=null&&(i.password=r),s=$msg({from:this._connection.jid,to:t,id:o}).c("x",i),this._connection.send(s),o},queryOccupants:function(e,t,n){var r,i;return r={xmlns:Strophe.NS.DISCO_ITEMS},i=$iq({from:this._connection.jid,to:e,type:"get"}).c("query",r),this._connection.sendIQ(i,t,n)},configure:function(e,t,n){var r,i;return r=$iq({to:e,type:"get"}).c("query",{xmlns:Strophe.NS.MUC_OWNER}),i=r.tree(),this._connection.sendIQ(i,t,n)},cancelConfigure:function(e){var t,n;return t=$iq({to:e,type:"set"}).c("query",{xmlns:Strophe.NS.MUC_OWNER}).c("x",{xmlns:"jabber:x:data",type:"cancel"}),n=t.tree(),this._connection.sendIQ(n)},saveConfiguration:function(e,t,n,r){var i,s,o,u,a;s=$iq({to:e,type:"set"}).c("query",{xmlns:Strophe.NS.MUC_OWNER});if(typeof Form!="undefined"&&t instanceof Form)t.type="submit",s.cnode(t.toXML());else{s.c("x",{xmlns:"jabber:x:data",type:"submit"});for(u=0,a=t.length;u<a;u++)i=t[u],s.cnode(i).up()}return o=s.tree(),this._connection.sendIQ(o,n,r)},createInstantRoom:function(e,t,n){var r;return r=$iq({to:e,type:"set"}).c("query",{xmlns:Strophe.NS.MUC_OWNER}).c("x",{xmlns:"jabber:x:data",type:"submit"}),this._connection.sendIQ(r.tree(),t,n)},setTopic:function(e,t){var n;return n=$msg({to:e,from:this._connection.jid,type:"groupchat"}).c("subject",{xmlns:"jabber:client"}).t(t),this._connection.send(n.tree())},_modifyPrivilege:function(e,t,n,r,i){var s;return s=$iq({to:e,type:"set"}).c("query",{xmlns:Strophe.NS.MUC_ADMIN}).cnode(t.node),n!=null&&s.c("reason",n),this._connection.sendIQ(s.tree(),r,i)},modifyRole:function(e,t,n,r,i,s){var o;return o=$build("item",{nick:t,role:n}),this._modifyPrivilege(e,o,r,i,s)},kick:function(e,t,n,r,i){return this.modifyRole(e,t,"none",n,r,i)},voice:function(e,t,n,r,i){return this.modifyRole(e,t,"participant",n,r,i)},mute:function(e,t,n,r,i){return this.modifyRole(e,t,"visitor",n,r,i)},op:function(e,t,n,r,i){return this.modifyRole(e,t,"moderator",n,r,i)},deop:function(e,t,n,r,i){return this.modifyRole(e,t,"participant",n,r,i)},modifyAffiliation:function(e,t,n,r,i,s){var o;return o=$build("item",{jid:t,affiliation:n}),this._modifyPrivilege(e,o,r,i,s)},ban:function(e,t,n,r,i){return this.modifyAffiliation(e,t,"outcast",n,r,i)},member:function(e,t,n,r,i){return this.modifyAffiliation(e,t,"member",n,r,i)},revoke:function(e,t,n,r,i){return this.modifyAffiliation(e,t,"none",n,r,i)},owner:function(e,t,n,r,i){return this.modifyAffiliation(e,t,"owner",n,r,i)},admin:function(e,t,n,r,i){return this.modifyAffiliation(e,t,"admin",n,r,i)},changeNick:function(e,t){var n,r;return r=this.test_append_nick(e,t),n=$pres({from:this._connection.jid,to:r,id:this._connection.getUniqueId()}),this._connection.send(n.tree())},setStatus:function(e,t,n,r){var i,s;return s=this.test_append_nick(e,t),i=$pres({from:this._connection.jid,to:s}),n!=null&&i.c("show",n).up(),r!=null&&i.c("status",r),this._connection.send(i.tree())},listRooms:function(e,t,n){var r;return r=$iq({to:e,from:this._connection.jid,type:"get"}).c("query",{xmlns:Strophe.NS.DISCO_ITEMS}),this._connection.sendIQ(r,t,n)},test_append_nick:function(e,t){return e+(t!=null?"/"+Strophe.escapeNode(t):"")}}),n=function(){function t(e,t,n,i){this.client=e,this.name=t,this.nick=n,this.password=i,this._roomRosterHandler=r(this._roomRosterHandler,this),this._addOccupant=r(this._addOccupant,this),this.roster={},this._message_handlers={},this._presence_handlers={},this._roster_handlers={},this._handler_ids=0,e.muc&&(this.client=e.muc),this.name=Strophe.getBareJidFromJid(t),this.addHandler("presence",this._roomRosterHandler)}return t.prototype.join=function(e,t,n){return this.client.join(this.name,this.nick,e,t,n,this.password)},t.prototype.leave=function(e,t){return this.client.leave(this.name,this.nick,e,t),delete this.client.rooms[this.name]},t.prototype.message=function(e,t,n,r){return this.client.message(this.name,e,t,n,r)},t.prototype.groupchat=function(e,t){return this.client.groupchat(this.name,e,t)},t.prototype.invite=function(e,t){return this.client.invite(this.name,e,t)},t.prototype.directInvite=function(e,t){return this.client.directInvite(this.name,e,t,this.password)},t.prototype.configure=function(e){return this.client.configure(this.name,e)},t.prototype.cancelConfigure=function(){return this.client.cancelConfigure(this.name)},t.prototype.saveConfiguration=function(e){return this.client.saveConfiguration(this.name,e)},t.prototype.queryOccupants=function(e,t){return this.client.queryOccupants(this.name,e,t)},t.prototype.setTopic=function(e){return this.client.setTopic(this.name,e)},t.prototype.modifyRole=function(e,t,n,r,i){return this.client.modifyRole(this.name,e,t,n,r,i)},t.prototype.kick=function(e,t,n,r){return this.client.kick(this.name,e,t,n,r)},t.prototype.voice=function(e,t,n,r){return this.client.voice(this.name,e,t,n,r)},t.prototype.mute=function(e,t,n,r){return this.client.mute(this.name,e,t,n,r)},t.prototype.op=function(e,t,n,r){return this.client.op(this.name,e,t,n,r)},t.prototype.deop=function(e,t,n,r){return this.client.deop(this.name,e,t,n,r)},t.prototype.modifyAffiliation=function(e,t,n,r,i){return this.client.modifyAffiliation(this.name,e,t,n,r,i)},t.prototype.ban=function(e,t,n,r){return this.client.ban(this.name,e,t,n,r)},t.prototype.member=function(e,t,n,r){return this.client.member(this.name,e,t,n,r)},t.prototype.revoke=function(e,t,n,r){return this.client.revoke(this.name,e,t,n,r)},t.prototype.owner=function(e,t,n,r){return this.client.owner(this.name,e,t,n,r)},t.prototype.admin=function(e,t,n,r){return this.client.admin(this.name,e,t,n,r)},t.prototype.changeNick=function(e){return this.nick=e,this.client.changeNick(this.name,e)},t.prototype.setStatus=function(e,t){return this.client.setStatus(this.name,this.nick,e,t)},t.prototype.addHandler=function(e,t){var n;n=this._handler_ids++;switch(e){case"presence":this._presence_handlers[n]=t;break;case"message":this._message_handlers[n]=t;break;case"roster":this._roster_handlers[n]=t;break;default:return this._handler_ids--,null}return n},t.prototype.removeHandler=function(e){return delete this._presence_handlers[e],delete this._message_handlers[e],delete this._roster_handlers[e]},t.prototype._addOccupant=function(t){var n;return n=new e(t,this),this.roster[n.nick]=n,n},t.prototype._roomRosterHandler=function(e){var n,r,i,s,o,u;n=t._parsePresence(e),o=n.nick,s=n.newnick||null;switch(n.type){case"error":return;case"unavailable":s&&(n.nick=s,this.roster[o]&&this.roster[s]&&(this.roster[o].update(this.roster[s]),this.roster[s]=this.roster[o]),this.roster[o]&&!this.roster[s]&&(this.roster[s]=this.roster[o].update(n))),delete this.roster[o];break;default:this.roster[o]?this.roster[o].update(n):this._addOccupant(n)}u=this._roster_handlers;for(i in u)r=u[i],r(this.roster,this)||delete this._roster_handlers[i];return!0},t._parsePresence=function(e){var t,n,r,i,s,o,u,a,f,l,c,h,p,d,v,m;i={},t=e.attributes,i.nick=Strophe.getResourceFromJid(t.from.textContent),i.type=((f=t.type)!=null?f.textContent:void 0)||null,i.states=[],l=e.childNodes;for(s=0,u=l.length;s<u;s++){n=l[s];switch(n.nodeName){case"status":i.status=n.textContent||null;break;case"show":i.show=n.textContent||null;break;case"x":t=n.attributes;if(((c=t.xmlns)!=null?c.textContent:void 0)===Strophe.NS.MUC_USER){h=n.childNodes;for(o=0,a=h.length;o<a;o++){r=h[o];switch(r.nodeName){case"item":t=r.attributes,i.affiliation=((p=t.affiliation)!=null?p.textContent:void 0)||null,i.role=((d=t.role)!=null?d.textContent:void 0)||null,i.jid=((v=t.jid)!=null?v.textContent:void 0)||null,i.newnick=((m=t.nick)!=null?m.textContent:void 0)||null;break;case"status":r.attributes.code&&i.states.push(r.attributes.code.textContent)}}}}}return i},t}(),t=function(){function e(e){this.parse=r(this.parse,this),e!=null&&this.parse(e)}return e.prototype.parse=function(e){var t,n,r,i,s,o,u,a,f,l,c,h,p;o=e.getElementsByTagName("query")[0].childNodes,this.identities=[],this.features=[],this.x=[];for(u=0,l=o.length;u<l;u++){r=o[u],n=r.attributes;switch(r.nodeName){case"identity":s={};for(a=0,c=n.length;a<c;a++)t=n[a],s[t.name]=t.textContent;this.identities.push(s);break;case"feature":this.features.push(n["var"].textContent);break;case"x":n=r.childNodes[0].attributes;if(!n["var"].textContent==="FORM_TYPE"||!n.type.textContent==="hidden")break;p=r.childNodes;for(f=0,h=p.length;f<h;f++){i=p[f];if(!!i.attributes.type)continue;n=i.attributes,this.x.push({"var":n["var"].textContent,label:n.label.textContent||"",value:i.firstChild.textContent||""})}}}return{identities:this.identities,features:this.features,x:this.x}},e}(),e=function(){function e(e,t){this.room=t,this.update=r(this.update,this),this.admin=r(this.admin,this),this.owner=r(this.owner,this),this.revoke=r(this.revoke,this),this.member=r(this.member,this),this.ban=r(this.ban,this),this.modifyAffiliation=r(this.modifyAffiliation,this),this.deop=r(this.deop,this),this.op=r(this.op,this),this.mute=r(this.mute,this),this.voice=r(this.voice,this),this.kick=r(this.kick,this),this.modifyRole=r(this.modifyRole,this),this.update(e)}return e.prototype.modifyRole=function(e,t,n,r){return this.room.modifyRole(this.nick,e,t,n,r)},e.prototype.kick=function(e,t,n){return this.room.kick(this.nick,e,t,n)},e.prototype.voice=function(e,t,n){return this.room.voice(this.nick,e,t,n)},e.prototype.mute=function(e,t,n){return this.room.mute(this.nick,e,t,n)},e.prototype.op=function(e,t,n){return this.room.op(this.nick,e,t,n)},e.prototype.deop=function(e,t,n){return this.room.deop(this.nick,e,t,n)},e.prototype.modifyAffiliation=function(e,t,n,r){return this.room.modifyAffiliation(this.jid,e,t,n,r)},e.prototype.ban=function(e,t,n){return this.room.ban(this.jid,e,t,n)},e.prototype.member=function(e,t,n){return this.room.member(this.jid,e,t,n)},e.prototype.revoke=function(e,t,n){return this.room.revoke(this.jid,e,t,n)},e.prototype.owner=function(e,t,n){return this.room.owner(this.jid,e,t,n)},e.prototype.admin=function(e,t,n){return this.room.admin(this.jid,e,t,n)},e.prototype.update=function(e){return this.nick=e.nick||null,this.affiliation=e.affiliation||null,this.role=e.role||null,this.jid=e.jid||null,this.status=e.status||null,this.show=e.show||null,this},e}()}.call(this),define("strophe.muc",function(){}),Strophe.addConnectionPlugin("roster",{_connection:null,_callbacks:[],items:[],ver:null,init:function(e){this._connection=e,this.items=[];var t,n=this,r=e.connect,i=e.attach,s=function(r){if(r==Strophe.Status.ATTACHED||r==Strophe.Status.CONNECTED)try{e.addHandler(n._onReceivePresence.bind(n),null,"presence",null,null,null),e.addHandler(n._onReceiveIQ.bind(n),Strophe.NS.ROSTER,"iq","set",null,null)}catch(i){Strophe.error(i)}t!==null&&t.apply(this,arguments)};e.connect=function(n,i,o,u,a){t=o,typeof arguments[0]=="undefined"&&(arguments[0]=null),typeof arguments[1]=="undefined"&&(arguments[1]=null),arguments[2]=s,r.apply(e,arguments)},e.attach=function(n,r,o,u,a,f,l){t=u,typeof arguments[0]=="undefined"&&(arguments[0]=null),typeof arguments[1]=="undefined"&&(arguments[1]=null),typeof arguments[2]=="undefined"&&(arguments[2]=null),arguments[3]=s,i.apply(e,arguments)},Strophe.addNamespace("ROSTER_VER","urn:xmpp:features:rosterver"),Strophe.addNamespace("NICK","http://jabber.org/protocol/nick")},supportVersioning:function(){return this._connection.features&&this._connection.features.getElementsByTagName("ver").length>0},get:function(e,t,n){var r={xmlns:Strophe.NS.ROSTER};this.items=[],this.supportVersioning()&&(r.ver=t||"",this.items=n||[]);var i=$iq({type:"get",id:this._connection.getUniqueId("roster")}).c("query",r);return this._connection.sendIQ(i,this._onReceiveRosterSuccess.bind(this,e),this._onReceiveRosterError.bind(this,e))},registerCallback:function(e){this._callbacks.push(e)},findItem:function(e){for(var t=0;t<this.items.length;t++)if(this.items[t]&&this.items[t].jid==e)return this.items[t];return!1},removeItem:function(e){for(var t=0;t<this.items.length;t++)if(this.items[t]&&this.items[t].jid==e)return this.items.splice(t,1),!0;return!1},subscribe:function(e,t,n){var r=$pres({to:e,type:"subscribe"});t&&t!==""&&r.c("status").t(t),n&&n!==""&&r.c("nick",{xmlns:Strophe.NS.NICK}).t(n),this._connection.send(r)},unsubscribe:function(e,t){var n=$pres({to:e,type:"unsubscribe"});t&&t!=""&&n.c("status").t(t),this._connection.send(n)},authorize:function(e,t){var n=$pres({to:e,type:"subscribed"});t&&t!=""&&n.c("status").t(t),this._connection.send(n)},unauthorize:function(e,t){var n=$pres({to:e,type:"unsubscribed"});t&&t!=""&&n.c("status").t(t),this._connection.send(n)},add:function(e,t,n,r){var i=$iq({type:"set"}).c("query",{xmlns:Strophe.NS.ROSTER}).c("item",{jid:e,name:t});for(var s=0;s<n.length;s++)i.c("group").t(n[s]).up();this._connection.sendIQ(i,r,r)},update:function(e,t,n,r){var i=this.findItem(e);if(!i)throw"item not found";var s=t||i.name,o=n||i.groups,u=$iq({type:"set"}).c("query",{xmlns:Strophe.NS.ROSTER}).c("item",{jid:i.jid,name:s});for(var a=0;a<o.length;a++)u.c("group").t(o[a]).up();return this._connection.sendIQ(u,r,r)},remove:function(e,t){var n=this.findItem(e);if(!n)throw"item not found";var r=$iq({type:"set"}).c("query",{xmlns:Strophe.NS.ROSTER}).c("item",{jid:n.jid,subscription:"remove"});this._connection.sendIQ(r,t,t)},_onReceiveRosterSuccess:function(e,t){this._updateItems(t),e(this.items)},_onReceiveRosterError:function(e,t){e(this.items)},_onReceivePresence:function(e){var t=e.getAttribute("from"),n=Strophe.getBareJidFromJid(t),r=this.findItem(n);if(!r)return!0;var i=e.getAttribute("type");if(i=="unavailable")delete r.resources[Strophe.getResourceFromJid(t)];else{if(!!i)return!0;r.resources[Strophe.getResourceFromJid(t)]={show:e.getElementsByTagName("show").length!=0?Strophe.getText(e.getElementsByTagName("show")[0]):"",status:e.getElementsByTagName("status").length!=0?Strophe.getText(e.getElementsByTagName("status")[0]):"",priority:e.getElementsByTagName("priority").length!=0?Strophe.getText(e.getElementsByTagName("priority")[0]):""}}return this._call_backs(this.items,r),!0},_call_backs:function(e,t){for(var n=0;n<this._callbacks.length;n++)this._callbacks[n](e,t)},_onReceiveIQ:function(e){var t=e.getAttribute("id"),n=e.getAttribute("from");if(n&&n!=""&&n!=this._connection.jid&&n!=Strophe.getBareJidFromJid(this._connection.jid))return!0;var r=$iq({type:"result",id:t,from:this._connection.jid});return this._connection.send(r),this._updateItems(e),!0},_updateItems:function(e){var t=e.getElementsByTagName("query");if(t.length!=0){this.ver=t.item(0).getAttribute("ver");var n=this;Strophe.forEachChild(t.item(0),"item",function(e){n._updateItem(e)})}this._call_backs(this.items)},_updateItem:function(e){var t=e.getAttribute("jid"),n=e.getAttribute("name"),r=e.getAttribute("subscription"),i=e.getAttribute("ask"),s=[];Strophe.forEachChild(e,"group",function(e){s.push(Strophe.getText(e))});if(r=="remove"){this.removeItem(t);return}var e=this.findItem(t);e?(e.name=n,e.subscription=r,e.ask=i,e.groups=s):this.items.push({name:n,jid:t,subscription:r,ask:i,groups:s,resources:{}})}}),define("strophe.roster",function(){});var buildIq;buildIq=function(e,t,n){var r;return r=$iq(t?{type:e,to:t}:{type:e}),r.c("vCard",{xmlns:Strophe.NS.VCARD}),n&&r.cnode(n),r},Strophe.addConnectionPlugin("vcard",{_connection:null,init:function(e){return this._connection=e,Strophe.addNamespace("VCARD","vcard-temp")},get:function(e,t,n){var r;return r=buildIq("get",t),this._connection.sendIQ(r,e,n)},set:function(e,t,n,r){var i;return i=buildIq("set",n,t),this._connection.sendIQ(i,e,error_rb)}}),define("strophe.vcard",function(){}),Strophe.addConnectionPlugin("disco",{_connection:null,_identities:[],_features:[],_items:[],init:function(e){this._connection=e,this._identities=[],this._features=[],this._items=[],e.addHandler(this._onDiscoInfo.bind(this),Strophe.NS.DISCO_INFO,"iq","get",null,null),e.addHandler(this._onDiscoItems.bind(this),Strophe.NS.DISCO_ITEMS,"iq","get",null,null)},addIdentity:function(e,t,n,r){for(var i=0;i<this._identities.length;i++)if(this._identities[i].category==e&&this._identities[i].type==t&&this._identities[i].name==n&&this._identities[i].lang==r)return!1;return this._identities.push({category:e,type:t,name:n,lang:r}),!0},addFeature:function(e){for(var t=0;t<this._features.length;t++)if(this._features[t]==e)return!1;return this._features.push(e),!0},removeFeature:function(e){for(var t=0;t<this._features.length;t++)if(this._features[t]===e)return this._features.splice(t,1),!0;return!1},addItem:function(e,t,n,r){return n&&!r?!1:(this._items.push({jid:e,name:t,node:n,call_back:r}),!0)},info:function(e,t,n,r,i){var s={xmlns:Strophe.NS.DISCO_INFO};t&&(s.node=t);var o=$iq({from:this._connection.jid,to:e,type:"get"}).c("query",s);this._connection.sendIQ(o,n,r,i)},items:function(e,t,n,r,i){var s={xmlns:Strophe.NS.DISCO_ITEMS};t&&(s.node=t);var o=$iq({from:this._connection.jid,to:e,type:"get"}).c("query",s);this._connection.sendIQ(o,n,r,i)},_buildIQResult:function(e,t){var n=e.getAttribute("id"),r=e.getAttribute("from"),i=$iq({type:"result",id:n});return r!==null&&i.attrs({to:r}),i.c("query",t)},_onDiscoInfo:function(e){var t=e.getElementsByTagName("query")[0].getAttribute("node"),n={xmlns:Strophe.NS.DISCO_INFO};t&&(n.node=t);var r=this._buildIQResult(e,n);for(var i=0;i<this._identities.length;i++){var n={category:this._identities[i].category,type:this._identities[i].type};this._identities[i].name&&(n.name=this._identities[i].name),this._identities[i].lang&&(n["xml:lang"]=this._identities[i].lang),r.c("identity",n).up()}for(var i=0;i<this._features.length;i++)r.c("feature",{"var":this._features[i]}).up();return this._connection.send(r.tree()),!0},_onDiscoItems:function(e){var t={xmlns:Strophe.NS.DISCO_ITEMS},n=e.getElementsByTagName("query")[0].getAttribute("node");if(n){t.node=n;var r=[];for(var i=0;i<this._items.length;i++)if(this._items[i].node==n){r=this._items[i].call_back(e);break}}else var r=this._items;var s=this._buildIQResult(e,t);for(var i=0;i<r.length;i++){var o={jid:r[i].jid};r[i].name&&(o.name=r[i].name),r[i].node&&(o.node=r[i].node),s.c("item",o).up()}return this._connection.send(s.tree()),!0}}),define("strophe.disco",function(){}),define("converse-dependencies",["otr","locales","backbone.localStorage","jquery.tinysort","strophe","strophe.muc","strophe.roster","strophe.vcard","strophe.disco"],function(e){return e}),function(e,t){if(typeof console=="undefined"||typeof console.log=="undefined")console={log:function(){},error:function(){}};typeof define=="function"&&define.amd?define("converse",["converse-dependencies"],function(e){return _.templateSettings={evaluate:/\{\[([\s\S]+?)\]\}/g,interpolate:/\{\{([\s\S]+?)\}\}/g},typeof e!="undefined"?t(jQuery,_,e.OTR,e.DSA,console):t(jQuery,_,undefined,undefined,console)}):(_.templateSettings={evaluate:/\{\[([\s\S]+?)\]\}/g,interpolate:/\{\{([\s\S]+?)\}\}/g},typeof OTR!="undefined"&&typeof DSA!="undefined"?e.converse=t(jQuery,_,OTR,DSA,console):e.converse=t(jQuery,_,undefined,undefined,console))}(this,function(e,t,n,r,i){e.fn.addHyperlinks=function(){return this.length>0&&this.each(function(t,n){var r=e(n).html(),i=r.match(/\b(https?:\/\/|www\.|https?:\/\/www\.)[^\s<]{2,200}\b/g);if(i)for(t=0;t<i.length;t++){var s=i[t].indexOf("http://")===0||i[t].indexOf("https://")===0?"":"http://";r=r.replace(i[t],"<a target='_blank' href='"+s+i[t]+"'>"+i[t]+"</a>")}e(n).html(r)}),this},e.fn.addEmoticons=function(){return s.show_emoticons&&this.length>0&&this.each(function(t,n){var r=e(n).html();r=r.replace(/:\)/g,'<span class="emoticon icon-smiley"></span>'),r=r.replace(/:\-\)/g,'<span class="emoticon icon-smiley"></span>'),r=r.replace(/;\)/g,'<span class="emoticon icon-wink"></span>'),r=r.replace(/;\-\)/g,'<span class="emoticon icon-wink"></span>'),r=r.replace(/:D/g,'<span class="emoticon icon-grin"></span>'),r=r.replace(/:\-D/g,'<span class="emoticon icon-grin"></span>'),r=r.replace(/:P/g,'<span class="emoticon icon-tongue"></span>'),r=r.replace(/:\-P/g,'<span class="emoticon icon-tongue"></span>'),r=r.replace(/:p/g,'<span class="emoticon icon-tongue"></span>'),r=r.replace(/:\-p/g,'<span class="emoticon icon-tongue"></span>'),r=r.replace(/8\)/g,'<span class="emoticon icon-cool"></span>'),r=r.replace(/>:\)/g,'<span class="emoticon icon-evil"></span>'),r=r.replace(/:S/g,'<span class="emoticon icon-confused"></span>'),r=r.replace(/:\\/g,'<span class="emoticon icon-wondering"></span>'),r=r.replace(/:\/ /g,'<span class="emoticon icon-wondering"></span>'),r=r.replace(/>:\(/g,'<span class="emoticon icon-angry"></span>'),r=r.replace(/:\(/g,'<span class="emoticon icon-sad"></span>'),r=r.replace(/:\-\(/g,'<span class="emoticon icon-sad"></span>'),r=r.replace(/:O/g,'<span class="emoticon icon-shocked"></span>'),r=r.replace(/:\-O/g,'<span class="emoticon icon-shocked"></span>'),r=r.replace(/\=\-O/g,'<span class="emoticon icon-shocked"></span>'),r=r.replace(/\(\^.\^\)b/g,'<span class="emoticon icon-thumbs-up"></span>'),r=r.replace(/<3/g,'<span class="emoticon icon-heart"></span>'),e(n).html(r)}),this};var s={emit:function(t,n){e(this).trigger(t,n)},once:function(t,n){e(this).one(t,n)},on:function(t,n){e(this).bind(t,n)},off:function(t,n){e(this).unbind(t,n)}};return s.initialize=function(s,o){var u=this,a=0,f=1,l=2,c=3,h={ENTER:13},p=typeof crypto!="undefined"&&(typeof crypto.randomBytes=="function"||typeof crypto.getRandomValues=="function"),d=p&&typeof CryptoJS!="undefined"&&typeof n!="undefined"&&typeof r!="undefined";this.allow_contact_requests=!0,this.allow_muc=!0,this.allow_otr=!0,this.animate=!0,this.auto_list_rooms=!1,this.auto_reconnect=!0,this.auto_subscribe=!1,this.bosh_service_url=undefined,this.cache_otr_key=!1,this.debug=!1,this.expose_rid_and_sid=!1,this.hide_muc_server=!1,this.i18n=locales.en,this.prebind=!1,this.show_controlbox_by_default=!1,this.show_only_online_users=!1,this.show_call_button=!1,this.show_emoticons=!0,this.show_toolbar=!0,this.use_otr_by_default=!1,this.use_vcards=!0,this.xhr_custom_status=!1,this.xhr_custom_status_url="",this.xhr_user_search=!1,this.xhr_user_search_url="",t.extend(this,t.pick(s,["allow_contact_requests","allow_muc","allow_otr","animate","auto_list_rooms","auto_reconnect","auto_subscribe","bosh_service_url","cache_otr_key","connection","debug","expose_rid_and_sid","fullname","hide_muc_server","i18n","jid","prebind","rid","show_call_button","show_controlbox_by_default","show_emoticons","show_only_online_users","show_toolbar","sid","use_otr_by_default","use_vcards","xhr_custom_status","xhr_custom_status_url","xhr_user_search","xhr_user_search_url"])),this.allow_otr=this.allow_otr&&d,this.use_otr_by_default=this.use_otr_by_default&&this.allow_otr;var v=e.proxy(function(e){this.i18n===undefined&&(this.i18n=locales.en);var t=this.i18n.translate(e);return arguments.length>1?t.fetch.apply(t,[].slice.call(arguments,1)):t.fetch()},this),m=function(e){return e},g={};g[a]="unencrypted",g[f]="unverified",g[l]="verified",g[c]="finished";var y={};y[a]=v("unencrypted"),y[f]=v("unverified"),y[l]=v("verified"),y[c]=v("finished");var b={dnd:v("This contact is busy"),online:v("This contact is online"),offline:v("This contact is offline"),unavailable:v("This contact is unavailable"),xa:v("This contact is away for an extended period"),away:v("This contact is away")};this.callback=o||function(){},this.initial_presence_sent=0,this.msg_counter=0,this.giveFeedback=function(t,n){e(".conn-feedback").text(t),e(".conn-feedback").attr("class","conn-feedback"),n&&e(".conn-feedback").addClass(n)},this.log=function(e,t){this.debug&&(t=="error"?i.log("ERROR: "+e):i.log(e))},this.getVCard=function(n,r,i){if(!this.use_vcards){r&&r(n,n);return}u.connection.vcard.get(e.proxy(function(i){var s=e(i).find("vCard"),o=s.find("FN").text(),a=s.find("BINVAL").text(),f=s.find("TYPE").text(),l=s.find("URL").text();if(n){var c=u.roster.get(n);c&&(o=t.isEmpty(o)?c.get("fullname")||n:o,c.save({fullname:o,image_type:f,image:a,url:l,vcard_updated:u.toISOString(new Date)}))}r&&r(n,o,a,f,l)},this),n,function(e){var t=u.roster.get(n);t&&t.save({vcard_updated:u.toISOString(new Date)}),i&&i(e)})},this.reconnect=function(){u.giveFeedback(v("Reconnecting"),"error"),u.prebind||this.connection.connect(this.connection.jid,this.connection.pass,function(e,t){u.onConnect(e,t,!0)},this.connection.wait,this.connection.hold,this.connection.route)},this.showLoginButton=function(){var e=u.chatboxesview.views.controlbox;typeof e.loginpanel!="undefined"&&e.loginpanel.showLoginButton()},this.onConnect=function(e,t,n){var r,i;e===Strophe.Status.CONNECTED||e===Strophe.Status.ATTACHED?typeof n!="undefined"&&n?(u.log(e===Strophe.Status.CONNECTED?"Reconnected":"Reattached"),u.onReconnected()):(u.log(e===Strophe.Status.CONNECTED?"Connected":"Attached"),u.onConnected()):e===Strophe.Status.DISCONNECTED?(u.giveFeedback(v("Disconnected"),"error"),u.auto_reconnect?u.reconnect():u.showLoginButton()):e===Strophe.Status.Error?(u.showLoginButton(),u.giveFeedback(v("Error"),"error")):e===Strophe.Status.CONNECTING?u.giveFeedback(v("Connecting")):e===Strophe.Status.CONNFAIL?(u.showLoginButton(),u.giveFeedback(v("Connection Failed"),"error")):e===Strophe.Status.AUTHENTICATING?u.giveFeedback(v("Authenticating")):e===Strophe.Status.AUTHFAIL?(u.showLoginButton(),u.giveFeedback(v("Authentication Failed"),"error")):e===Strophe.Status.DISCONNECTING&&u.giveFeedback(v("Disconnecting"),"error")},this.toISOString=function(e){var t;return typeof e.toISOString!="undefined"?e.toISOString():(t=function(e){return e<10?"0"+e:""+e},e.getUTCFullYear()+"-"+t(e.getUTCMonth()+1)+"-"+t(e.getUTCDate())+"T"+t(e.getUTCHours())+":"+t(e.getUTCMinutes())+":"+t(e.getUTCSeconds())+".000Z")},this.parseISO8601=function(e){var t=[1,4,5,6,7,10,11],n=/^\s*(\d{4})-(\d{2})-(\d{2})T(\d{2}):(\d{2}):(\d{2}\.?\d*)Z\s*$/.exec(e),r=0,i,s;for(i=0;s=t[i];++i)n[s]=+n[s]||0;return n[2]=(+n[2]||1)-1,n[3]=+n[3]||1,n[8]!=="Z"&&n[9]!==undefined&&(r=n[10]*60+n[11],n[9]==="+"&&(r=0-r)),new Date(Date.UTC(n[1],n[2],n[3],n[4],n[5]+r,n[6],n[7]))},this.updateMsgCounter=function(){this.msg_counter>0?(document.title.search(/^Messages \(\d+\) /)==-1?document.title="Messages ("+this.msg_counter+") "+document.title:document.title=document.title.replace(/^Messages \(\d+\) /,"Messages ("+this.msg_counter+") "),window.blur(),window.focus()):document.title.search(/^Messages \(\d+\) /)!=-1&&(document.title=document.title.replace(/^Messages \(\d+\) /,""))},this.incrementMsgCounter=function(){this.msg_counter+=1,this.updateMsgCounter()},this.clearMsgCounter=function(){this.msg_counter=0,this.updateMsgCounter()},this.initStatus=function(e){this.xmppstatus=new this.XMPPStatus;var t=hex_sha1("converse.xmppstatus-"+this.bare_jid);this.xmppstatus.id=t,this.xmppstatus.localStorage=new Backbone.LocalStorage(t),this.xmppstatus.fetch({success:e,error:e})},this.registerRosterHandler=function(){this.connection.roster.registerCallback(e.proxy(this.roster.rosterHandler,this.roster),null,"presence",null)},this.registerRosterXHandler=function(){this.connection.addHandler(e.proxy(this.roster.subscribeToSuggestedItems,this.roster),"http://jabber.org/protocol/rosterx","message",null)},this.registerPresenceHandler=function(){this.connection.addHandler(e.proxy(function(e){return this.presenceHandler(e),!0},this.roster),null,"presence",null)},this.initRoster=function(){this.roster=new this.RosterItems,this.roster.localStorage=new Backbone.LocalStorage(hex_sha1("converse.rosteritems-"+u.bare_jid)),this.registerRosterHandler(),this.registerRosterXHandler(),this.registerPresenceHandler(),this.rosterview=new this.RosterView({model:this.roster})},this.registerGlobalEventHandlers=function(){e(document).click(function(){e(".toggle-otr ul").is(":visible")&&e(".toggle-otr ul",this).slideUp(),e(".toggle-smiley ul").is(":visible")&&e(".toggle-smiley ul",this).slideUp()}),e(window).on("blur focus",e.proxy(function(e){this.windowState!=e.type&&e.type=="focus"&&u.clearMsgCounter(),this.windowState=e.type},this))},this.onReconnected=function(){this.initStatus(e.proxy(function(){this.registerRosterXHandler(),this.registerPresenceHandler(),this.chatboxes.registerMessageHandler(),u.xmppstatus.sendPresence(),this.giveFeedback(v("Online Contacts"))},this))},this.onConnected=function(){this.debug&&(this.connection.xmlInput=function(e){i.log(e)},this.connection.xmlOutput=function(e){i.log(e)},Strophe.log=function(e,t){i.log(e+" "+t)},Strophe.error=function(e){i.log("ERROR: "+e)}),this.bare_jid=Strophe.getBareJidFromJid(this.connection.jid),this.domain=Strophe.getDomainFromJid(this.connection.jid),this.features=new this.Features,this.initStatus(e.proxy(function(){this.initRoster(),this.chatboxes.onConnected(),this.connection.roster.get(function(){}),this.registerGlobalEventHandlers(),this.giveFeedback(v("Online Contacts")),this.callback&&(this.connection.service==="jasmine tests"?this.callback(this):this.callback())},this)),u.emit("onReady")},this.OTR=Backbone.Model.extend({getSessionPassphrase:function(){if(u.prebind){var e=hex_sha1(u.connection.jid),t=window.sessionStorage[e];return typeof t=="undefined"&&(t=Math.floor(Math.random()*4294967295).toString(),window.sessionStorage[e]=t),t}return u.connection.pass},generatePrivateKey:function(){var e=new r,t=u.connection.jid;if(u.cache_otr_key){var n=CryptoJS.lib.PasswordBasedCipher,i=this.getSessionPassphrase();typeof i!="undefined"&&(window.sessionStorage[hex_sha1(t+"priv_key")]=n.encrypt(CryptoJS.algo.AES,e.packPrivate(),i).toString(),window.sessionStorage[hex_sha1(t+"instance_tag")]=instance_tag,window.sessionStorage[hex_sha1(t+"pass_check")]=n.encrypt(CryptoJS.algo.AES,"match",i).toString())}return e}}),this.Message=Backbone.Model.extend(),this.Messages=Backbone.Collection.extend({model:u.Message}),this.ChatBox=Backbone.Model.extend({initialize:function(){this.get("box_id")!=="controlbox"&&(this.messages=new u.Messages,this.messages.localStorage=new Backbone.LocalStorage(hex_sha1("converse.messages"+this.get("jid")+u.bare_jid)),this.set({user_id:Strophe.getNodeFromJid(this.get("jid")),box_id:hex_sha1(this.get("jid")),otr_status:this.get("otr_status")||a}))},getSession:function(e){var t=CryptoJS.lib.PasswordBasedCipher,i,s,o,a,f;if(u.cache_otr_key){s=u.otr.getSessionPassphrase();if(typeof s!="undefined"){o=window.sessionStorage[hex_sha1(this.id+"instance_tag")],a=window.sessionStorage[hex_sha1(this.id+"priv_key")],f=window.sessionStorage[hex_sha1(this.connection.jid+"pass_check")];if(a&&o&&typeof f!="undefined"){var l=t.decrypt(CryptoJS.algo.AES,a,s),c=r.parsePrivate(l.toString(CryptoJS.enc.Latin1));if(t.decrypt(CryptoJS.algo.AES,f,s).toString(CryptoJS.enc.Latin1)==="match"){this.trigger("showHelpMessages",[v("Re-establishing encrypted session")]),e({key:c,instance_tag:o});return}}}}this.trigger("showHelpMessages",[v("Generating private key."),v("Your browser might become unresponsive.")],null,!0),setTimeout(function(){e({key:u.otr.generatePrivateKey.apply(this),instance_tag:n.makeInstanceTag()})},500)},updateOTRStatus:function(e){switch(e){case n.CONST.STATUS_AKE_SUCCESS:this.otr.msgstate===n.CONST.MSGSTATE_ENCRYPTED&&this.save({otr_status:f});break;case n.CONST.STATUS_END_OTR:this.otr.msgstate===n.CONST.MSGSTATE_FINISHED?this.save({otr_status:c}):this.otr.msgstate===n.CONST.MSGSTATE_PLAINTEXT&&this.save({otr_status:a})}},onSMP:function(e,t){switch(e){case"question":this.otr.smpSecret(prompt(v("Authentication request from %1$s\n\nYour buddy is attempting to verify your identity, by asking you the question below.\n\n%2$s",[this.get("fullname"),t])));break;case"trust":t===!0?this.save({otr_status:l}):(this.trigger("showHelpMessages",[v("Could not verify this user's identify.")],"error"),this.save({otr_status:f}));break;default:throw new Error("Unknown type.")}},initiateOTR:function(t){this.save({otr_status:a});var r=this.getSession(e.proxy(function(r){this.otr=new n({fragment_size:140,send_interval:200,priv:r.key,instance_tag:r.instance_tag,debug:this.debug}),this.otr.on("status",e.proxy(this.updateOTRStatus,this)),this.otr.on("smp",e.proxy(this.onSMP,this)),this.otr.on("ui",e.proxy(function(e){this.trigger("showReceivedOTRMessage",e)},this)),this.otr.on("io",e.proxy(function(e){this.trigger("sendMessageStanza",e)},this)),this.otr.on("error",e.proxy(function(e){this.trigger("showOTRError",e)},this)),this.trigger("showHelpMessages",[v("Exchanging private key with buddy.")]),t?this.otr.receiveMsg(t):this.otr.sendQueryMsg()},this))},endOTR:function(){this.otr&&this.otr.endOtr(),this.save({otr_status:a})},createMessage:function(n){var r=e(n),i=r.children("body").text(),s=Strophe.getBareJidFromJid(r.attr("from")),o=r.find("composing"),a=r.find("delay").length>0,f=this.get("fullname"),l,c,h;f=(t.isEmpty(f)?s:f).split(" ")[0],i?(a?(l=r.find("delay").attr("stamp"),c=l):c=u.toISOString(new Date),s==u.bare_jid?h="me":h="them",this.messages.create({fullname:f,sender:h,delayed:a,time:c,message:i})):o.length&&this.messages.add({fullname:f,sender:"them",delayed:a,time:u.toISOString(new Date),composing:o.length})},messageReceived:function(n){var r=e(n).children("body"),i=r.length>0?r.text():undefined;if(!i||!u.allow_otr)return this.createMessage(n);i.match(/^\?OTRv23?/)?this.initiateOTR(i):t.contains([f,l],this.get("otr_status"))?this.otr.receiveMsg(i):i.match(/^\?OTR/)?this.otr?this.otr.receiveMsg(i):this.initiateOTR(i):this.createMessage(n)}}),this.ChatBoxView=Backbone.View.extend({length:200,tagName:"div",className:"chatbox",is_chatroom:!1,events:{"click .close-chatbox-button":"closeChat","keypress textarea.chat-textarea":"keyPressed","click .toggle-smiley":"toggleEmoticonMenu","click .toggle-smiley ul li":"insertEmoticon","click .toggle-otr":"toggleOTRMenu","click .start-otr":"startOTRFromToolbar","click .end-otr":"endOTR","click .auth-otr":"authOTR","click .toggle-call":"toggleCall"},template:t.template('<div class="chat-head chat-head-chatbox"><a class="close-chatbox-button icon-close"></a><a href="{{url}}" target="_blank" class="user"><div class="chat-title"> {{ fullname }} </div></a><p class="user-custom-message"><p/></div><div class="chat-content"></div><form class="sendXMPPMessage" action="" method="post">{[ if ('+u.show_toolbar+") { ]}"+'<ul class="chat-toolbar no-text-select"></ul>'+"{[ } ]}"+"<textarea "+'type="text" '+'class="chat-textarea" '+'placeholder="'+v("Personal message")+'"/>'+"</form>"),toolbar_template:t.template('{[ if (show_emoticons) { ]}<li class="toggle-smiley icon-happy" title="Insert a smilery"><ul><li><a class="icon-smiley" href="#" data-emoticon=":)"></a></li><li><a class="icon-wink" href="#" data-emoticon=";)"></a></li><li><a class="icon-grin" href="#" data-emoticon=":D"></a></li><li><a class="icon-tongue" href="#" data-emoticon=":P"></a></li><li><a class="icon-cool" href="#" data-emoticon="8)"></a></li><li><a class="icon-evil" href="#" data-emoticon=">:)"></a></li><li><a class="icon-confused" href="#" data-emoticon=":S"></a></li><li><a class="icon-wondering" href="#" data-emoticon=":\\"></a></li><li><a class="icon-angry" href="#" data-emoticon=">:("></a></li><li><a class="icon-sad" href="#" data-emoticon=":("></a></li><li><a class="icon-shocked" href="#" data-emoticon=":O"></a></li><li><a class="icon-thumbs-up" href="#" data-emoticon="(^.^)b"></a></li><li><a class="icon-heart" href="#" data-emoticon="<3"></a></li></ul></li>{[ } ]}{[ if ('+u.show_call_button+") { ]}"+'<li><a class="toggle-call icon-phone" title="Start a call"></a></li>'+"{[ } ]}"+"{[ if (allow_otr) { ]}"+'<li class="toggle-otr {{otr_status_class}}" title="{{otr_tooltip}}">'+'<span class="chat-toolbar-text">{{otr_translated_status}}</span>'+'{[ if (otr_status == "'+a+'") { ]}'+'<span class="icon-unlocked"></span>'+"{[ } ]}"+'{[ if (otr_status == "'+f+'") { ]}'+'<span class="icon-lock"></span>'+"{[ } ]}"+'{[ if (otr_status == "'+l+'") { ]}'+'<span class="icon-lock"></span>'+"{[ } ]}"+'{[ if (otr_status == "'+c+'") { ]}'+'<span class="icon-unlocked"></span>'+"{[ } ]}"+"<ul>"+'{[ if (otr_status == "'+a+'") { ]}'+'<li><a class="start-otr" href="#">'+v("Start encrypted conversation")+"</a></li>"+"{[ } ]}"+'{[ if (otr_status != "'+a+'") { ]}'+'<li><a class="start-otr" href="#">'+v("Refresh encrypted conversation")+"</a></li>"+'<li><a class="end-otr" href="#">'+v("End encrypted conversation")+"</a></li>"+'<li><a class="auth-otr" data-scheme="smp" href="#">'+v("Verify with SMP")+"</a></li>"+"{[ } ]}"+'{[ if (otr_status == "'+f+'") { ]}'+'<li><a class="auth-otr" data-scheme="fingerprint" href="#">'+v("Verify with fingerprints")+"</a></li>"+"{[ } ]}"+'<li><a href="http://www.cypherpunks.ca/otr/help/3.2.0/levels.php" target="_blank">'+v("What's this?")+"</a></li>"+"</ul>"+"</li>"+"{[ } ]}"),message_template:t.template('<div class="chat-message {{extra_classes}}"><span class="chat-message-{{sender}}">{{time}} {{username}}: </span><span class="chat-message-content">{{message}}</span></div>'),action_template:t.template('<div class="chat-message {{extra_classes}}"><span class="chat-message-{{sender}}">{{time}} **{{username}} </span><span class="chat-message-content">{{message}}</span></div>'),new_day_template:t.template('<time class="chat-date" datetime="{{isodate}}">{{datestring}}</time>'),initialize:function(){this.model.messages.on("add",this.onMessageAdded,this),this.model.on("show",this.show,this),this.model.on("destroy",this.hide,this),this.model.on("change",this.onChange,this),this.model.on("showOTRError",this.showOTRError,this),this.model.on("buddyStartsOTR",this.buddyStartsOTR,this),this.model.on("showHelpMessages",this.showHelpMessages,this),this.model.on("sendMessageStanza",this.sendMessageStanza,this),this.model.on("showSentOTRMessage",function(e){this.showOTRMessage(e,"me")},this),this.model.on("showReceivedOTRMessage",function(e){this.showOTRMessage(e,"them")},this),this.updateVCard(),this.$el.appendTo(u.chatboxesview.$el),this.render().show().model.messages.fetch({add:!0}),this.model.get("status")&&this.showStatusMessage(this.model.get("status")),(t.contains([f,l],this.model.get("otr_status"))||u.use_otr_by_default)&&this.model.initiateOTR()},render:function(){return this.$el.attr("id",this.model.get("box_id")).html(this.template(this.model.toJSON())),this.renderToolbar().renderAvatar(),this},showStatusNotification:function(t,n){var r=this.$el.find(".chat-content");r.find("div.chat-event").remove().end().append(e('<div class="chat-event"></div>').text(t)),this.scrollDown()},renderEmoticons:function(e){return u.show_emoticons&&(e=e.replace(/:\)/g,'<span class="emoticon icon-smiley"></span>'),e=e.replace(/:\-\)/g,'<span class="emoticon icon-smiley"></span>'),e=e.replace(/;\)/g,'<span class="emoticon icon-wink"></span>'),e=e.replace(/;\-\)/g,'<span class="emoticon icon-wink"></span>'),e=e.replace(/:D/g,'<span class="emoticon icon-grin"></span>'),e=e.replace(/:\-D/g,'<span class="emoticon icon-grin"></span>'),e=e.replace(/:P/g,'<span class="emoticon icon-tongue"></span>'),e=e.replace(/:\-P/g,'<span class="emoticon icon-tongue"></span>'),e=e.replace(/:p/g,'<span class="emoticon icon-tongue"></span>'),e=e.replace(/:\-p/g,'<span class="emoticon icon-tongue"></span>'),e=e.replace(/8\)/g,'<span class="emoticon icon-cool"></span>'),e=e.replace(/>:\)/g,'<span class="emoticon icon-evil"></span>'),e=e.replace(/:S/g,'<span class="emoticon icon-confused"></span>'),e=e.replace(/:\\/g,'<span class="emoticon icon-wondering"></span>'),e=e.replace(/:\//g,'<span class="emoticon icon-wondering"></span>'),e=e.replace(/>:\(/g,'<span class="emoticon icon-angry"></span>'),e=e.replace(/:\(/g,'<span class="emoticon icon-sad"></span>'),e=e.replace(/:\-\(/g,'<span class="emoticon icon-sad"></span>'),e=e.replace(/:O/g,'<span class="emoticon icon-shocked"></span>'),e=e.replace(/:\-O/g,'<span class="emoticon icon-shocked"></span>'),e=e.replace(/\=\-O/g,'<span class="emoticon icon-shocked"></span>'),e=e.replace(/\(\^.\^\)b/g,'<span class="emoticon icon-thumbs-up"></span>'),e=e.replace(/<3/g,'<span class="emoticon icon-heart"></span>')),e},showMessage:function(t,n){var r=u.parseISO8601(n.time),i=n.message,s=i.match(/^\/(.*?)(?: (.*))?$/),o=n.sender,a,f;s&&s[1]==="me"?(i=i.replace(/^\/me/,""),a=this.action_template,f=n.fullname):(a=this.message_template,f=o==="me"&&v("me")||n.fullname),t.find("div.chat-event").remove();var l=a({sender:o,time:r.toTimeString().substring(0,5),username:f,message:"",extra_classes:n.delayed&&"delayed"||""});return t.append(e(l).children(".chat-message-content").first().text(i).addHyperlinks().addEmoticons().parent()),this.scrollDown()},showOTRMessage:function(e,t){var n=t==="me"&&t||this.model.get("fullname"),r=this.$el.find(".chat-content");return r.find("div.chat-event").remove(),r.append(this.message_template({sender:t,time:(new Date).toTimeString().substring(0,5),message:e,username:n,extra_classes:""})),this.scrollDown()},showHelpMessages:function(t,n,r){var i=this.$el.find(".chat-content"),s,o=t.length;for(s=0;s<o;s++)i.append(e('<div class="chat-'+(n||"info")+'">'+t[s]+"</div>"));return r===!0?i.append('<span class="spinner"/>'):r===!1&&i.find("span.spinner").remove(),this.scrollDown()},onMessageAdded:function(e){var n=e.get("time"),r=this.model.messages.pluck("time"),i=u.parseISO8601(n),s=this.$el.find(".chat-content"),o,a,f,l,c,h;a=t.indexOf(r,n)-1,a>=0&&(o=this.model.messages.at(a),f=u.parseISO8601(o.get("time")),l=new Date(i.getTime()),l.setUTCHours(0,0,0,0),l=u.toISOString(l),this.isDifferentDay(f,i)&&s.append(this.new_day_template({isodate:l,datestring:i.toString().substring(0,15)})));if(e.get("composing")){this.showStatusNotification(e.get("fullname")+" "+"is typing");return}return this.showMessage(s,t.clone(e.attributes)),e.get("sender")!="me"&&u.windowState=="blur"&&u.incrementMsgCounter(),this.scrollDown()},isDifferentDay:function(e,t){return t.getDate()!=e.getDate()||t.getFullYear()!=e.getFullYear()||t.getMonth()!=e.getMonth()},sendMessageStanza:function(e){var t=(new Date).getTime(),n=this.model.get("jid"),r=$msg({from:u.connection.jid,to:n,type:"chat",id:t}).c("body").t(e).up().c("active",{xmlns:"http://jabber.org/protocol/chatstates"}),i=$msg({to:u.bare_jid,type:"chat",id:t}).c("forwarded",{xmlns:"urn:xmpp:forward:0"}).c("delay",{xmns:"urn:xmpp:delay",stamp:t}).up().cnode(r.tree());u.connection.send(r),u.connection.send(i)},sendMessage:function(e){var n=e.replace(/^\s*/,"").match(/^\/(.*)\s*$/),r;if(n){if(n[1]==="clear"){this.$el.find(".chat-content").empty(),this.model.messages.reset().localStorage._clear();return}if(n[1]==="help"){r=["<strong>/help</strong>:"+v("Show this menu")+"","<strong>/me</strong>:"+v("Write in the third person")+"","<strong>/clear</strong>:"+v("Remove messages")+""],this.showHelpMessages(r);return}if(u.allow_otr||n[1]==="endotr")return this.endOTR();if(u.allow_otr||n[1]==="otr")return this.model.initiateOTR()}if(t.contains([f,l],this.model.get("otr_status")))this.model.otr.sendMsg(e),this.model.trigger("showSentOTRMessage",e);else{var i=u.xmppstatus.get("fullname");i=t.isEmpty(i)?u.bare_jid:i,this.model.messages.create({fullname:i,sender:"me",time:u.toISOString(new Date),message:e}),this.sendMessageStanza(e)}},keyPressed:function(t){var n=e(t.target),r,i,s;t.keyCode==h.ENTER?(t.preventDefault(),r=n.val(),n.val("").focus(),r!==""&&(this.model.get("chatroom")?this.sendChatRoomMessage(r):this.sendMessage(r),u.emit("onMessageSend",r)),this.$el.data("composing",!1)):this.model.get("chatroom")||(s=this.$el.data("composing"),s||(t.keyCode!=47&&(i=$msg({to:this.model.get("jid"),type:"chat"}).c("composing",{xmlns:"http://jabber.org/protocol/chatstates"}),u.connection.send(i)),this.$el.data("composing",!0)))},insertEmoticon:function(t){t.stopPropagation(),this.$el.find(".toggle-smiley ul").slideToggle(200);var n=this.$el.find("textarea.chat-textarea"),r=n.val(),i=e(t.target);i=i.is("a")?i:i.children("a"),r&&r[r.length-1]!==" "&&(r+=" "),n.focus().val(r+i.data("emoticon")+" ")},toggleEmoticonMenu:function(e){e.stopPropagation(),this.$el.find(".toggle-smiley ul").slideToggle(200)},toggleOTRMenu:function(e){e.stopPropagation(),this.$el.find(".toggle-otr ul").slideToggle(200)},showOTRError:function(e){e=="Message cannot be sent at this time."?this.showHelpMessages([v("Your message could not be sent")],"error"):e=="Received an unencrypted message."?this.showHelpMessages([v("We received an unencrypted message")],"error"):e=="Received an unreadable encrypted message."?this.showHelpMessages([v("We received an unreadable encrypted message")],"error"):this.showHelpMessages(["Encryption error occured: "+e],"error"),i.log("OTR ERROR:"+e)},buddyStartsOTR:function(e){this.showHelpMessages([v("This user has requested an encrypted session.")]),this.model.initiateOTR()},startOTRFromToolbar:function(t){e(t.target).parent().parent().slideUp(),t.stopPropagation(),this.model.initiateOTR()},endOTR:function(e){typeof e!="undefined"&&(e.preventDefault(),e.stopPropagation()),this.model.endOTR()},authOTR:function(t){var n=e(t.target).data().scheme,r,i,s;n==="fingerprint"?(r=confirm(v("Here are the fingerprints, please confirm them with %1$s, outside of this chat.\n\nFingerprint for you, %2$s: %3$s\n\nFingerprint for %1$s: %4$s\n\nIf you have confirmed that the fingerprints match, click OK, otherwise click Cancel.",[this.model.get("fullname"),u.xmppstatus.get("fullname")||u.bare_jid,this.model.otr.priv.fingerprint(),this.model.otr.their_priv_pk.fingerprint()])),r===!0?this.model.save({otr_status:l}):this.model.save({otr_status:f})):n==="smp"?(alert(v("You will be prompted to provide a security question and then an answer to that question.\n\nYour buddy will then be prompted the same question and if they type the exact same answer (case sensitive), their identity will be verified.")),i=prompt(v("What is your security question?")),i&&(s=prompt(v("What is the answer to the security question?")),this.model.otr.smpSecret(s,i))):this.showHelpMessages([v("Invalid authentication scheme provided")],"error")},toggleCall:function(e){e.stopPropagation(),u.emit("onCallButtonClicked",{connection:u.connection,model:this.model})},onChange:function(e,n){if(t.has(e.changed,"chat_status")){var r=e.get("chat_status"),i=e.get("fullname");i=t.isEmpty(i)?e.get("jid"):i,this.$el.is(":visible")&&(r==="offline"?this.showStatusNotification(i+" "+"has gone offline"):r==="away"?this.showStatusNotification(i+" "+"has gone away"):r==="dnd"?this.showStatusNotification(i+" "+"is busy"):r==="online"&&this.$el.find("div.chat-event").remove()),u.emit("onBuddyStatusChanged",e.attributes,e.get("chat_status"))}t.has(e.changed,"status")&&(this.showStatusMessage(e.get("status")),u.emit("onBuddyStatusMessageChanged",e.attributes,e.get("status"))),t.has(e.changed,"image")&&this.renderAvatar(),t.has(e.changed,"otr_status")&&this.renderToolbar().informOTRChange()},showStatusMessage:function(e){this.$el.find("p.user-custom-message").text(e).attr("title",e)},closeChat:function(){u.connection?this.model.destroy():this.model.trigger("hide")},updateVCard:function(){var t=this.model.get("jid"),n=u.roster.get(t);n&&!n.get("vcard_updated")&&u.getVCard(t,e.proxy(function(e,t,n,r,i){this.model.save({fullname:t||e,url:i,image_type:r,image:n})},this),e.proxy(function(e){u.log("ChatBoxView.initialize: An error occured while fetching vcard")},this))},informOTRChange:function(){var e=this.model.toJSON(),t=[];return e.otr_status==a?t.push(v("Your messages are not encrypted anymore")):e.otr_status==f?t.push(v("Your messages are now encrypted but your buddy's identity has not been verified.")):e.otr_status==l?t.push(v("Your buddy's identify has been verified.")):e.otr_status==c&&t.push(v("Your buddy has ended encryption on their end, you should do the same.")),this.showHelpMessages(t,"info",!1)},renderToolbar:function(){if(u.show_toolbar){var e=this.model.toJSON();e.otr_status==a?e.otr_tooltip=v("Your messages are not encrypted. Click here to enable OTR encryption."):e.otr_status==f?e.otr_tooltip=v("Your messages are encrypted, but your buddy has not been verified."):e.otr_status==l?e.otr_tooltip=v("Your messages are encrypted and your buddy verified."):e.otr_status==c&&(e.otr_tooltip=v("Your buddy has closed their end of the private session, you should do the same")),e.allow_otr=u.allow_otr&&!this.is_chatroom,e.show_emoticons=u.show_emoticons,e.otr_translated_status=y[e.otr_status],e.otr_status_class=g[e.otr_status],this.$el.find(".chat-toolbar").html(this.toolbar_template(e))}return this},renderAvatar:function(){if(!this.model.get("image"))return;var t="data:"+this.model.get("image_type")+";base64,"+this.model.get("image"),n=e('<canvas height="33px" width="33px" class="avatar"></canvas>').get(0);if(!n.getContext||!n.getContext("2d"))return this;var r=n.getContext("2d"),i=new Image;return i.onload=function(){var e=i.width/i.height;r.drawImage(i,0,0,35*e,35)},i.src=t,this.$el.find(".chat-title").before(n),this},focus:function(){return this.$el.find(".chat-textarea").focus(),this},hide:function(){this.$el.is(":visible")&&this.$el.css("opacity")=="1"&&(u.animate?this.$el.hide("fast"):this.$el.hide(),u.emit("onChatBoxClosed",this))},show:function(){return this.$el.is(":visible")&&this.$el.css("opacity")=="1"?(u.emit("onChatBoxFocused",this),this.focus()):(u.animate?this.$el.css({opacity:0,display:"inline"}).animate({opacity:"1"},200):this.$el.css({opacity:1,display:"inline"}),u.connection&&this.model.save(),u.emit("onChatBoxOpened",this),this)},scrollDown:function(){var e=this.$el.find(".chat-content");return e.scrollTop(e[0].scrollHeight),this}}),this.ContactsPanel=Backbone.View.extend({tagName:"div",className:"oc-chat-content",id:"users",events:{"click a.toggle-xmpp-contact-form":"toggleContactForm","submit form.add-xmpp-contact":"addContactFromForm","submit form.search-xmpp-contact":"searchContacts","click a.subscribe-to-user":"addContactFromList"},tab_template:t.template('<li><a class="s current" href="#users">'+v("Contacts")+"</a></li>"),template:t.template('<form class="set-xmpp-status" action="" method="post"><span id="xmpp-status-holder"><select id="select-xmpp-status" style="display:none"><option value="online">'+v("Online")+"</option>"+'<option value="dnd">'+v("Busy")+"</option>"+'<option value="away">'+v("Away")+"</option>"+'<option value="offline">'+v("Offline")+"</option>"+"</select>"+"</span>"+"</form>"),add_contact_dropdown_template:t.template('<dl class="add-converse-contact dropdown"><dt id="xmpp-contact-search" class="fancy-dropdown"><a class="toggle-xmpp-contact-form" href="#"title="'+v("Click to add new chat contacts")+'">'+'<span class="icon-plus"></span>'+v("Add a contact")+"</a>"+"</dt>"+'<dd class="search-xmpp" style="display:none"><ul></ul></dd>'+"</dl>"),add_contact_form_template:t.template('<li><form class="add-xmpp-contact"><input type="text" name="identifier" class="username" placeholder="'+v("Contact username")+'"/>'+'<button type="submit">'+v("Add")+"</button>"+"</form>"+"<li>"),search_contact_template:t.template('<li><form class="search-xmpp-contact"><input type="text" name="identifier" class="username" placeholder="'+v("Contact name")+'"/>'+'<button type="submit">'+v("Search")+"</button>"+"</form>"+"<li>"),initialize:function(e){e.$parent.append(this.$el),this.$tabs=e.$parent.parent().find("#controlbox-tabs")},render:function(){var e,t=this.template();return this.$tabs.append(this.tab_template()),u.xhr_user_search?e=this.search_contact_template():e=this.add_contact_form_template(),u.allow_contact_requests&&(t+=this.add_contact_dropdown_template()),this.$el.html(t),this.$el.find(".search-xmpp ul").append(e),this.$el.append(u.rosterview.$el),this},toggleContactForm:function(t){t.preventDefault(),this.$el.find(".search-xmpp").toggle("fast",function(){e(this).is(":visible")&&e(this).find("input.username").focus()})},searchContacts:function(t){t.preventDefault(),e.getJSON(xhr_user_search_url+"?q="+e(t.target).find("input.username").val(),function(t){var n=e(".search-xmpp ul");n.find("li.found-user").remove(),n.find("li.chat-info").remove(),t.length||n.append('<li class="chat-info">'+v("No users found")+"</li>"),e(t).each(function(t,r){n.append(e('<li class="found-user"></li>').append(e('<a class="subscribe-to-user" href="#" title="'+v("Click to add as a chat contact")+'"></a>').attr("data-recipient",Strophe.escapeNode(r.id)+"@"+u.domain).text(r.fullname)))})})},addContactFromForm:function(t){t.preventDefault();var n=e(t.target).find("input"),r=n.val();if(!r){n.addClass("error");return}this.addContact(r),e(".search-xmpp").hide()},addContactFromList:function(t){t.preventDefault();var n=e(t.target),r=n.attr("data-recipient"),i=n.text();this.addContact(r,i),n.parent().remove(),e(".search-xmpp").hide()},addContact:function(e,n){n=t.isEmpty(n)?e:n,u.connection.roster.add(e,n,[],function(t){u.connection.roster.subscribe(e,null,u.xmppstatus.get("fullname"))})}}),this.RoomsPanel=Backbone.View.extend({tagName:"div",id:"chatrooms",events:{"submit form.add-chatroom":"createChatRoom","click input#show-rooms":"showRooms","click a.open-room":"createChatRoom","click a.room-info":"showRoomInfo"},room_template:t.template('<dd class="available-chatroom"><a class="open-room" data-room-jid="{{jid}}"title="'+v("Click to open this room")+'" href="#">{{name}}</a>'+'<a class="room-info icon-room-info" data-room-jid="{{jid}}"'+'title="'+v("Show more information on this room")+'" href="#"> </a>'+"</dd>"),room_description_template:t.template('<div class="room-info"><p class="room-info"><strong>'+v("Description:")+"</strong> {{desc}}</p>"+'<p class="room-info"><strong>'+v("Occupants:")+"</strong> {{occ}}</p>"+'<p class="room-info"><strong>'+v("Features:")+"</strong> <ul>"+"{[ if (passwordprotected) { ]}"+'<li class="room-info locked">'+v("Requires authentication")+"</li>"+"{[ } ]}"+"{[ if (hidden) { ]}"+'<li class="room-info">'+v("Hidden")+"</li>"+"{[ } ]}"+"{[ if (membersonly) { ]}"+'<li class="room-info">'+v("Requires an invitation")+"</li>"+"{[ } ]}"+"{[ if (moderated) { ]}"+'<li class="room-info">'+v("Moderated")+"</li>"+"{[ } ]}"+"{[ if (nonanonymous) { ]}"+'<li class="room-info">'+v("Non-anonymous")+"</li>"+"{[ } ]}"+"{[ if (open) { ]}"+'<li class="room-info">'+v("Open room")+"</li>"+"{[ } ]}"+"{[ if (persistent) { ]}"+'<li class="room-info">'+v("Permanent room")+"</li>"+"{[ } ]}"+"{[ if (publicroom) { ]}"+'<li class="room-info">'+v("Public")+"</li>"+"{[ } ]}"+"{[ if (semianonymous) { ]}"+'<li class="room-info">'+v("Semi-anonymous")+"</li>"+"{[ } ]}"+"{[ if (temporary) { ]}"+'<li class="room-info">'+v("Temporary room")+"</li>"+"{[ } ]}"+"{[ if (unmoderated) { ]}"+'<li class="room-info">'+v("Unmoderated")+"</li>"+"{[ } ]}"+"</p>"+"</div>"),tab_template:t.template('<li><a class="s" href="#chatrooms">'+v("Rooms")+"</a></li>"),template:t.template('<form class="add-chatroom" action="" method="post"><input type="text" name="chatroom" class="new-chatroom-name" placeholder="'+v("Room name")+'"/>'+'<input type="text" name="nick" class="new-chatroom-nick" placeholder="'+v("Nickname")+'"/>'+'<input type="{{ server_input_type }}" name="server" class="new-chatroom-server" placeholder="'+v("Server")+'"/>'+'<input type="submit" name="join" value="'+v("Join")+'"/>'+'<input type="button" name="show" id="show-rooms" value="'+v("Show rooms")+'"/>'+"</form>"+'<dl id="available-chatrooms"></dl>'),initialize:function(n){n.$parent.append(this.$el.html(this.template({server_input_type:u.hide_muc_server&&"hidden"||"text"})).hide()),this.$tabs=n.$parent.parent().find("#controlbox-tabs"),this.on("update-rooms-list",function(e){this.updateRoomsList()}),u.xmppstatus.on("change",e.proxy(function(e){if(!t.has(e.changed,"fullname"))return;var n=this.$el.find("input.new-chatroom-nick");n.is(":focus")||n.val(e.get("fullname"))},this))},render:function(){return this.$tabs.append(this.tab_template()),this},informNoRoomsFound:function(){var t=this.$el.find("#available-chatrooms");t.html("<dt>"+v("No rooms on %1$s",this.muc_domain)+"</dt>"),e("input#show-rooms").show().siblings("span.spinner").remove()},updateRoomsList:function(t){u.connection.muc.listRooms(this.muc_domain,e.proxy(function(t){var n,r,i,s,o=this,u=this.$el.find("#available-chatrooms");this.rooms=e(t).find("query").find("item");if(this.rooms.length){u.html("<dt>"+v("Rooms on %1$s",this.muc_domain)+"</dt>"),s=document.createDocumentFragment();for(i=0;i<this.rooms.length;i++)n=Strophe.unescapeNode(e(this.rooms[i]).attr("name")||e(this.rooms[i]).attr("jid")),r=e(this.rooms[i]).attr("jid"),s.appendChild(e(this.room_template({name:n,jid:r}))[0]);u.append(s),e("input#show-rooms").show().siblings("span.spinner").remove()}else this.informNoRoomsFound();return!0},this),e.proxy(function(e){this.informNoRoomsFound()},this))},showRooms:function(t){var n=this.$el.find("#available-chatrooms"),r=this.$el.find("input.new-chatroom-server"),i=r.val();if(!i){r.addClass("error");return}this.$el.find("input.new-chatroom-name").removeClass("error"),r.removeClass("error"),n.empty(),e("input#show-rooms").hide().after('<span class="spinner"/>'),this.muc_domain=i,this.updateRoomsList()},showRoomInfo:function(t){var n=t.target,r=e(n).parent("dd"),i=r.find("div.room-info");i.length?i.remove():(r.find("span.spinner").remove(),r.append('<span class="spinner hor_centered"/>'),u.connection.disco.info(e(n).attr("data-room-jid"),null,e.proxy(function(t){var n=e(t);r.find("span.spinner").replaceWith(this.room_description_template({desc:n.find('field[var="muc#roominfo_description"] value').text(),occ:n.find('field[var="muc#roominfo_occupants"] value').text(),hidden:n.find('feature[var="muc_hidden"]').length,membersonly:n.find('feature[var="muc_membersonly"]').length,moderated:n.find('feature[var="muc_moderated"]').length,nonanonymous:n.find('feature[var="muc_nonanonymous"]').length,open:n.find('feature[var="muc_open"]').length,passwordprotected:n.find('feature[var="muc_passwordprotected"]').length,persistent:n.find('feature[var="muc_persistent"]').length,publicroom:n.find('feature[var="muc_public"]').length,semianonymous:n.find('feature[var="muc_semianonymous"]').length,temporary:n.find('feature[var="muc_temporary"]').length,unmoderated:n.find('feature[var="muc_unmoderated"]').length}))},this)))},createChatRoom:function(t){t.preventDefault();var n,r,i,s,o,a=this.$el.find("input.new-chatroom-nick"),f=a.val(),l;f?a.removeClass("error"):a.addClass("error");if(t.type==="click")o=e(t.target).attr("data-room-jid");else{r=this.$el.find("input.new-chatroom-name"),s=this.$el.find("input.new-chatroom-server"),i=s.val(),n=r.val().trim().toLowerCase(),r.val("");if(!n||!i){n||r.addClass("error"),i||s.addClass("error");return}o=Strophe.escapeNode(n)+"@"+i,r.removeClass("error"),s.removeClass("error"),this.muc_domain=i}if(!f)return;l=u.chatboxesview.showChatBox({id:o,jid:o,name:Strophe.unescapeNode(Strophe.getNodeFromJid(o)),nick:f,chatroom:!0,box_id:hex_sha1(o)}),l.get("connected")||u.chatboxesview.views[o].connect(null)}}),this.ControlBoxView=u.ChatBoxView.extend({tagName:"div",className:"chatbox",id:"controlbox",events:{"click a.close-chatbox-button":"closeChat","click ul#controlbox-tabs li a":"switchTab"},initialize:function(){this.$el.appendTo(u.chatboxesview.$el),this.model.on("change",e.proxy(function(n,r){var i;if(t.has(n.changed,"connected")){this.render(),u.features.on("add",e.proxy(this.featureAdded,this));var s=u.features.findWhere({"var":"http://jabber.org/protocol/muc"});s&&this.featureAdded(s)}t.has(n.changed,"visible")&&n.changed.visible===!0&&this.show()},this)),this.model.on("show",this.show,this),this.model.on("destroy",this.hide,this),this.model.on("hide",this.hide,this),this.model.get("visible")&&this.show()},featureAdded:function(e){if(e.get("var")=="http://jabber.org/protocol/muc"&&u.allow_muc){this.roomspanel.muc_domain=e.get("from");var t=this.$el.find("input.new-chatroom-server");t.is(":focus")||t.val(this.roomspanel.muc_domain),u.auto_list_rooms&&this.roomspanel.trigger("update-rooms-list")}},template:t.template('<div class="chat-head oc-chat-head"><ul id="controlbox-tabs"></ul><a class="close-chatbox-button icon-close"></a></div><div class="controlbox-panes"></div>'),switchTab:function(t){t.preventDefault();var n=e(t.target),r=n.parent().siblings("li").children("a"),i=e(n.attr("href")),s=e(r.attr("href"));s.fadeOut("fast",function(){r.removeClass("current"),n.addClass("current"),i.fadeIn("fast",function(){})})},showHelpMessages:function(e){return},render:function(){return!u.prebind&&!u.connection?(this.$el.html(this.template(this.model.toJSON())),this.loginpanel=new u.LoginPanel({$parent:this.$el.find(".controlbox-panes"),model:this}),this.loginpanel.render()):this.contactspanel||(this.$el.html(this.template(this.model.toJSON())),this.contactspanel=new u.ContactsPanel({$parent:this.$el.find(".controlbox-panes")}),this.contactspanel.render(),u.xmppstatusview=new u.XMPPStatusView({model:u.xmppstatus}),u.xmppstatusview.render(),u.allow_muc&&(this.roomspanel=new u.RoomsPanel({$parent:this.$el.find(".controlbox-panes")}),this.roomspanel.render())),this}}),this.ChatRoomView=u.ChatBoxView.extend({length:300,tagName:"div",className:"chatroom",events:{"click a.close-chatbox-button":"closeChat","click a.configure-chatroom-button":"configureChatRoom","click .toggle-smiley":"toggleEmoticonMenu","click .toggle-smiley ul li":"insertEmoticon","keypress textarea.chat-textarea":"keyPressed"},info_template:t.template('<div class="chat-info">{{message}}</div>'),is_chatroom:!0,sendChatRoomMessage:function(e){var t=e.replace(/^\s*/,"").match(/^\/(.*?)(?: (.*))?$/)||[!1],n;switch(t[1]){case"msg":break;case"clear":this.$el.find(".chat-content").empty();break;case"topic":u.connection.muc.setTopic(this.model.get("jid"),t[2]);break;case"kick":u.connection.muc.kick(this.model.get("jid"),t[2]);break;case"ban":u.connection.muc.ban(this.model.get("jid"),t[2]);break;case"op":u.connection.muc.op(this.model.get("jid"),t[2]);break;case"deop":u.connection.muc.deop(this.model.get("jid"),t[2]);break;case"help":n=this.$el.find(".chat-content"),msgs=["<strong>/help</strong>:"+v("Show this menu")+"","<strong>/me</strong>:"+v("Write in the third person")+"","<strong>/topic</strong>:"+v("Set chatroom topic")+"","<strong>/kick</strong>:"+v("Kick user from chatroom")+"","<strong>/ban</strong>:"+v("Ban user from chatroom")+"","<strong>/clear</strong>:"+v("Remove messages")+""],this.showHelpMessages(msgs);break;default:this.last_msgid=u.connection.muc.groupchat(this.model.get("jid"),e)}},template:t.template('<div class="chat-head chat-head-chatroom"><a class="close-chatbox-button icon-close"></a><a class="configure-chatroom-button icon-wrench" style="display:none"></a><div class="chat-title"> {{ name }} </div><p class="chatroom-topic"><p/></div><div class="chat-body"><span class="spinner centered"/></div>'),chatarea_template:t.template('<div class="chat-area"><div class="chat-content"></div><form class="sendXMPPMessage" action="" method="post">{[ if ('+u.show_toolbar+") { ]}"+'<ul class="chat-toolbar no-text-select"></ul>'+"{[ } ]}"+'<textarea type="text" class="chat-textarea" '+'placeholder="'+v("Message")+'"/>'+"</form>"+"</div>"+'<div class="participants">'+'<ul class="participant-list"></ul>'+"</div>"),render:function(){return this.$el.attr("id",this.model.get("box_id")).html(this.template(this.model.toJSON())),this},renderChatArea:function(){return this.$el.find(".chat-area").length||(this.$el.find(".chat-body").empty().append(this.chatarea_template()),this.renderToolbar()),this},connect:function(n){t.has(u.connection.muc.rooms,this.model.get("jid"))?u.connection.muc.join(this.model.get("jid"),this.model.get("nick"),null,null,null,n):u.connection.muc.join(this.model.get("jid"),this.model.get("nick"),e.proxy(this.onChatRoomMessage,this),e.proxy(this.onChatRoomPresence,this),e.proxy(this.onChatRoomRoster,this),n)},initialize:function(){this.connect(null),this.model.messages.on("add",this.onMessageAdded,this),this.model.on("destroy",function(t,n,r){this.hide(),u.connection.muc.leave(this.model.get("jid"),this.model.get("nick"),e.proxy(this.onLeave,this),undefined)},this),this.$el.appendTo(u.chatboxesview.$el),this.render().show().model.messages.fetch({add:!0})},onLeave:function(){this.model.set("connected",!1)},form_input_template:t.template('<label>{{label}}<input name="{{name}}" type="{{type}}" value="{{value}}"></label>'),select_option_template:t.template('<option value="{{value}}">{{label}}</option>'),form_select_template:t.template('<label>{{label}}<select name="{{name}}">{{options}}</select></label>'),form_checkbox_template:t.template('<label>{{label}}<input name="{{name}}" type="{{type}}" {{checked}}"></label>'),renderConfigurationForm:function(t){var n=this.$el.find("form.chatroom-form"),r=e(t),i=r.find("field"),s=r.find("title").text(),o=r.find("instructions").text(),u,a,f=[],l={"text-private":"password","text-single":"textline","boolean":"checkbox",hidden:"hidden","list-single":"dropdown"};n.find("span.spinner").remove(),n.append(e("<legend>").text(s)),o!=s&&n.append(e("<p>").text(o));for(u=0;u<i.length;u++){$field=e(i[u]);if($field.attr("type")=="list-single"){f=[],$options=$field.find("option");for(a=0;a<$options.length;a++)f.push(this.select_option_template({value:e($options[a]).find("value").text(),label:e($options[a]).attr("label")}));n.append(this.form_select_template({name:$field.attr("var"),label:$field.attr("label"),options:f.join("")}))}else $field.attr("type")=="boolean"?n.append(this.form_checkbox_template({name:$field.attr("var"),type:l[$field.attr("type")],label:$field.attr("label")||"",checked:$field.find("value").text()==="1"&&'checked="1"'||""})):n.append(this.form_input_template({name:$field.attr("var"),type:l[$field.attr("type")],label:$field.attr("label")||"",value:$field.find("value").text()}))}n.append('<input type="submit" value="'+v("Save")+'"/>'),n.append('<input type="button" value="'+v("Cancel")+'"/>'),n.on("submit",e.proxy(this.saveConfiguration,this)),n.find("input[type=button]").on("click",e.proxy(this.cancelConfiguration,this))},field_template:t.template('<field var="{{name}}"><value>{{value}}</value></field>'),saveConfiguration:function(t){t.preventDefault();var n=this,r=e(t.target).find(":input:not([type=button]):not([type=submit])"),i=r.length,s=[];r.each(function(){var t=e(this),r;t.is("[type=checkbox]")?r=t.is(":checked")&&1||0:r=t.val();var o=e(n.field_template({name:t.attr("name"),value:r}))[0];s.push(o),--i||u.connection.muc.saveConfiguration(n.model.get("jid"),s,e.proxy(n.onConfigSaved,n),e.proxy(n.onErrorConfigSaved,n))}),this.$el.find("div.chatroom-form-container").hide(function(){e(this).remove(),n.$el.find(".chat-area").show(),n.$el.find(".participants").show()})},onConfigSaved:function(e){},onErrorConfigSaved:function(e){this.showStatusNotification(v("An error occurred while trying to save the form."))},cancelConfiguration:function(t){t.preventDefault();var n=this;this.$el.find("div.chatroom-form-container").hide(function(){e(this).remove(),n.$el.find(".chat-area").show(),n.$el.find(".participants").show()})},configureChatRoom:function(t){t.preventDefault();if(this.$el.find("div.chatroom-form-container").length)return;this.$el.find(".chat-area").hide(),this.$el.find(".participants").hide(),this.$el.find(".chat-body").append(e('<div class="chatroom-form-container"><form class="chatroom-form"><span class="spinner centered"/></form></div>')),u.connection.muc.configure(this.model.get("jid"),e.proxy(this.renderConfigurationForm,this))},submitPassword:function(e){e.preventDefault();var t=this.$el.find(".chatroom-form").find("input[type=password]").val();this.$el.find(".chatroom-form-container").replaceWith('<span class="spinner centered"/>'),this.connect(t)},renderPasswordForm:function(){this.$el.find("span.centered.spinner").remove(),this.$el.find(".chat-body").append(e('<div class="chatroom-form-container"><form class="chatroom-form"><legend>'+v("This chatroom requires a password")+"</legend>"+"<label>"+v("Password: ")+'<input type="password" name="password"/></label>'+'<input type="submit" value="'+v("Submit")+"/>"+"</form>"+"</div>")),this.$el.find(".chatroom-form").on("submit",e.proxy(this.submitPassword,this))},showDisconnectMessage:function(t){this.$el.find(".chat-area").remove(),this.$el.find(".participants").remove(),this.$el.find("span.centered.spinner").remove(),this.$el.find(".chat-body").append(e("<p>"+t+"</p>"))},infoMessages:{100:v("This room is not anonymous"),102:v("This room now shows unavailable members"),103:v("This room does not show unavailable members"),104:v("Non-privacy-related room configuration has changed"),170:v("Room logging is now enabled"),171:v("Room logging is now disabled"),172:v("This room is now non-anonymous"),173:v("This room is now semi-anonymous"),174:v("This room is now fully-anonymous"),201:v("A new room has been created"),210:v("Your nickname has been changed")},actionInfoMessages:{301:m("<strong>%1$s</strong> has been banned"),307:m("<strong>%1$s</strong> has been kicked out"),321:m("<strong>%1$s</strong> has been removed because of an affiliation change"),322:m("<strong>%1$s</strong> has been removed for not being a member")},disconnectMessages:{301:v("You have been banned from this room"),307:v("You have been kicked from this room"),321:v("You have been removed from this room because of an affiliation change"),322:v("You have been removed from this room because the room has changed to members-only and you're not a member"),332:v("You have been removed from this room because the MUC (Multi-user chat) service is being shut down.")},showStatusMessages:function(e,n){var r=this.$el.find(".chat-content"),i=e.find("status"),s=[],o=[],u=[],a,f;for(f=0;f<i.length;f++){var l=i[f].getAttribute("code");n?t.contains(t.keys(this.disconnectMessages),l)&&s.push(this.disconnectMessages[l]):t.contains(t.keys(this.infoMessages),l)?o.push(this.infoMessages[l]):t.contains(t.keys(this.actionInfoMessages),l)&&u.push(v(this.actionInfoMessages[l],Strophe.unescapeNode(Strophe.getResourceFromJid(e.attr("from")))))}if(s.length>0){for(f=0;f<s.length;f++)this.showDisconnectMessage(s[f]);this.model.set("connected",!1);return}this.renderChatArea();for(f=0;f<o.length;f++)r.append(this.info_template({message:o[f]}));for(f=0;f<u.length;f++)r.append(this.info_template({message:u[f]}));return this.scrollDown()},showErrorMessage:function(e,t){delete u.connection.muc[t.name],e.attr("type")=="auth"?e.find("not-authorized").length?this.renderPasswordForm():e.find("registration-required").length?this.showDisconnectMessage(v("You are not on the member list of this room")):e.find("forbidden").length&&this.showDisconnectMessage(v("You have been banned from this room")):e.attr("type")=="modify"?e.find("jid-malformed").length&&this.showDisconnectMessage(v("No nickname was specified")):e.attr("type")=="cancel"&&(e.find("not-allowed").length?this.showDisconnectMessage(v("You are not allowed to create new rooms")):e.find("not-acceptable").length?this.showDisconnectMessage(v("Your nickname doesn't conform to this room's policies")):e.find("conflict").length?this.showDisconnectMessage(v("Your nickname is already taken")):e.find("item-not-found").length?this.showDisconnectMessage(v("This room does not (yet) exist")):e.find("service-unavailable").length&&this.showDisconnectMessage(v("This room has reached it's maximum number of occupants")))},onChatRoomPresence:function(t,n){var r=n.nick,i=e(t),s=i.attr("from"),o=i.find("status[code='110']").length||s==n.name+"/"+Strophe.escapeNode(r),a;if(i.attr("type")==="error")this.model.set("connected",!1),this.showErrorMessage(i.find("error"),n);else{this.model.set("connected",!0),this.showStatusMessages(i,o);if(!this.model.get("connected"))return!0;i.find("status[code='201']").length&&u.connection.muc.createInstantRoom(n.name),o&&(a=i.find("item"),a.length&&a.attr("affiliation")=="owner"&&this.$el.find("a.configure-chatroom-button").show(),i.find("status[code='210']").length&&this.model.set({nick:Strophe.getResourceFromJid(s)}))}return!0},onChatRoomMessage:function(n){var r=e(n),i=r.children("body").text(),s=r.attr("from"),o=this.$el.find(".chat-content"),a=Strophe.getResourceFromJid(s),f=a&&Strophe.unescapeNode(a)||"",l=r.find("delay").length>0,c=r.children("subject").text(),h,p,d,m,g,y,b;l?(b=r.find("delay").attr("stamp"),d=u.parseISO8601(b)):d=new Date,g=o.find("time").map(function(){return e(this).attr("datetime")}).get(),m=new Date(d.getTime()),m.setUTCHours(0,0,0,0),y=u.toISOString(m),t.indexOf(g,y)==-1&&o.append(this.new_day_template({isodate:y,datestring:m.toString().substring(0,15)})),this.showStatusMessages(r),c&&(this.$el.find(".chatroom-topic").text(c).attr("title",c),o.append(this.info_template({message:v("Topic set by %1$s to: %2$s",f,c)})));if(!i)return!0;var w=f===this.model.get("nick")&&"me"||"room";return this.showMessage(o,{message:i,sender:w,fullname:f,time:u.toISOString(d)}),w==="room"&&u.emit("onMessage",n),!0},occupant_template:t.template('<li class="{{role}}" {[ if (role === "moderator") { ]}title="'+v("This user is a moderator")+'"'+"{[ } ]}"+'{[ if (role === "participant") { ]}'+'title="'+v("This user can send messages in this room")+'"'+"{[ } ]}"+'{[ if (role === "visitor") { ]}'+'title="'+v("This user can NOT send messages in this room")+'"'+"{[ } ]}"+">{{nick}}</li>"),onChatRoomRoster:function(e,n){this.renderChatArea();var r=u.chatboxesview.views.controlbox,i=t.size(e),s=this.$el.find(".participant-list"),o=[],a=t.keys(e),f;this.$el.find(".participant-list").empty();for(f=0;f<i;f++)o.push(this.occupant_template({role:e[a[f]].role,nick:Strophe.unescapeNode(a[f])}));return s.append(o.join("")),!0}}),this.ChatBoxes=Backbone.Collection.extend({model:u.ChatBox,registerMessageHandler:function(){u.connection.addHandler(e.proxy(function(e){return this.messageReceived(e),!0},this),null,"message","chat")},onConnected:function(){this.localStorage=new Backbone.LocalStorage(hex_sha1("converse.chatboxes-"+u.bare_jid)),this.get("controlbox")?this.get("controlbox").save():this.add({id:"controlbox",box_id:"controlbox"}),this.get("controlbox").set({connected:!0}),this.registerMessageHandler(),this.fetch({add:!0,success:e.proxy(function(e,n){t.include(t.pluck(n,"id"),"controlbox")&&this.get("controlbox").set({visible:!0}).save()},this)})},messageReceived:function(n){var r,i=e(n),s=i.attr("from");if(s==u.connection.jid)return!0;var o=i.children("forwarded");o.length&&(i=o.children("message"));var a=Strophe.getBareJidFromJid(s),f=Strophe.getBareJidFromJid(i.attr("to")),l,c,h;a==u.bare_jid?(r=f,l=Strophe.getResourceFromJid(i.attr("to"))):(r=a,l=Strophe.getResourceFromJid(s)),c=this.get(r),h=u.roster.get(r);if(h===undefined)return u.log("Could not get roster item for JID "+r,"error"),!0;if(!c){var p=h.get("fullname");p=t.isEmpty(p)?r:p,c=this.create({id:r,jid:r,fullname:p,image_type:h.get("image_type"),image:h.get("image"),url:h.get("url")})}return c.messageReceived(n),u.roster.addResource(r,l),u.emit("onMessage",n),!0}}),this.ChatBoxesView=Backbone.View.extend({el:"#conversejs",initialize:function(){this.views={},this.model.on("add",function(e){var t=this.views[e.get("id")];t?(delete t.model,t.model=e,t.initialize(),e.get("id")!=="controlbox"&&t.$el.appendTo(this.$el)):(e.get("chatroom")?t=new u.ChatRoomView({model:e}):e.get("box_id")==="controlbox"?(t=new u.ControlBoxView({model:e}),t.render()):t=new u.ChatBoxView({model:e}),this.views[e.get("id")]=t)},this)},showChatBox:function(e){var t=this.model.get(e.jid);return t?t.trigger("show"):t=this.model.create(e,{error:function(e,t){u.log(t.responseText)}}),t}}),this.RosterItem=Backbone.Model.extend({initialize:function(e,n){var r=e.jid;e.fullname||(e.fullname=r);var i=t.extend({id:r,user_id:Strophe.getNodeFromJid(r),resources:[],status:""},e);i.sorted=!1,i.chat_status="offline",this.set(i)}}),this.RosterItemView=Backbone.View.extend({tagName:"dd",events:{"click .accept-xmpp-request":"acceptRequest","click .decline-xmpp-request":"declineRequest","click .open-chat":"openChat","click .remove-xmpp-contact":"removeContact"},openChat:function(e){e.preventDefault(),u.chatboxesview.showChatBox({id:this.model.get("jid"),jid:this.model.get("jid"),fullname:this.model.get("fullname"),image_type:this.model.get("image_type"),image:this.model.get("image"),url:this.model.get("url"),status:this.model.get("status")})},removeContact:function(e){e.preventDefault();var t=confirm("Are you sure you want to remove this contact?");if(t===!0){var n=this.model.get("jid");u.connection.roster.remove(n,function(e){u.connection.roster.unauthorize(n),u.rosterview.model.remove(n)})}},acceptRequest:function(e){var t=this.model.get("jid");u.connection.roster.authorize(t),u.connection.roster.add(t,this.model.get("fullname"),[],function(e){u.connection.roster.subscribe(t,null,u.xmppstatus.get("fullname"))}),e.preventDefault()},declineRequest:function(e){e.preventDefault(),u.connection.roster.unauthorize(this.model.get("jid")),this.model.destroy()},template:t.template('<a class="open-chat" title="'+v("Click to chat with this contact")+'" href="#">'+'<span class="icon-{{ chat_status }}" title="{{ status_desc }}"></span>{{ fullname }}'+"</a>"+'<a class="remove-xmpp-contact icon-remove" title="'+v("Click to remove this contact")+'" href="#"></a>'),pending_template:t.template('<span>{{ fullname }}</span><a class="remove-xmpp-contact icon-remove" title="'+v("Click to remove this contact")+'" href="#"></a>'),request_template:t.template('<div>{{ fullname }}</div><button type="button" class="accept-xmpp-request">Accept</button><button type="button" class="decline-xmpp-request">Decline</button>'),render:function(){var e=this.model,n=e.get("ask"),r=e.get("requesting"),i=e.get("subscription"),s=["current-xmpp-contact","pending-xmpp-contact","requesting-xmpp-contact"].concat(t.keys(b));t.each(s,function(e){this.el.className.indexOf(e)!==-1&&this.$el.removeClass(e)},this),this.$el.addClass(e.get("chat_status"));if(n==="subscribe")this.$el.addClass("pending-xmpp-contact"),this.$el.html(this.pending_template(e.toJSON()));else if(r===!0)this.$el.addClass("requesting-xmpp-contact"),this.$el.html(this.request_template(e.toJSON())),u.controlboxtoggle.showControlBox();else if(i==="both"||i==="to")this.$el.addClass("current-xmpp-contact"),this.$el.html(this.template(t.extend(e.toJSON(),{status_desc:b[e.get("chat_status")||"offline"]})));return this}}),this.RosterItems=Backbone.Collection.extend({model:u.RosterItem,comparator:function(e){var t=e.get("chat_status"),n=4;switch(t){case"offline":n=0;break;case"unavailable":n=1;break;case"xa":n=2;break;case"away":n=3;break;case"dnd":n=4;break;case"online":n=5}return n},subscribeToSuggestedItems:function(t){return e(t).find("item").each(function(){var t=e(this),n=t.attr("jid"),r=t.attr("action"),i=t.attr("name");r==="add"&&u.connection.roster.add(n,i,[],function(e){u.connection.roster.subscribe(n,null,u.xmppstatus.get("fullname"))})}),!0},isSelf:function(e){return Strophe.getBareJidFromJid(e)===Strophe.getBareJidFromJid(u.connection.jid)},addResource:function(e,n){var r=this.get(e),i;r&&(i=r.get("resources"),i?t.indexOf(i,n)==-1&&(i.push(n),r.set({resources:i})):r.set({resources:[n]}))},removeResource:function(e,n){var r=this.get(e),i,s;if(r){i=r.get("resources"),s=t.indexOf(i,n);if(s!==-1)return i.splice(s,1),r.set({resources:i}),i.length}return 0},subscribeBack:function(e){var t=Strophe.getBareJidFromJid(e);u.connection.roster.findItem(t)?(u.connection.roster.authorize(t),u.connection.roster.subscribe(e,null,u.xmppstatus.get("fullname"))):u.connection.roster.add(e,"",[],function(n){u.connection.roster.authorize(t),u.connection.roster.subscribe(e,null,u.xmppstatus.get("fullname"))})},unsubscribe:function(e){u.xmppstatus.sendPresence("unsubscribe"),u.connection.roster.findItem(e)&&u.connection.roster.remove(e,function(t){u.rosterview.model.remove(e)})},getNumOnlineContacts:function(){var e=0,n=["offline","unavailable"],r=this.models,i=r.length,s;u.show_only_online_users&&(n=t.union(n,["dnd","xa","away"]));for(s=0;s<i;s++)t.indexOf(n,r[s].get("chat_status"))===-1&&e++;return e},cleanCache:function(e){var n,r,i=[];for(r=0;r<e.length;++r)i.push(e[r].jid);for(r=0;r<this.models.length;++r)n=this.models[r].get("id"),t.indexOf(i,n)===-1&&this.get(n).destroy()},rosterHandler:function(e){u.emit("onRoster",e),this.cleanCache(e),t.each(e,function(e,t,n){if(this.isSelf(e.jid))return;var r=this.get(e.jid);if(!r){var i=t===n.length-1?!0:!1;if(e.subscription==="none"&&e.ask===null&&!i)return;this.create({jid:e.jid,subscription:e.subscription,ask:e.ask,fullname:e.name||e.jid,is_last:i})}else if(e.subscription==="none"&&e.ask===null)r.destroy();else if(r.get("subscription")!==e.subscription||r.get("ask")!==e.ask)r.set({subscription:e.subscription,ask:e.ask,requesting:null}),r.save()},this),u.initial_presence_sent||(u.initial_presence_sent=1,u.xmppstatus.sendPresence())},handleIncomingSubscription:function(t){var n=Strophe.getBareJidFromJid(t),r=this.get(n);if(!u.allow_contact_requests)return u.connection.roster.unauthorize(n),!0;if(u.auto_subscribe)!r||r.get("subscription")!="to"?this.subscribeBack(t):u.connection.roster.authorize(n);else if(r&&r.get("subscription")!="none")u.connection.roster.authorize(n);else{if(!!this.get(n))return!0;u.getVCard(n,e.proxy(function(e,t,r,i,s){this.add({jid:n,subscription:"none",ask:null,requesting:!0,fullname:t,image:r,image_type:i,url:s,vcard_updated:u.toISOString(new Date),is_last:!0})},this),e.proxy(function(e,t,r,i,s){u.log("Error while retrieving vcard"),this.add({jid:n,subscription:"none",ask:null,requesting:!0,fullname:e,is_last:!0})},this))}return!0},presenceHandler:function(t){var n=e(t),r=n.attr("type");if(r==="error")return!0;var i=n.attr("from"),s=Strophe.getBareJidFromJid(i),o=Strophe.getResourceFromJid(i),a=n.find("show"),f=a.text()||"online",l=n.find("status"),c;return this.isSelf(s)?(u.connection.jid!==i&&r!=="unavailable"&&u.xmppstatus.save({status:f}),!0):(n.find("x").attr("xmlns")||"").indexOf(Strophe.NS.MUC)===0?!0:(c=this.get(s),c&&l.text()!=c.get("status")&&c.save({status:l.text()}),r==="subscribed"||r==="unsubscribe"?!0:r==="subscribe"?this.handleIncomingSubscription(i):(r==="unsubscribed"?this.unsubscribe(s):r==="unavailable"?this.removeResource(s,o)===0&&c&&c.set({chat_status:"offline"}):c&&(this.addResource(s,o),c.set({chat_status:f})),!0))}}),this.RosterView=Backbone.View.extend({tagName:"dl",id:"converse-roster",rosteritemviews:{},requesting_contacts_template:t.template('<dt id="xmpp-contact-requests">'+v("Contact requests")+"</dt>"),contacts_template:t.template('<dt id="xmpp-contacts">'+v("My contacts")+"</dt>"),pending_contacts_template:t.template('<dt id="pending-xmpp-contacts">'+v("Pending contacts")+"</dt>"),initialize:function(){this.model.on("add",function(e){this.addRosterItemView(e).render(e),e.get("vcard_updated")||u.getVCard(e.get("jid"))},this),this.model.on("change",function(e){if(t.size(e.changed)===1&&t.contains(t.keys(e.changed),"sorted"))return;this.updateChatBox(e).render(e)},this),this.model.on("remove",function(e){this.removeRosterItemView(e)},this),this.model.on("destroy",function(e){this.removeRosterItemView(e)},this);var e=this.contacts_template();u.allow_contact_requests&&(e=this.requesting_contacts_template()+e+this.pending_contacts_template()),this.$el.hide().html(e),this.model.fetch({add:!0})},updateChatBox:function(e,n){var r=u.chatboxes.get(e.get("jid")),i={};return r?(t.has(e.changed,"chat_status")&&(i.chat_status=e.get("chat_status")),t.has(e.changed,"status")&&(i.status=e.get("status")),r.save(i),this):this},addRosterItemView:function(e){var t=new u.RosterItemView({model:e});return this.rosteritemviews[e.id]=t,this},removeRosterItemView:function(e){var t=this.rosteritemviews[e.id];return t&&(t.$el.remove(),delete this.rosteritemviews[e.id],this.render()),this},renderRosterItem:function(t,n){if(u.show_only_online_users&&t.get("chat_status")!=="online")return n.$el.remove(),n.delegateEvents(),this;e.contains(document.documentElement,n.el)?n.render():this.$el.find("#xmpp-contacts").after(n.render().el)},render:function(n){var r=this.$el.find("#xmpp-contacts"),i=this.$el.find("#xmpp-contact-requests"),s=this.$el.find("#pending-xmpp-contacts"),o=!1,a,f;if(n){var l=n.id,c=this.rosteritemviews[n.id],h=n.get("ask"),p=n.get("subscription"),d=n.get("requesting"),v={order:"asc"};h==="subscribe"&&p=="none"?(s.after(c.render().el),s.after(s.siblings("dd.pending-xmpp-contact").tsort(v))):h==="subscribe"&&p=="from"?(s.after(c.render().el),s.after(s.siblings("dd.pending-xmpp-contact").tsort(v))):d===!0?(i.after(c.render().el),i.after(i.siblings("dd.requesting-xmpp-contact").tsort(v))):(p==="both"||p==="to")&&this.renderRosterItem(n,c),f=n.changed.chat_status,f&&(this.sortRoster(f),o=!0),n.get("is_last")&&(o||this.sortRoster(n.get("chat_status")),this.$el.is(":visible")||this.$el.show())}return t.each([r,i,s],function(e){e.nextUntil("dt").length?e.is(":visible")||e.show():e.is(":visible")&&e.hide()}),a=e("#online-count"),a.text("("+this.model.getNumOnlineContacts()+")"),a.is(":visible")||a.show(),u.emit("onRosterViewUpdated"),this},sortRoster:function(e){var t=this.$el.find("#xmpp-contacts");t.siblings("dd.current-xmpp-contact."+e).tsort("a",{order:"asc"}),t.after(t.siblings("dd.current-xmpp-contact.offline")),t.after(t.siblings("dd.current-xmpp-contact.unavailable")),t.after(t.siblings("dd.current-xmpp-contact.xa")),t.after(t.siblings("dd.current-xmpp-contact.away")),t.after(t.siblings("dd.current-xmpp-contact.dnd")),t.after(t.siblings("dd.current-xmpp-contact.online"))}}),this.XMPPStatus=Backbone.Model.extend({initialize:function(){this.set({status:this.get("status")||"online"}),this.on("change",e.proxy(function(n){this.get("fullname")===undefined&&u.getVCard(null,e.proxy(function(e,t,n,r,i){this.save({fullname:t})},this)),t.has(n.changed,"status")&&u.emit("onStatusChanged",this.get("status")),t.has(n.changed,"status_message")&&u.emit("onStatusMessageChanged",this.get("status_message"))},this))},sendPresence:function(e){e===undefined&&(e=this.get("status")||"online");var t=this.get("status_message"),n;e==="unavailable"||e==="probe"||e==="error"||e==="unsubscribe"||e==="unsubscribed"||e==="subscribe"||e==="subscribed"?n=$pres({type:e}):(e==="online"?n=$pres():n=$pres().c("show").t(e).up(),t&&n.c("status").t(t)),u.connection.send(n)},setStatus:function(e){this.sendPresence(e),this.save({status:e})},setStatusMessage:function(t){u.connection.send($pres().c("show").t(this.get("status")).up().c("status").t(t)),this.save({status_message:t}),this.xhr_custom_status&&e.ajax({url:this.xhr_custom_status_url,type:"POST",data:{msg:t}})}}),this.XMPPStatusView=Backbone.View.extend({el:"span#xmpp-status-holder",events:{"click a.choose-xmpp-status":"toggleOptions","click #fancy-xmpp-status-select a.change-xmpp-status-message":"renderStatusChangeForm","submit #set-custom-xmpp-status":"setStatusMessage","click .dropdown dd ul li a":"setStatus"},toggleOptions:function(t){t.preventDefault(),e(t.target).parent().parent().siblings("dd").find("ul").toggle("fast")},change_status_message_template:t.template('<form id="set-custom-xmpp-status"><input type="text" class="custom-xmpp-status" {{ status_message }}"placeholder="'+v("Custom status")+'"/>'+'<button type="submit">'+v("Save")+"</button>"+"</form>"),status_template:t.template('<div class="xmpp-status"><a class="choose-xmpp-status {{ chat_status }}" data-value="{{status_message}}" href="#" title="'+v("Click to change your chat status")+'">'+'<span class="icon-{{ chat_status }}"></span>'+"{{ status_message }}"+"</a>"+'<a class="change-xmpp-status-message icon-pencil" href="#" title="'+v("Click here to write a custom status message")+'"></a>'+"</div>"),renderStatusChangeForm:function(e){e.preventDefault();var t=this.model.get("status")||"offline",n=this.change_status_message_template({status_message:t});this.$el.find(".xmpp-status").replaceWith(n),this.$el.find(".custom-xmpp-status").focus().focus()},setStatusMessage:function(t){t.preventDefault();var n=e(t.target).find("input").val();n==="",this.model.setStatusMessage(n)},setStatus:function(t){t.preventDefault();var n=e(t.target),r=n.attr("data-value");this.model.setStatus(r),this.$el.find(".dropdown dd ul").hide()},getPrettyStatus:function(e){return e==="chat"?pretty_status=v("online"):e==="dnd"?pretty_status=v("busy"):e==="xa"?pretty_status=v("away for long"):e==="away"?pretty_status=v("away"):pretty_status=v(e)||v("online"),pretty_status},updateStatusUI:function(e){if(!t.has(e.changed,"status")&&!t.has(e.changed,"status_message"))return;var n=e.get("status"),r=e.get("status_message")||v("I am %1$s",this.getPrettyStatus(n));this.$el.find("#fancy-xmpp-status-select").html(this.status_template({chat_status:n,status_message:r}))},choose_template:t.template('<dl id="target" class="dropdown"><dt id="fancy-xmpp-status-select" class="fancy-dropdown"></dt><dd><ul class="xmpp-status-menu"></ul></dd></dl>'),option_template:t.template('<li><a href="#" class="{{ value }}" data-value="{{ value }}"><span class="icon-{{ value }}"></span>{{ text }}</a></li>'),initialize:function(){this.model.on("change",this.updateStatusUI,this)},render:function(){var t=this.$el.find("select#select-xmpp-status"),n=this.model.get("status")||"offline",r=e("option",t),i,s=[],o=this;return this.$el.html(this.choose_template()),this.$el.find("#fancy-xmpp-status-select").html(this.status_template({status_message:this.model.get("status_message")||v("I am %1$s",this.getPrettyStatus(n)),chat_status:n})),r.each(function(){s.push(o.option_template({value:e(this).val(),text:this.text}))}),i=this.$el.find("#target dd ul").hide(),i.append(s.join("")),t.remove(),this}}),this.Feature=Backbone.Model.extend(),this.Features=Backbone.Collection.extend({model:u.Feature,initialize:function(){this.localStorage=new Backbone.LocalStorage(hex_sha1("converse.features"+u.bare_jid)),this.localStorage.records.length===0?(u.connection.disco.info(u.domain,null,e.proxy(this.onInfo,this)),u.connection.disco.items(u.domain,null,e.proxy(this.onItems,this))):this.fetch({add:!0})},onItems:function(t){e(t).find("query item").each(e.proxy(function(t,n){u.connection.disco.info(e(n).attr("jid"),null,e.proxy(this.onInfo,this))},this))},onInfo:function(t){var n=e(t);if(n.find("identity[category=server][type=im]").length===0&&n.find("identity[category=conference][type=text]").length===0)return;n.find("feature").each(e.proxy(function(t,r){this.create({"var":e(r).attr("var"),from:n.attr("from")})},this))}}),this.LoginPanel=Backbone.View.extend({tagName:"div",id:"login-dialog",events:{"submit form#converse-login":"authenticate"},tab_template:t.template('<li><a class="current" href="#login">'+v("Sign in")+"</a></li>"),template:t.template('<form id="converse-login"><label>'+v("XMPP/Jabber Username:")+"</label>"+'<input type="username" name="jid">'+"<label>"+v("Password:")+"</label>"+'<input type="password" name="password">'+'<input class="login-submit" type="submit" value="'+v("Log In")+'">'+'</form">'),bosh_url_input:t.template("<label>"+v("BOSH Service URL:")+"</label>"+'<input type="text" id="bosh_service_url">'),connect:function(e,t,n){e&&e.find("input[type=submit]").hide().after('<span class="spinner login-submit"/>'),u.connection=new Strophe.Connection(u.bosh_service_url),u.connection.connect(t,n,u.onConnect)},showLoginButton:function(){var e=this.$el.find("#converse-login"),t=e.find("input[type=submit]");t.length&&t.show().siblings("span").remove()},initialize:function(e){e.$parent.html(this.$el.html(this.template())),this.$tabs=e.$parent.parent().find("#controlbox-tabs")},render:function(){return this.$tabs.append(this.tab_template()),this.$el.find("input#jid").focus(),this},authenticate:function(t){var n=e(t.target),r=n.find("input[name=jid]"),i=r.val(),s=n.find("input[name=password]"),o=s.val(),a=null,f=!1;u.bosh_service_url||(a=n.find("input#bosh_service_url"),u.bosh_service_url=a.val(),u.bosh_service_url||(f=!0,a.addClass("error"))),i||(f=!0,r.addClass("error")),o||(f=!0,s.addClass("error"));if(f)return;return this.connect(n,i,o),!1},remove:function(){this.$tabs.empty(),this.$el.parent().empty()}}),this.ControlBoxToggle=Backbone.View.extend({tagName:"a",className:"toggle-online-users",id:"toggle-controlbox",events:{click:"onClick"},attributes:{href:"#"},template:t.template('<strong class="conn-feedback">Toggle chat</strong><strong style="display: none" id="online-count">(0)</strong>'),initialize:function(){this.render()},render:function(){return e("#conversejs").append(this.$el.html(this.template())),this},showControlBox:function(){var e=u.chatboxes.get("controlbox");e?e.trigger("show"):(u.chatboxes.add({id:"controlbox",box_id:"controlbox",visible:!0}),u.connection&&u.chatboxes.get("controlbox").save())},onClick:function(t){t.preventDefault();if(e("div#controlbox").is(":visible")){var n=u.chatboxes.get("controlbox");u.connection?n.destroy():n.trigger("hide")}else this.showControlBox()}}),this.chatboxes=new this.ChatBoxes,this.chatboxesview=new this.ChatBoxesView({model:this.chatboxes}),this.controlboxtoggle=new this.ControlBoxToggle,this.otr=new this.OTR;if(this.prebind&&!this.connection){if(!this.jid||!this.sid||!this.rid||!this.bosh_service_url){this.log("If you set prebind=true, you MUST supply JID, RID and SID values");return}this.connection=new Strophe.Connection(this.bosh_service_url),this.connection.attach(this.jid,this.sid,this.rid,this.onConnect)}else this.connection&&this.onConnected();this.show_controlbox_by_default&&this.controlboxtoggle.showControlBox(),u.emit("onInitialized")},{initialize:function(e,t){s.initialize(e,t)},getRID:function(){return s.expose_rid_and_sid&&typeof s.connection!="undefined"?s.connection.rid:null},getSID:function(){return s.expose_rid_and_sid&&typeof s.connection!="undefined"?s.connection.sid:null},once:function(e,t){s.once(e,t)},on:function(e,t){s.on(e,t)},off:function(e,t){s.off(e,t)}}}),require.config({paths:{jquery:"components/jquery/jquery",locales:"locale/locales","jquery.tinysort":"components/tinysort/src/jquery.tinysort",underscore:"components/underscore/underscore",backbone:"components/backbone/backbone","backbone.localStorage":"components/backbone.localStorage/backbone.localStorage",strophe:"components/strophe/strophe","strophe.muc":"components/strophe.muc/index","strophe.roster":"components/strophe.roster/index","strophe.vcard":"components/strophe.vcard/index","strophe.disco":"components/strophe.disco/index",salsa20:"components/otr/build/dep/salsa20",bigint:"src/bigint","crypto.core":"components/otr/vendor/cryptojs/core","crypto.enc-base64":"components/otr/vendor/cryptojs/enc-base64","crypto.md5":"components/crypto-js/src/md5","crypto.evpkdf":"components/crypto-js/src/evpkdf","crypto.cipher-core":"components/otr/vendor/cryptojs/cipher-core","crypto.aes":"components/otr/vendor/cryptojs/aes","crypto.sha1":"components/otr/vendor/cryptojs/sha1","crypto.sha256":"components/otr/vendor/cryptojs/sha256","crypto.hmac":"components/otr/vendor/cryptojs/hmac","crypto.pad-nopadding":"components/otr/vendor/cryptojs/pad-nopadding","crypto.mode-ctr":"components/otr/vendor/cryptojs/mode-ctr",crypto:"src/crypto",eventemitter:"components/otr/build/dep/eventemitter",otr:"components/otr/build/otr","converse-dependencies":"src/deps-full"},shim:{backbone:{deps:["underscore","jquery"],exports:"Backbone"},"jquery.tinysort":{deps:["jquery"]},strophe:{deps:["jquery"]},underscore:{exports:"_"},"strophe.muc":{deps:["strophe","jquery"]},"strophe.roster":{deps:["strophe"]},"strophe.vcard":{deps:["strophe"]},"strophe.disco":{deps:["strophe"]}}}),require(["jquery","converse"],function(e,t,n){window.converse=n}),define("main",function(){}); |