diff --git a/public/build/manifest.json b/public/build/manifest.json index 1cec07867..1fd24db65 100644 --- a/public/build/manifest.json +++ b/public/build/manifest.json @@ -1,5 +1,5 @@ { - "css/styles.css": "css/styles.css?version=b7e7aa9", - "css/print-styles.css": "css/print-styles.css?version=b7e7aa9", - "js/common.js": "js/common.js?version=b7e7aa9" + "css/styles.css": "css/styles.css?version=b4531da", + "css/print-styles.css": "css/print-styles.css?version=b4531da", + "js/common.js": "js/common.js?version=b4531da" } \ No newline at end of file diff --git a/public/js/common.js b/public/js/common.js index 5bf8a71ee..41075aa52 100644 --- a/public/js/common.js +++ b/public/js/common.js @@ -8,4 +8,4 @@ a.enter(e,null,Ir(N)),N=n,M.clone=e,I[M.id]=M,l(M.scope,d,b,E,w,_,x)});g=I})}}}} u=r.toDataURL("image/png"),t.emit("thumbnail",e,u),null!=n?n():void 0}}(this),null!=n&&(i.onerror=n),i.src=t},t.prototype.processQueue=function(){var e,t,n,r;if(t=this.options.parallelUploads,n=this.getUploadingFiles().length,e=n,!(n>=t)&&(r=this.getQueuedFiles(),r.length>0)){if(this.options.uploadMultiple)return this.processFiles(r.slice(0,t-n));for(;t>e;){if(!r.length)return;this.processFile(r.shift()),e++}}},t.prototype.processFile=function(e){return this.processFiles([e])},t.prototype.processFiles=function(e){var n,r,i;for(r=0,i=e.length;i>r;r++)n=e[r],n.processing=!0,n.status=t.UPLOADING,this.emit("processing",n);return this.options.uploadMultiple&&this.emit("processingmultiple",e),this.uploadFiles(e)},t.prototype._getFilesWithXhr=function(e){var t,n;return n=function(){var n,r,i,o;for(i=this.files,o=[],n=0,r=i.length;r>n;n++)t=i[n],t.xhr===e&&o.push(t);return o}.call(this)},t.prototype.cancelUpload=function(e){var n,r,i,o,a,s,u;if(e.status===t.UPLOADING){for(r=this._getFilesWithXhr(e.xhr),i=0,a=r.length;a>i;i++)n=r[i],n.status=t.CANCELED;for(e.xhr.abort(),o=0,s=r.length;s>o;o++)n=r[o],this.emit("canceled",n);this.options.uploadMultiple&&this.emit("canceledmultiple",r)}else((u=e.status)===t.ADDED||u===t.QUEUED)&&(e.status=t.CANCELED,this.emit("canceled",e),this.options.uploadMultiple&&this.emit("canceledmultiple",[e]));return this.options.autoProcessQueue?this.processQueue():void 0},i=function(){var e,t;return t=arguments[0],e=2<=arguments.length?l.call(arguments,1):[],"function"==typeof t?t.apply(this,e):t},t.prototype.uploadFile=function(e){return this.uploadFiles([e])},t.prototype.uploadFiles=function(e){var n,o,a,s,u,l,c,f,d,h,p,m,g,v,$,y,b,w,x,k,C,S,_,E,D,T,A,M,O,F,N,I,j,P;for(x=new XMLHttpRequest,k=0,E=e.length;E>k;k++)n=e[k],n.xhr=x;m=i(this.options.method,e),b=i(this.options.url,e),x.open(m,b,!0),x.withCredentials=!!this.options.withCredentials,$=null,a=function(t){return function(){var r,i,o;for(o=[],r=0,i=e.length;i>r;r++)n=e[r],o.push(t._errorProcessing(e,$||t.options.dictResponseError.replace("{{statusCode}}",x.status),x));return o}}(this),y=function(t){return function(r){var i,o,a,s,u,l,c,f,d;if(null!=r)for(o=100*r.loaded/r.total,a=0,l=e.length;l>a;a++)n=e[a],n.upload={progress:o,total:r.total,bytesSent:r.loaded};else{for(i=!0,o=100,s=0,c=e.length;c>s;s++)n=e[s],(100!==n.upload.progress||n.upload.bytesSent!==n.upload.total)&&(i=!1),n.upload.progress=o,n.upload.bytesSent=n.upload.total;if(i)return}for(d=[],u=0,f=e.length;f>u;u++)n=e[u],d.push(t.emit("uploadprogress",n,o,n.upload.bytesSent));return d}}(this),x.onload=function(n){return function(r){var i;if(e[0].status!==t.CANCELED&&4===x.readyState){if($=x.responseText,x.getResponseHeader("content-type")&&~x.getResponseHeader("content-type").indexOf("application/json"))try{$=JSON.parse($)}catch(o){r=o,$="Invalid JSON response from server."}return y(),200<=(i=x.status)&&300>i?n._finished(e,$,r):a()}}}(this),x.onerror=function(n){return function(){return e[0].status!==t.CANCELED?a():void 0}}(this),v=null!=(O=x.upload)?O:x,v.onprogress=y,l={Accept:"application/json","Cache-Control":"no-cache","X-Requested-With":"XMLHttpRequest"},this.options.headers&&r(l,this.options.headers);for(s in l)u=l[s],u&&x.setRequestHeader(s,u);if(o=new FormData,this.options.params){F=this.options.params;for(p in F)w=F[p],o.append(p,w)}for(C=0,D=e.length;D>C;C++)n=e[C],this.emit("sending",n,x,o);if(this.options.uploadMultiple&&this.emit("sendingmultiple",e,x,o),"FORM"===this.element.tagName)for(N=this.element.querySelectorAll("input, textarea, select, button"),S=0,T=N.length;T>S;S++)if(f=N[S],d=f.getAttribute("name"),h=f.getAttribute("type"),"SELECT"===f.tagName&&f.hasAttribute("multiple"))for(I=f.options,_=0,A=I.length;A>_;_++)g=I[_],g.selected&&o.append(d,g.value);else(!h||"checkbox"!==(j=h.toLowerCase())&&"radio"!==j||f.checked)&&o.append(d,f.value);for(c=M=0,P=e.length-1;P>=0?P>=M:M>=P;c=P>=0?++M:--M)o.append(this._getParamName(c),e[c],e[c].name);return this.submitRequest(x,o,e)},t.prototype.submitRequest=function(e,t,n){return e.send(t)},t.prototype._finished=function(e,n,r){var i,o,a;for(o=0,a=e.length;a>o;o++)i=e[o],i.status=t.SUCCESS,this.emit("success",i,n,r),this.emit("complete",i);return this.options.uploadMultiple&&(this.emit("successmultiple",e,n,r),this.emit("completemultiple",e)),this.options.autoProcessQueue?this.processQueue():void 0},t.prototype._errorProcessing=function(e,n,r){var i,o,a;for(o=0,a=e.length;a>o;o++)i=e[o],i.status=t.ERROR,this.emit("error",i,n,r),this.emit("complete",i);return this.options.uploadMultiple&&(this.emit("errormultiple",e,n,r),this.emit("completemultiple",e)),this.options.autoProcessQueue?this.processQueue():void 0},t}(n),e.version="4.2.0",e.options={},e.optionsForElement=function(t){return t.getAttribute("id")?e.options[r(t.getAttribute("id"))]:void 0},e.instances=[],e.forElement=function(e){if("string"==typeof e&&(e=document.querySelector(e)),null==(null!=e?e.dropzone:void 0))throw new Error("No Dropzone found for given element. This is probably because you're trying to access it before Dropzone had the time to initialize. Use the `init` option to setup any additional observers on your Dropzone.");return e.dropzone},e.autoDiscover=!0,e.discover=function(){var t,n,r,i,o,a;for(document.querySelectorAll?r=document.querySelectorAll(".dropzone"):(r=[],t=function(e){var t,n,i,o;for(o=[],n=0,i=e.length;i>n;n++)t=e[n],/(^| )dropzone($| )/.test(t.className)?o.push(r.push(t)):o.push(void 0);return o},t(document.getElementsByTagName("div")),t(document.getElementsByTagName("form"))),a=[],i=0,o=r.length;o>i;i++)n=r[i],e.optionsForElement(n)!==!1?a.push(new e(n)):a.push(void 0);return a},e.blacklistedBrowsers=[/opera.*Macintosh.*version\/12/i],e.isBrowserSupported=function(){var t,n,r,i,o;if(t=!0,window.File&&window.FileReader&&window.FileList&&window.Blob&&window.FormData&&document.querySelector)if("classList"in document.createElement("a"))for(o=e.blacklistedBrowsers,r=0,i=o.length;i>r;r++)n=o[r],n.test(navigator.userAgent)&&(t=!1);else t=!1;else t=!1;return t},u=function(e,t){var n,r,i,o;for(o=[],r=0,i=e.length;i>r;r++)n=e[r],n!==t&&o.push(n);return o},r=function(e){return e.replace(/[\-_](\w)/g,function(e){return e.charAt(1).toUpperCase()})},e.createElement=function(e){var t;return t=document.createElement("div"),t.innerHTML=e,t.childNodes[0]},e.elementInside=function(e,t){if(e===t)return!0;for(;e=e.parentNode;)if(e===t)return!0;return!1},e.getElement=function(e,t){var n;if("string"==typeof e?n=document.querySelector(e):null!=e.nodeType&&(n=e),null==n)throw new Error("Invalid `"+t+"` option provided. Please provide a CSS selector or a plain HTML element.");return n},e.getElements=function(e,t){var n,r,i,o,a,s,u,l;if(e instanceof Array){i=[];try{for(o=0,s=e.length;s>o;o++)r=e[o],i.push(this.getElement(r,t))}catch(c){n=c,i=null}}else if("string"==typeof e)for(i=[],l=document.querySelectorAll(e),a=0,u=l.length;u>a;a++)r=l[a],i.push(r);else null!=e.nodeType&&(i=[e]);if(null==i||!i.length)throw new Error("Invalid `"+t+"` option provided. Please provide a CSS selector, a plain HTML element or a list of those.");return i},e.confirm=function(e,t,n){return window.confirm(e)?t():null!=n?n():void 0},e.isValidFile=function(e,t){var n,r,i,o,a;if(!t)return!0;for(t=t.split(","),r=e.type,n=r.replace(/\/.*$/,""),o=0,a=t.length;a>o;o++)if(i=t[o],i=i.trim(),"."===i.charAt(0)){if(-1!==e.name.toLowerCase().indexOf(i.toLowerCase(),e.name.length-i.length))return!0}else if(/\/\*$/.test(i)){if(n===i.replace(/\/.*$/,""))return!0}else if(r===i)return!0;return!1},"undefined"!=typeof jQuery&&null!==jQuery&&(jQuery.fn.dropzone=function(t){return this.each(function(){return new e(this,t)})}),"undefined"!=typeof t&&null!==t?t.exports=e:window.Dropzone=e,e.ADDED="added",e.QUEUED="queued",e.ACCEPTED=e.QUEUED,e.UPLOADING="uploading",e.PROCESSING=e.UPLOADING,e.CANCELED="canceled",e.ERROR="error",e.SUCCESS="success",o=function(e){var t,n,r,i,o,a,s,u,l,c;for(s=e.naturalWidth,a=e.naturalHeight,n=document.createElement("canvas"),n.width=1,n.height=a,r=n.getContext("2d"),r.drawImage(e,0,0),i=r.getImageData(0,0,1,a).data,c=0,o=a,u=a;u>c;)t=i[4*(u-1)+3],0===t?o=u:c=u,u=o+c>>1;return l=u/a,0===l?1:l},a=function(e,t,n,r,i,a,s,u,l,c){var f;return f=o(t),e.drawImage(t,n,r,i,a,s,u,l,c/f)},i=function(e,t){var n,r,i,o,a,s,u,l,c;if(i=!1,c=!0,r=e.document,l=r.documentElement,n=r.addEventListener?"addEventListener":"attachEvent",u=r.addEventListener?"removeEventListener":"detachEvent",s=r.addEventListener?"":"on",o=function(n){return"readystatechange"!==n.type||"complete"===r.readyState?(("load"===n.type?e:r)[u](s+n.type,o,!1),!i&&(i=!0)?t.call(e,n.type||n):void 0):void 0},a=function(){var e;try{l.doScroll("left")}catch(t){return e=t,void setTimeout(a,50)}return o("poll")},"complete"!==r.readyState){if(r.createEventObject&&l.doScroll){try{c=!e.frameElement}catch(f){}c&&a()}return r[n](s+"DOMContentLoaded",o,!1),r[n](s+"readystatechange",o,!1),e[n](s+"load",o,!1)}},e._autoDiscoverFunction=function(){return e.autoDiscover?e.discover():void 0},i(window,e._autoDiscoverFunction)}).call(this)},{}],10:[function(e,t,n){(function(e){(function(){function e(e){this.tokens=[],this.tokens.links={},this.options=e||f.defaults,this.rules=d.normal,this.options.gfm&&(this.options.tables?this.rules=d.tables:this.rules=d.gfm)}function r(e,t){if(this.options=t||f.defaults,this.links=e,this.rules=h.normal,this.renderer=this.options.renderer||new i,this.renderer.options=this.options,!this.links)throw new Error("Tokens array requires a `links` property.");this.options.gfm?this.options.breaks?this.rules=h.breaks:this.rules=h.gfm:this.options.pedantic&&(this.rules=h.pedantic)}function i(e){this.options=e||{}}function o(e){this.tokens=[],this.token=null,this.options=e||f.defaults,this.options.renderer=this.options.renderer||new i,this.renderer=this.options.renderer,this.renderer.options=this.options}function a(e,t){return e.replace(t?/&/g:/&(?!#?\w+;)/g,"&").replace(//g,">").replace(/"/g,""").replace(/'/g,"'")}function s(e){return e.replace(/&([#\w]+);/g,function(e,t){return t=t.toLowerCase(),"colon"===t?":":"#"===t.charAt(0)?"x"===t.charAt(1)?String.fromCharCode(parseInt(t.substring(2),16)):String.fromCharCode(+t.substring(1)):""})}function u(e,t){return e=e.source,t=t||"",function n(r,i){return r?(i=i.source||i,i=i.replace(/(^|[^\[])\^/g,"$1"),e=e.replace(r,i),n):new RegExp(e,t)}}function l(){}function c(e){for(var t,n,r=1;rAn error occured:

"+a(d.message+"",!0)+"
";throw d}}var d={newline:/^\n+/,code:/^( {4}[^\n]+\n*)+/,fences:l,hr:/^( *[-*_]){3,} *(?:\n+|$)/,heading:/^ *(#{1,6}) *([^\n]+?) *#* *(?:\n+|$)/,nptable:l,lheading:/^([^\n]+)\n *(=|-){2,} *(?:\n+|$)/,blockquote:/^( *>[^\n]+(\n(?!def)[^\n]+)*\n*)+/,list:/^( *)(bull) [\s\S]+?(?:hr|def|\n{2,}(?! )(?!\1bull )\n*|\s*$)/,html:/^ *(?:comment *(?:\n|\s*$)|closed *(?:\n{2,}|\s*$)|closing *(?:\n{2,}|\s*$))/,def:/^ *\[([^\]]+)\]: *]+)>?(?: +["(]([^\n]+)[")])? *(?:\n+|$)/,table:l,paragraph:/^((?:[^\n]+\n?(?!hr|heading|lheading|blockquote|tag|def))+)\n*/,text:/^[^\n]+/};d.bullet=/(?:[*+-]|\d+\.)/,d.item=/^( *)(bull) [^\n]*(?:\n(?!\1bull )[^\n]*)*/,d.item=u(d.item,"gm")(/bull/g,d.bullet)(),d.list=u(d.list)(/bull/g,d.bullet)("hr","\\n+(?=\\1?(?:[-*_] *){3,}(?:\\n+|$))")("def","\\n+(?="+d.def.source+")")(),d.blockquote=u(d.blockquote)("def",d.def)(),d._tag="(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:/|[^\\w\\s@]*@)\\b",d.html=u(d.html)("comment",//)("closed",/<(tag)[\s\S]+?<\/\1>/)("closing",/])*?>/)(/tag/g,d._tag)(),d.paragraph=u(d.paragraph)("hr",d.hr)("heading",d.heading)("lheading",d.lheading)("blockquote",d.blockquote)("tag","<"+d._tag)("def",d.def)(),d.normal=c({},d),d.gfm=c({},d.normal,{fences:/^ *(`{3,}|~{3,})[ \.]*(\S+)? *\n([\s\S]*?)\s*\1 *(?:\n+|$)/,paragraph:/^/,heading:/^ *(#{1,6}) +([^\n]+?) *#* *(?:\n+|$)/}),d.gfm.paragraph=u(d.paragraph)("(?!","(?!"+d.gfm.fences.source.replace("\\1","\\2")+"|"+d.list.source.replace("\\1","\\3")+"|")(),d.tables=c({},d.gfm,{nptable:/^ *(\S.*\|.*)\n *([-:]+ *\|[-| :]*)\n((?:.*\|.*(?:\n|$))*)\n*/,table:/^ *\|(.+)\n *\|( *[-:]+[-| :]*)\n((?: *\|.*(?:\n|$))*)\n*/}),e.rules=d,e.lex=function(t,n){var r=new e(n);return r.lex(t)},e.prototype.lex=function(e){return e=e.replace(/\r\n|\r/g,"\n").replace(/\t/g," ").replace(/\u00a0/g," ").replace(/\u2424/g,"\n"),this.token(e,!0)},e.prototype.token=function(e,t,n){for(var r,i,o,a,s,u,l,c,f,e=e.replace(/^ +$/gm,"");e;)if((o=this.rules.newline.exec(e))&&(e=e.substring(o[0].length),o[0].length>1&&this.tokens.push({type:"space"})),o=this.rules.code.exec(e))e=e.substring(o[0].length),o=o[0].replace(/^ {4}/gm,""),this.tokens.push({type:"code",text:this.options.pedantic?o:o.replace(/\n+$/,"")});else if(o=this.rules.fences.exec(e))e=e.substring(o[0].length),this.tokens.push({type:"code",lang:o[2],text:o[3]||""});else if(o=this.rules.heading.exec(e))e=e.substring(o[0].length),this.tokens.push({type:"heading",depth:o[1].length,text:o[2]});else if(t&&(o=this.rules.nptable.exec(e))){for(e=e.substring(o[0].length),u={type:"table",header:o[1].replace(/^ *| *\| *$/g,"").split(/ *\| */),align:o[2].replace(/^ *|\| *$/g,"").split(/ *\| */),cells:o[3].replace(/\n$/,"").split("\n")},c=0;c ?/gm,""),this.token(o,t,!0),this.tokens.push({type:"blockquote_end"});else if(o=this.rules.list.exec(e)){for(e=e.substring(o[0].length),a=o[2],this.tokens.push({type:"list_start",ordered:a.length>1}),o=o[0].match(this.rules.item),r=!1,f=o.length,c=0;f>c;c++)u=o[c],l=u.length,u=u.replace(/^ *([*+-]|\d+\.) +/,""),~u.indexOf("\n ")&&(l-=u.length,u=this.options.pedantic?u.replace(/^ {1,4}/gm,""):u.replace(new RegExp("^ {1,"+l+"}","gm"),"")),this.options.smartLists&&c!==f-1&&(s=d.bullet.exec(o[c+1])[0],a===s||a.length>1&&s.length>1||(e=o.slice(c+1).join("\n")+e,c=f-1)),i=r||/\n\n(?!\s*$)/.test(u),c!==f-1&&(r="\n"===u.charAt(u.length-1),i||(i=r)),this.tokens.push({type:i?"loose_item_start":"list_item_start"}),this.token(u,!1,n),this.tokens.push({type:"list_item_end"});this.tokens.push({type:"list_end"})}else if(o=this.rules.html.exec(e))e=e.substring(o[0].length),this.tokens.push({type:this.options.sanitize?"paragraph":"html",pre:!this.options.sanitizer&&("pre"===o[1]||"script"===o[1]||"style"===o[1]),text:o[0]});else if(!n&&t&&(o=this.rules.def.exec(e)))e=e.substring(o[0].length),this.tokens.links[o[1].toLowerCase()]={href:o[2],title:o[3]};else if(t&&(o=this.rules.table.exec(e))){for(e=e.substring(o[0].length),u={type:"table",header:o[1].replace(/^ *| *\| *$/g,"").split(/ *\| */),align:o[2].replace(/^ *|\| *$/g,"").split(/ *\| */),cells:o[3].replace(/(?: *\| *)?\n$/,"").split("\n")},c=0;c])/,autolink:/^<([^ >]+(@|:\/)[^ >]+)>/,url:l,tag:/^|^<\/?\w+(?:"[^"]*"|'[^']*'|[^'">])*?>/,link:/^!?\[(inside)\]\(href\)/,reflink:/^!?\[(inside)\]\s*\[([^\]]*)\]/,nolink:/^!?\[((?:\[[^\]]*\]|[^\[\]])*)\]/,strong:/^__([\s\S]+?)__(?!_)|^\*\*([\s\S]+?)\*\*(?!\*)/,em:/^\b_((?:[^_]|__)+?)_\b|^\*((?:\*\*|[\s\S])+?)\*(?!\*)/,code:/^(`+)\s*([\s\S]*?[^`])\s*\1(?!`)/,br:/^ {2,}\n(?!\s*$)/,del:l,text:/^[\s\S]+?(?=[\\?(?:\s+['"]([\s\S]*?)['"])?\s*/,h.link=u(h.link)("inside",h._inside)("href",h._href)(),h.reflink=u(h.reflink)("inside",h._inside)(),h.normal=c({},h),h.pedantic=c({},h.normal,{strong:/^__(?=\S)([\s\S]*?\S)__(?!_)|^\*\*(?=\S)([\s\S]*?\S)\*\*(?!\*)/,em:/^_(?=\S)([\s\S]*?\S)_(?!_)|^\*(?=\S)([\s\S]*?\S)\*(?!\*)/}),h.gfm=c({},h.normal,{escape:u(h.escape)("])","~|])")(),url:/^(https?:\/\/[^\s<]+[^<.,:;"')\]\s])/,del:/^~~(?=\S)([\s\S]*?\S)~~/,text:u(h.text)("]|","~]|")("|","|https?://|")()}),h.breaks=c({},h.gfm,{br:u(h.br)("{2,}","*")(),text:u(h.gfm.text)("{2,}","*")()}),r.rules=h,r.output=function(e,t,n){var i=new r(t,n);return i.output(e)},r.prototype.output=function(e){for(var t,n,r,i,o="";e;)if(i=this.rules.escape.exec(e))e=e.substring(i[0].length),o+=i[1];else if(i=this.rules.autolink.exec(e))e=e.substring(i[0].length),"@"===i[2]?(n=":"===i[1].charAt(6)?this.mangle(i[1].substring(7)):this.mangle(i[1]),r=this.mangle("mailto:")+n):(n=a(i[1]),r=n),o+=this.renderer.link(r,null,n);else if(this.inLink||!(i=this.rules.url.exec(e))){if(i=this.rules.tag.exec(e))!this.inLink&&/^/i.test(i[0])&&(this.inLink=!1),e=e.substring(i[0].length),o+=this.options.sanitize?this.options.sanitizer?this.options.sanitizer(i[0]):a(i[0]):i[0];else if(i=this.rules.link.exec(e))e=e.substring(i[0].length),this.inLink=!0,o+=this.outputLink(i,{href:i[2],title:i[3]}),this.inLink=!1;else if((i=this.rules.reflink.exec(e))||(i=this.rules.nolink.exec(e))){if(e=e.substring(i[0].length),t=(i[2]||i[1]).replace(/\s+/g," "),t=this.links[t.toLowerCase()],!t||!t.href){o+=i[0].charAt(0),e=i[0].substring(1)+e;continue}this.inLink=!0,o+=this.outputLink(i,t),this.inLink=!1}else if(i=this.rules.strong.exec(e))e=e.substring(i[0].length),o+=this.renderer.strong(this.output(i[2]||i[1]));else if(i=this.rules.em.exec(e))e=e.substring(i[0].length),o+=this.renderer.em(this.output(i[2]||i[1]));else if(i=this.rules.code.exec(e))e=e.substring(i[0].length),o+=this.renderer.codespan(a(i[2],!0));else if(i=this.rules.br.exec(e))e=e.substring(i[0].length),o+=this.renderer.br();else if(i=this.rules.del.exec(e))e=e.substring(i[0].length),o+=this.renderer.del(this.output(i[1]));else if(i=this.rules.text.exec(e))e=e.substring(i[0].length),o+=this.renderer.text(a(this.smartypants(i[0])));else if(e)throw new Error("Infinite loop on byte: "+e.charCodeAt(0))}else e=e.substring(i[0].length),n=a(i[1]),r=n,o+=this.renderer.link(r,null,n);return o},r.prototype.outputLink=function(e,t){var n=a(t.href),r=t.title?a(t.title):null;return"!"!==e[0].charAt(0)?this.renderer.link(n,r,this.output(e[1])):this.renderer.image(n,r,a(e[1]))},r.prototype.smartypants=function(e){return this.options.smartypants?e.replace(/---/g,"—").replace(/--/g,"–").replace(/(^|[-\u2014\/(\[{"\s])'/g,"$1‘").replace(/'/g,"’").replace(/(^|[-\u2014\/(\[{\u2018\s])"/g,"$1“").replace(/"/g,"”").replace(/\.{3}/g,"…"):e},r.prototype.mangle=function(e){if(!this.options.mangle)return e;for(var t,n="",r=e.length,i=0;r>i;i++)t=e.charCodeAt(i),Math.random()>.5&&(t="x"+t.toString(16)),n+="&#"+t+";";return n},i.prototype.code=function(e,t,n){if(this.options.highlight){var r=this.options.highlight(e,t);null!=r&&r!==e&&(n=!0,e=r)}return t?'
'+(n?e:a(e,!0))+"\n
\n":"
"+(n?e:a(e,!0))+"\n
"},i.prototype.blockquote=function(e){return"
\n"+e+"
\n"},i.prototype.html=function(e){return e},i.prototype.heading=function(e,t,n){return"'+e+"\n"},i.prototype.hr=function(){return this.options.xhtml?"
\n":"
\n"},i.prototype.list=function(e,t){var n=t?"ol":"ul";return"<"+n+">\n"+e+"\n"},i.prototype.listitem=function(e){return"
  • "+e+"
  • \n"},i.prototype.paragraph=function(e){return"

    "+e+"

    \n"},i.prototype.table=function(e,t){return"\n\n"+e+"\n\n"+t+"\n
    \n"},i.prototype.tablerow=function(e){return"\n"+e+"\n"},i.prototype.tablecell=function(e,t){var n=t.header?"th":"td",r=t.align?"<"+n+' style="text-align:'+t.align+'">':"<"+n+">";return r+e+"\n"},i.prototype.strong=function(e){return""+e+""},i.prototype.em=function(e){return""+e+""},i.prototype.codespan=function(e){return""+e+""},i.prototype.br=function(){return this.options.xhtml?"
    ":"
    "},i.prototype.del=function(e){return""+e+""},i.prototype.link=function(e,t,n){if(this.options.sanitize){try{var r=decodeURIComponent(s(e)).replace(/[^\w:]/g,"").toLowerCase()}catch(i){return""}if(0===r.indexOf("javascript:")||0===r.indexOf("vbscript:"))return""}var o='
    "},i.prototype.image=function(e,t,n){var r=''+n+'":">"},i.prototype.text=function(e){return e},o.parse=function(e,t,n){var r=new o(t,n);return r.parse(e)},o.prototype.parse=function(e){this.inline=new r(e.links,this.options,this.renderer),this.tokens=e.reverse();for(var t="";this.next();)t+=this.tok();return t},o.prototype.next=function(){return this.token=this.tokens.pop()},o.prototype.peek=function(){return this.tokens[this.tokens.length-1]||0},o.prototype.parseText=function(){for(var e=this.token.text;"text"===this.peek().type;)e+="\n"+this.next().text;return this.inline.output(e)},o.prototype.tok=function(){switch(this.token.type){case"space":return"";case"hr":return this.renderer.hr();case"heading":return this.renderer.heading(this.inline.output(this.token.text),this.token.depth,this.token.text);case"code":return this.renderer.code(this.token.text,this.token.lang,this.token.escaped);case"table":var e,t,n,r,i,o="",a="";for(n="",e=0;e0)for(n in tr)r=tr[n],i=t[r],p(i)||(e[r]=i);return e}function g(e){m(this,e),this._d=new Date(null!=e._d?e._d.getTime():NaN),nr===!1&&(nr=!0,n.updateOffset(this),nr=!1)}function v(e){return e instanceof g||null!=e&&null!=e._isAMomentObject}function $(e){return 0>e?Math.ceil(e):Math.floor(e)}function y(e){var t=+e,n=0;return 0!==t&&isFinite(t)&&(n=$(t)),n}function b(e,t,n){var r,i=Math.min(e.length,t.length),o=Math.abs(e.length-t.length),a=0;for(r=0;i>r;r++)(n&&e[r]!==t[r]||!n&&y(e[r])!==y(t[r]))&&a++;return a+o}function w(e){n.suppressDeprecationWarnings===!1&&"undefined"!=typeof console&&console.warn&&console.warn("Deprecation warning: "+e)}function x(e,t){var n=!0;return u(function(){return n&&(w(e+"\nArguments: "+Array.prototype.slice.call(arguments).join(", ")+"\n"+(new Error).stack),n=!1),t.apply(this,arguments)},t)}function k(e,t){rr[e]||(w(t),rr[e]=!0)}function C(e){return e instanceof Function||"[object Function]"===Object.prototype.toString.call(e)}function S(e){return"[object Object]"===Object.prototype.toString.call(e)}function _(e){var t,n;for(n in e)t=e[n],C(t)?this[n]=t:this["_"+n]=t;this._config=e,this._ordinalParseLenient=new RegExp(this._ordinalParse.source+"|"+/\d{1,2}/.source)}function E(e,t){var n,r=u({},e);for(n in t)s(t,n)&&(S(e[n])&&S(t[n])?(r[n]={},u(r[n],e[n]),u(r[n],t[n])):null!=t[n]?r[n]=t[n]:delete r[n]);return r}function D(e){null!=e&&this.set(e)}function T(e){return e?e.toLowerCase().replace("_","-"):e}function A(e){for(var t,n,r,i,o=0;o0;){if(r=M(i.slice(0,t).join("-")))return r;if(n&&n.length>=t&&b(i,n,!0)>=t-1)break;t--}o++}return null}function M(n){var r=null;if(!or[n]&&"undefined"!=typeof t&&t&&t.exports)try{r=ir._abbr,e("./locale/"+n),O(r)}catch(i){}return or[n]}function O(e,t){var n;return e&&(n=p(t)?I(e):F(e,t),n&&(ir=n)),ir._abbr}function F(e,t){return null!==t?(t.abbr=e,null!=or[e]?(k("defineLocaleOverride","use moment.updateLocale(localeName, config) to change an existing locale. moment.defineLocale(localeName, config) should only be used for creating a new locale"),t=E(or[e]._config,t)):null!=t.parentLocale&&(null!=or[t.parentLocale]?t=E(or[t.parentLocale]._config,t):k("parentLocaleUndefined","specified parentLocale is not defined yet")),or[e]=new D(t),O(e),or[e]):(delete or[e],null)}function N(e,t){if(null!=t){var n;null!=or[e]&&(t=E(or[e]._config,t)),n=new D(t),n.parentLocale=or[e],or[e]=n,O(e)}else null!=or[e]&&(null!=or[e].parentLocale?or[e]=or[e].parentLocale:null!=or[e]&&delete or[e]);return or[e]}function I(e){var t;if(e&&e._locale&&e._locale._abbr&&(e=e._locale._abbr),!e)return ir;if(!i(e)){if(t=M(e))return t;e=[e]}return A(e)}function j(){return Object.keys(or)}function P(e,t){var n=e.toLowerCase();ar[n]=ar[n+"s"]=ar[t]=e}function L(e){return"string"==typeof e?ar[e]||ar[e.toLowerCase()]:void 0}function R(e){var t,n,r={};for(n in e)s(e,n)&&(t=L(n),t&&(r[t]=e[n]));return r}function U(e,t){return function(r){return null!=r?(z(this,e,r),n.updateOffset(this,t),this):V(this,e)}}function V(e,t){return e.isValid()?e._d["get"+(e._isUTC?"UTC":"")+t]():NaN}function z(e,t,n){e.isValid()&&e._d["set"+(e._isUTC?"UTC":"")+t](n)}function H(e,t){var n;if("object"==typeof e)for(n in e)this.set(n,e[n]);else if(e=L(e),C(this[e]))return this[e](t);return this}function q(e,t,n){var r=""+Math.abs(e),i=t-r.length,o=e>=0;return(o?n?"+":"":"-")+Math.pow(10,Math.max(0,i)).toString().substr(1)+r}function Y(e,t,n,r){var i=r;"string"==typeof r&&(i=function(){return this[r]()}),e&&(cr[e]=i),t&&(cr[t[0]]=function(){return q(i.apply(this,arguments),t[1],t[2])}),n&&(cr[n]=function(){return this.localeData().ordinal(i.apply(this,arguments),e)})}function W(e){return e.match(/\[[\s\S]/)?e.replace(/^\[|\]$/g,""):e.replace(/\\/g,"")}function B(e){var t,n,r=e.match(sr);for(t=0,n=r.length;n>t;t++)cr[r[t]]?r[t]=cr[r[t]]:r[t]=W(r[t]);return function(i){var o="";for(t=0;n>t;t++)o+=r[t]instanceof Function?r[t].call(i,e):r[t];return o}}function G(e,t){return e.isValid()?(t=Z(t,e.localeData()),lr[t]=lr[t]||B(t),lr[t](e)):e.localeData().invalidDate()}function Z(e,t){function n(e){return t.longDateFormat(e)||e}var r=5;for(ur.lastIndex=0;r>=0&&ur.test(e);)e=e.replace(ur,n),ur.lastIndex=0,r-=1;return e}function Q(e,t,n){Dr[e]=C(t)?t:function(e,r){return e&&n?n:t}}function X(e,t){return s(Dr,e)?Dr[e](t._strict,t._locale):new RegExp(J(e))}function J(e){return K(e.replace("\\","").replace(/\\(\[)|\\(\])|\[([^\]\[]*)\]|\\(.)/g,function(e,t,n,r,i){return t||n||r||i}))}function K(e){return e.replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&")}function ee(e,t){var n,r=t;for("string"==typeof e&&(e=[e]),"number"==typeof t&&(r=function(e,n){n[t]=y(e)}),n=0;nr;r++){if(i=l([2e3,r]),n&&!this._longMonthsParse[r]&&(this._longMonthsParse[r]=new RegExp("^"+this.months(i,"").replace(".","")+"$","i"),this._shortMonthsParse[r]=new RegExp("^"+this.monthsShort(i,"").replace(".","")+"$","i")),n||this._monthsParse[r]||(o="^"+this.months(i,"")+"|^"+this.monthsShort(i,""),this._monthsParse[r]=new RegExp(o.replace(".",""),"i")),n&&"MMMM"===t&&this._longMonthsParse[r].test(e))return r;if(n&&"MMM"===t&&this._shortMonthsParse[r].test(e))return r;if(!n&&this._monthsParse[r].test(e))return r}}function se(e,t){var n;if(!e.isValid())return e;if("string"==typeof t)if(/^\d+$/.test(t))t=y(t);else if(t=e.localeData().monthsParse(t),"number"!=typeof t)return e;return n=Math.min(e.date(),re(e.year(),t)),e._d["set"+(e._isUTC?"UTC":"")+"Month"](t,n),e}function ue(e){return null!=e?(se(this,e),n.updateOffset(this,!0),this):V(this,"Month")}function le(){return re(this.year(),this.month())}function ce(e){return this._monthsParseExact?(s(this,"_monthsRegex")||de.call(this),e?this._monthsShortStrictRegex:this._monthsShortRegex):this._monthsShortStrictRegex&&e?this._monthsShortStrictRegex:this._monthsShortRegex}function fe(e){return this._monthsParseExact?(s(this,"_monthsRegex")||de.call(this),e?this._monthsStrictRegex:this._monthsRegex):this._monthsStrictRegex&&e?this._monthsStrictRegex:this._monthsRegex}function de(){function e(e,t){return t.length-e.length}var t,n,r=[],i=[],o=[];for(t=0;12>t;t++)n=l([2e3,t]),r.push(this.monthsShort(n,"")),i.push(this.months(n,"")),o.push(this.months(n,"")),o.push(this.monthsShort(n,""));for(r.sort(e),i.sort(e),o.sort(e),t=0;12>t;t++)r[t]=K(r[t]),i[t]=K(i[t]),o[t]=K(o[t]);this._monthsRegex=new RegExp("^("+o.join("|")+")","i"),this._monthsShortRegex=this._monthsRegex,this._monthsStrictRegex=new RegExp("^("+i.join("|")+")$","i"),this._monthsShortStrictRegex=new RegExp("^("+r.join("|")+")$","i")}function he(e){var t,n=e._a;return n&&-2===f(e).overflow&&(t=n[Mr]<0||n[Mr]>11?Mr:n[Or]<1||n[Or]>re(n[Ar],n[Mr])?Or:n[Fr]<0||n[Fr]>24||24===n[Fr]&&(0!==n[Nr]||0!==n[Ir]||0!==n[jr])?Fr:n[Nr]<0||n[Nr]>59?Nr:n[Ir]<0||n[Ir]>59?Ir:n[jr]<0||n[jr]>999?jr:-1,f(e)._overflowDayOfYear&&(Ar>t||t>Or)&&(t=Or),f(e)._overflowWeeks&&-1===t&&(t=Pr),f(e)._overflowWeekday&&-1===t&&(t=Lr),f(e).overflow=t),e}function pe(e){var t,n,r,i,o,a,s=e._i,u=qr.exec(s)||Yr.exec(s);if(u){for(f(e).iso=!0,t=0,n=Br.length;n>t;t++)if(Br[t][1].exec(u[1])){i=Br[t][0],r=Br[t][2]!==!1;break}if(null==i)return void(e._isValid=!1);if(u[3]){for(t=0,n=Gr.length;n>t;t++)if(Gr[t][1].exec(u[3])){o=(u[2]||" ")+Gr[t][0];break}if(null==o)return void(e._isValid=!1)}if(!r&&null!=o)return void(e._isValid=!1);if(u[4]){if(!Wr.exec(u[4]))return void(e._isValid=!1);a="Z"}e._f=i+(o||"")+(a||""),Te(e)}else e._isValid=!1}function me(e){var t=Zr.exec(e._i);return null!==t?void(e._d=new Date(+t[1])):(pe(e),void(e._isValid===!1&&(delete e._isValid,n.createFromInputFallback(e))))}function ge(e,t,n,r,i,o,a){var s=new Date(e,t,n,r,i,o,a);return 100>e&&e>=0&&isFinite(s.getFullYear())&&s.setFullYear(e),s}function ve(e){var t=new Date(Date.UTC.apply(null,arguments));return 100>e&&e>=0&&isFinite(t.getUTCFullYear())&&t.setUTCFullYear(e),t}function $e(e){return ye(e)?366:365}function ye(e){return e%4===0&&e%100!==0||e%400===0}function be(){return ye(this.year())}function we(e,t,n){var r=7+t-n,i=(7+ve(e,0,r).getUTCDay()-t)%7;return-i+r-1}function xe(e,t,n,r,i){var o,a,s=(7+n-r)%7,u=we(e,r,i),l=1+7*(t-1)+s+u;return 0>=l?(o=e-1,a=$e(o)+l):l>$e(e)?(o=e+1,a=l-$e(e)):(o=e,a=l),{year:o,dayOfYear:a}}function ke(e,t,n){var r,i,o=we(e.year(),t,n),a=Math.floor((e.dayOfYear()-o-1)/7)+1;return 1>a?(i=e.year()-1,r=a+Ce(i,t,n)):a>Ce(e.year(),t,n)?(r=a-Ce(e.year(),t,n),i=e.year()+1):(i=e.year(),r=a),{week:r,year:i}}function Ce(e,t,n){var r=we(e,t,n),i=we(e+1,t,n);return($e(e)-r+i)/7}function Se(e,t,n){return null!=e?e:null!=t?t:n}function _e(e){var t=new Date(n.now());return e._useUTC?[t.getUTCFullYear(),t.getUTCMonth(),t.getUTCDate()]:[t.getFullYear(),t.getMonth(),t.getDate()]}function Ee(e){var t,n,r,i,o=[];if(!e._d){for(r=_e(e),e._w&&null==e._a[Or]&&null==e._a[Mr]&&De(e),e._dayOfYear&&(i=Se(e._a[Ar],r[Ar]),e._dayOfYear>$e(i)&&(f(e)._overflowDayOfYear=!0),n=ve(i,0,e._dayOfYear),e._a[Mr]=n.getUTCMonth(),e._a[Or]=n.getUTCDate()),t=0;3>t&&null==e._a[t];++t)e._a[t]=o[t]=r[t];for(;7>t;t++)e._a[t]=o[t]=null==e._a[t]?2===t?1:0:e._a[t];24===e._a[Fr]&&0===e._a[Nr]&&0===e._a[Ir]&&0===e._a[jr]&&(e._nextDay=!0,e._a[Fr]=0),e._d=(e._useUTC?ve:ge).apply(null,o),null!=e._tzm&&e._d.setUTCMinutes(e._d.getUTCMinutes()-e._tzm),e._nextDay&&(e._a[Fr]=24)}}function De(e){var t,n,r,i,o,a,s,u;t=e._w,null!=t.GG||null!=t.W||null!=t.E?(o=1,a=4,n=Se(t.GG,e._a[Ar],ke(Pe(),1,4).year),r=Se(t.W,1),i=Se(t.E,1),(1>i||i>7)&&(u=!0)):(o=e._locale._week.dow,a=e._locale._week.doy,n=Se(t.gg,e._a[Ar],ke(Pe(),o,a).year),r=Se(t.w,1),null!=t.d?(i=t.d,(0>i||i>6)&&(u=!0)):null!=t.e?(i=t.e+o,(t.e<0||t.e>6)&&(u=!0)):i=o),1>r||r>Ce(n,o,a)?f(e)._overflowWeeks=!0:null!=u?f(e)._overflowWeekday=!0:(s=xe(n,r,i,o,a),e._a[Ar]=s.year,e._dayOfYear=s.dayOfYear)}function Te(e){if(e._f===n.ISO_8601)return void pe(e);e._a=[],f(e).empty=!0;var t,r,i,o,a,s=""+e._i,u=s.length,l=0;for(i=Z(e._f,e._locale).match(sr)||[],t=0;t0&&f(e).unusedInput.push(a),s=s.slice(s.indexOf(r)+r.length),l+=r.length),cr[o]?(r?f(e).empty=!1:f(e).unusedTokens.push(o),ne(o,r,e)):e._strict&&!r&&f(e).unusedTokens.push(o);f(e).charsLeftOver=u-l,s.length>0&&f(e).unusedInput.push(s),f(e).bigHour===!0&&e._a[Fr]<=12&&e._a[Fr]>0&&(f(e).bigHour=void 0),e._a[Fr]=Ae(e._locale,e._a[Fr],e._meridiem),Ee(e),he(e)}function Ae(e,t,n){var r;return null==n?t:null!=e.meridiemHour?e.meridiemHour(t,n):null!=e.isPM?(r=e.isPM(n),r&&12>t&&(t+=12),r||12!==t||(t=0),t):t}function Me(e){var t,n,r,i,o;if(0===e._f.length)return f(e).invalidFormat=!0,void(e._d=new Date(NaN));for(i=0;io)&&(r=o,n=t));u(e,n||t)}function Oe(e){if(!e._d){var t=R(e._i);e._a=a([t.year,t.month,t.day||t.date,t.hour,t.minute,t.second,t.millisecond],function(e){return e&&parseInt(e,10)}),Ee(e)}}function Fe(e){var t=new g(he(Ne(e)));return t._nextDay&&(t.add(1,"d"),t._nextDay=void 0),t}function Ne(e){var t=e._i,n=e._f;return e._locale=e._locale||I(e._l),null===t||void 0===n&&""===t?h({nullInput:!0}):("string"==typeof t&&(e._i=t=e._locale.preparse(t)),v(t)?new g(he(t)):(i(n)?Me(e):n?Te(e):o(t)?e._d=t:Ie(e),d(e)||(e._d=null),e))}function Ie(e){var t=e._i;void 0===t?e._d=new Date(n.now()):o(t)?e._d=new Date(+t):"string"==typeof t?me(e):i(t)?(e._a=a(t.slice(0),function(e){return parseInt(e,10)}),Ee(e)):"object"==typeof t?Oe(e):"number"==typeof t?e._d=new Date(t):n.createFromInputFallback(e)}function je(e,t,n,r,i){var o={};return"boolean"==typeof n&&(r=n,n=void 0),o._isAMomentObject=!0,o._useUTC=o._isUTC=i,o._l=n,o._i=e,o._f=t,o._strict=r,Fe(o)}function Pe(e,t,n,r){return je(e,t,n,r,!1)}function Le(e,t){var n,r;if(1===t.length&&i(t[0])&&(t=t[0]),!t.length)return Pe();for(n=t[0],r=1;re&&(e=-e,n="-"),n+q(~~(e/60),2)+t+q(~~e%60,2)})}function qe(e,t){var n=(t||"").match(e)||[],r=n[n.length-1]||[],i=(r+"").match(ei)||["-",0,0],o=+(60*i[1])+y(i[2]);return"+"===i[0]?o:-o}function Ye(e,t){var r,i;return t._isUTC?(r=t.clone(),i=(v(e)||o(e)?+e:+Pe(e))-+r,r._d.setTime(+r._d+i),n.updateOffset(r,!1),r):Pe(e).local()}function We(e){return 15*-Math.round(e._d.getTimezoneOffset()/15)}function Be(e,t){var r,i=this._offset||0;return this.isValid()?null!=e?("string"==typeof e?e=qe(Sr,e):Math.abs(e)<16&&(e=60*e),!this._isUTC&&t&&(r=We(this)),this._offset=e,this._isUTC=!0,null!=r&&this.add(r,"m"),i!==e&&(!t||this._changeInProgress?ct(this,it(e-i,"m"),1,!1):this._changeInProgress||(this._changeInProgress=!0,n.updateOffset(this,!0),this._changeInProgress=null)),this):this._isUTC?i:We(this):null!=e?this:NaN}function Ge(e,t){return null!=e?("string"!=typeof e&&(e=-e),this.utcOffset(e,t),this):-this.utcOffset()}function Ze(e){return this.utcOffset(0,e)}function Qe(e){return this._isUTC&&(this.utcOffset(0,e),this._isUTC=!1,e&&this.subtract(We(this),"m")),this}function Xe(){return this._tzm?this.utcOffset(this._tzm):"string"==typeof this._i&&this.utcOffset(qe(Cr,this._i)),this}function Je(e){return this.isValid()?(e=e?Pe(e).utcOffset():0,(this.utcOffset()-e)%60===0):!1}function Ke(){return this.utcOffset()>this.clone().month(0).utcOffset()||this.utcOffset()>this.clone().month(5).utcOffset()}function et(){if(!p(this._isDSTShifted))return this._isDSTShifted;var e={};if(m(e,this),e=Ne(e),e._a){var t=e._isUTC?l(e._a):Pe(e._a);this._isDSTShifted=this.isValid()&&b(e._a,t.toArray())>0}else this._isDSTShifted=!1;return this._isDSTShifted}function tt(){return this.isValid()?!this._isUTC:!1}function nt(){return this.isValid()?this._isUTC:!1}function rt(){return this.isValid()?this._isUTC&&0===this._offset:!1}function it(e,t){var n,r,i,o=e,a=null;return ze(e)?o={ms:e._milliseconds,d:e._days,M:e._months}:"number"==typeof e?(o={},t?o[t]=e:o.milliseconds=e):(a=ti.exec(e))?(n="-"===a[1]?-1:1,o={y:0,d:y(a[Or])*n,h:y(a[Fr])*n,m:y(a[Nr])*n,s:y(a[Ir])*n,ms:y(a[jr])*n}):(a=ni.exec(e))?(n="-"===a[1]?-1:1,o={y:ot(a[2],n),M:ot(a[3],n),w:ot(a[4],n),d:ot(a[5],n),h:ot(a[6],n),m:ot(a[7],n),s:ot(a[8],n)}):null==o?o={}:"object"==typeof o&&("from"in o||"to"in o)&&(i=st(Pe(o.from),Pe(o.to)),o={},o.ms=i.milliseconds,o.M=i.months),r=new Ve(o),ze(e)&&s(e,"_locale")&&(r._locale=e._locale),r}function ot(e,t){var n=e&&parseFloat(e.replace(",","."));return(isNaN(n)?0:n)*t}function at(e,t){var n={milliseconds:0,months:0};return n.months=t.month()-e.month()+12*(t.year()-e.year()),e.clone().add(n.months,"M").isAfter(t)&&--n.months,n.milliseconds=+t-+e.clone().add(n.months,"M"),n}function st(e,t){var n;return e.isValid()&&t.isValid()?(t=Ye(t,e),e.isBefore(t)?n=at(e,t):(n=at(t,e),n.milliseconds=-n.milliseconds,n.months=-n.months),n):{milliseconds:0,months:0}}function ut(e){return 0>e?-1*Math.round(-1*e):Math.round(e)}function lt(e,t){return function(n,r){var i,o;return null===r||isNaN(+r)||(k(t,"moment()."+t+"(period, number) is deprecated. Please use moment()."+t+"(number, period)."),o=n,n=r,r=o),n="string"==typeof n?+n:n,i=it(n,r),ct(this,i,e),this}}function ct(e,t,r,i){var o=t._milliseconds,a=ut(t._days),s=ut(t._months);e.isValid()&&(i=null==i?!0:i,o&&e._d.setTime(+e._d+o*r),a&&z(e,"Date",V(e,"Date")+a*r),s&&se(e,V(e,"Month")+s*r),i&&n.updateOffset(e,a||s))}function ft(e,t){var n=e||Pe(),r=Ye(n,this).startOf("day"),i=this.diff(r,"days",!0),o=-6>i?"sameElse":-1>i?"lastWeek":0>i?"lastDay":1>i?"sameDay":2>i?"nextDay":7>i?"nextWeek":"sameElse",a=t&&(C(t[o])?t[o]():t[o]);return this.format(a||this.localeData().calendar(o,this,Pe(n)))}function dt(){return new g(this)}function ht(e,t){var n=v(e)?e:Pe(e);return this.isValid()&&n.isValid()?(t=L(p(t)?"millisecond":t),"millisecond"===t?+this>+n:+n<+this.clone().startOf(t)):!1}function pt(e,t){var n=v(e)?e:Pe(e);return this.isValid()&&n.isValid()?(t=L(p(t)?"millisecond":t),"millisecond"===t?+n>+this:+this.clone().endOf(t)<+n):!1}function mt(e,t,n){return this.isAfter(e,n)&&this.isBefore(t,n)}function gt(e,t){var n,r=v(e)?e:Pe(e);return this.isValid()&&r.isValid()?(t=L(t||"millisecond"),"millisecond"===t?+this===+r:(n=+r,+this.clone().startOf(t)<=n&&n<=+this.clone().endOf(t))):!1}function vt(e,t){return this.isSame(e,t)||this.isAfter(e,t)}function $t(e,t){return this.isSame(e,t)||this.isBefore(e,t)}function yt(e,t,n){var r,i,o,a;return this.isValid()?(r=Ye(e,this),r.isValid()?(i=6e4*(r.utcOffset()-this.utcOffset()),t=L(t),"year"===t||"month"===t||"quarter"===t?(a=bt(this,r),"quarter"===t?a/=3:"year"===t&&(a/=12)):(o=this-r,a="second"===t?o/1e3:"minute"===t?o/6e4:"hour"===t?o/36e5:"day"===t?(o-i)/864e5:"week"===t?(o-i)/6048e5:o),n?a:$(a)):NaN):NaN}function bt(e,t){var n,r,i=12*(t.year()-e.year())+(t.month()-e.month()),o=e.clone().add(i,"months");return 0>t-o?(n=e.clone().add(i-1,"months"),r=(t-o)/(o-n)):(n=e.clone().add(i+1,"months"),r=(t-o)/(n-o)),-(i+r)}function wt(){return this.clone().locale("en").format("ddd MMM DD YYYY HH:mm:ss [GMT]ZZ")}function xt(){var e=this.clone().utc();return 0o&&(t=o),Gt.call(this,e,t,n,r,i))}function Gt(e,t,n,r,i){var o=xe(e,t,n,r,i),a=ve(o.year,0,o.dayOfYear);return this.year(a.getUTCFullYear()),this.month(a.getUTCMonth()),this.date(a.getUTCDate()),this}function Zt(e){return null==e?Math.ceil((this.month()+1)/3):this.month(3*(e-1)+this.month()%3)}function Qt(e){return ke(e,this._week.dow,this._week.doy).week}function Xt(){return this._week.dow}function Jt(){return this._week.doy}function Kt(e){var t=this.localeData().week(this);return null==e?t:this.add(7*(e-t),"d")}function en(e){var t=ke(this,1,4).week;return null==e?t:this.add(7*(e-t),"d")}function tn(e,t){return"string"!=typeof e?e:isNaN(e)?(e=t.weekdaysParse(e),"number"==typeof e?e:null):parseInt(e,10)}function nn(e,t){return i(this._weekdays)?this._weekdays[e.day()]:this._weekdays[this._weekdays.isFormat.test(t)?"format":"standalone"][e.day()]}function rn(e){return this._weekdaysShort[e.day()]}function on(e){return this._weekdaysMin[e.day()]}function an(e,t,n){var r,i,o;for(this._weekdaysParse||(this._weekdaysParse=[],this._minWeekdaysParse=[],this._shortWeekdaysParse=[],this._fullWeekdaysParse=[]),r=0;7>r;r++){if(i=Pe([2e3,1]).day(r),n&&!this._fullWeekdaysParse[r]&&(this._fullWeekdaysParse[r]=new RegExp("^"+this.weekdays(i,"").replace(".",".?")+"$","i"),this._shortWeekdaysParse[r]=new RegExp("^"+this.weekdaysShort(i,"").replace(".",".?")+"$","i"),this._minWeekdaysParse[r]=new RegExp("^"+this.weekdaysMin(i,"").replace(".",".?")+"$","i")),this._weekdaysParse[r]||(o="^"+this.weekdays(i,"")+"|^"+this.weekdaysShort(i,"")+"|^"+this.weekdaysMin(i,""),this._weekdaysParse[r]=new RegExp(o.replace(".",""),"i")),n&&"dddd"===t&&this._fullWeekdaysParse[r].test(e))return r;if(n&&"ddd"===t&&this._shortWeekdaysParse[r].test(e))return r;if(n&&"dd"===t&&this._minWeekdaysParse[r].test(e))return r;if(!n&&this._weekdaysParse[r].test(e))return r}}function sn(e){if(!this.isValid())return null!=e?this:NaN;var t=this._isUTC?this._d.getUTCDay():this._d.getDay();return null!=e?(e=tn(e,this.localeData()),this.add(e-t,"d")):t}function un(e){if(!this.isValid())return null!=e?this:NaN;var t=(this.day()+7-this.localeData()._week.dow)%7;return null==e?t:this.add(e-t,"d")}function ln(e){return this.isValid()?null==e?this.day()||7:this.day(this.day()%7?e:e-7):null!=e?this:NaN}function cn(e){var t=Math.round((this.clone().startOf("day")-this.clone().startOf("year"))/864e5)+1;return null==e?t:this.add(e-t,"d")}function fn(){return this.hours()%12||12}function dn(e,t){Y(e,0,0,function(){return this.localeData().meridiem(this.hours(),this.minutes(),t)})}function hn(e,t){return t._meridiemParse}function pn(e){return"p"===(e+"").toLowerCase().charAt(0)}function mn(e,t,n){return e>11?n?"pm":"PM":n?"am":"AM"}function gn(e,t){t[jr]=y(1e3*("0."+e))}function vn(){return this._isUTC?"UTC":""}function $n(){return this._isUTC?"Coordinated Universal Time":""}function yn(e){return Pe(1e3*e)}function bn(){return Pe.apply(null,arguments).parseZone()}function wn(e,t,n){var r=this._calendar[e];return C(r)?r.call(t,n):r}function xn(e){var t=this._longDateFormat[e],n=this._longDateFormat[e.toUpperCase()];return t||!n?t:(this._longDateFormat[e]=n.replace(/MMMM|MM|DD|dddd/g,function(e){return e.slice(1)}),this._longDateFormat[e])}function kn(){return this._invalidDate}function Cn(e){return this._ordinal.replace("%d",e)}function Sn(e){return e}function _n(e,t,n,r){var i=this._relativeTime[n];return C(i)?i(e,t,n,r):i.replace(/%d/i,e)}function En(e,t){var n=this._relativeTime[e>0?"future":"past"];return C(n)?n(t):n.replace(/%s/i,t)}function Dn(e,t,n,r){var i=I(),o=l().set(r,t);return i[n](o,e)}function Tn(e,t,n,r,i){if("number"==typeof e&&(t=e,e=void 0),e=e||"",null!=t)return Dn(e,t,n,i);var o,a=[];for(o=0;r>o;o++)a[o]=Dn(e,o,n,i);return a}function An(e,t){return Tn(e,t,"months",12,"month")}function Mn(e,t){return Tn(e,t,"monthsShort",12,"month")}function On(e,t){return Tn(e,t,"weekdays",7,"day")}function Fn(e,t){return Tn(e,t,"weekdaysShort",7,"day")}function Nn(e,t){return Tn(e,t,"weekdaysMin",7,"day")}function In(){var e=this._data;return this._milliseconds=_i(this._milliseconds),this._days=_i(this._days),this._months=_i(this._months),e.milliseconds=_i(e.milliseconds),e.seconds=_i(e.seconds),e.minutes=_i(e.minutes),e.hours=_i(e.hours),e.months=_i(e.months),e.years=_i(e.years),this}function jn(e,t,n,r){var i=it(t,n);return e._milliseconds+=r*i._milliseconds,e._days+=r*i._days,e._months+=r*i._months,e._bubble()}function Pn(e,t){return jn(this,e,t,1)}function Ln(e,t){return jn(this,e,t,-1)}function Rn(e){return 0>e?Math.floor(e):Math.ceil(e)}function Un(){var e,t,n,r,i,o=this._milliseconds,a=this._days,s=this._months,u=this._data;return o>=0&&a>=0&&s>=0||0>=o&&0>=a&&0>=s||(o+=864e5*Rn(zn(s)+a),a=0,s=0),u.milliseconds=o%1e3,e=$(o/1e3),u.seconds=e%60,t=$(e/60),u.minutes=t%60,n=$(t/60),u.hours=n%24,a+=$(n/24),i=$(Vn(a)),s+=i,a-=Rn(zn(i)),r=$(s/12),s%=12,u.days=a,u.months=s,u.years=r,this}function Vn(e){return 4800*e/146097}function zn(e){return 146097*e/4800}function Hn(e){var t,n,r=this._milliseconds;if(e=L(e),"month"===e||"year"===e)return t=this._days+r/864e5,n=this._months+Vn(t),"month"===e?n:n/12;switch(t=this._days+Math.round(zn(this._months)),e){case"week":return t/7+r/6048e5;case"day":return t+r/864e5;case"hour":return 24*t+r/36e5;case"minute":return 1440*t+r/6e4;case"second":return 86400*t+r/1e3;case"millisecond":return Math.floor(864e5*t)+r;default:throw new Error("Unknown unit "+e)}}function qn(){return this._milliseconds+864e5*this._days+this._months%12*2592e6+31536e6*y(this._months/12)}function Yn(e){return function(){return this.as(e)}}function Wn(e){return e=L(e),this[e+"s"]()}function Bn(e){return function(){return this._data[e]}}function Gn(){return $(this.days()/7)}function Zn(e,t,n,r,i){return i.relativeTime(t||1,!!n,e,r)}function Qn(e,t,n){var r=it(e).abs(),i=zi(r.as("s")),o=zi(r.as("m")),a=zi(r.as("h")),s=zi(r.as("d")),u=zi(r.as("M")),l=zi(r.as("y")),c=i=o&&["m"]||o=a&&["h"]||a=s&&["d"]||s=u&&["M"]||u=l&&["y"]||["yy",l];return c[2]=t,c[3]=+e>0,c[4]=n,Zn.apply(null,c)}function Xn(e,t){return void 0===Hi[e]?!1:void 0===t?Hi[e]:(Hi[e]=t,!0)}function Jn(e){var t=this.localeData(),n=Qn(this,!e,t);return e&&(n=t.pastFuture(+this,n)),t.postformat(n)}function Kn(){var e,t,n,r=qi(this._milliseconds)/1e3,i=qi(this._days),o=qi(this._months);e=$(r/60),t=$(e/60),r%=60,e%=60,n=$(o/12),o%=12;var a=n,s=o,u=i,l=t,c=e,f=r,d=this.asSeconds();return d?(0>d?"-":"")+"P"+(a?a+"Y":"")+(s?s+"M":"")+(u?u+"D":"")+(l||c||f?"T":"")+(l?l+"H":"")+(c?c+"M":"")+(f?f+"S":""):"P0D"}var er,tr=n.momentProperties=[],nr=!1,rr={};n.suppressDeprecationWarnings=!1;var ir,or={},ar={},sr=/(\[[^\[]*\])|(\\)?([Hh]mm(ss)?|Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Qo?|YYYYYY|YYYYY|YYYY|YY|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?|.)/g,ur=/(\[[^\[]*\])|(\\)?(LTS|LT|LL?L?L?|l{1,4})/g,lr={},cr={},fr=/\d/,dr=/\d\d/,hr=/\d{3}/,pr=/\d{4}/,mr=/[+-]?\d{6}/,gr=/\d\d?/,vr=/\d\d\d\d?/,$r=/\d\d\d\d\d\d?/,yr=/\d{1,3}/,br=/\d{1,4}/,wr=/[+-]?\d{1,6}/,xr=/\d+/,kr=/[+-]?\d+/,Cr=/Z|[+-]\d\d:?\d\d/gi,Sr=/Z|[+-]\d\d(?::?\d\d)?/gi,_r=/[+-]?\d+(\.\d{1,3})?/,Er=/[0-9]*['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]+|[\u0600-\u06FF\/]+(\s*?[\u0600-\u06FF]+){1,2}/i,Dr={},Tr={},Ar=0,Mr=1,Or=2,Fr=3,Nr=4,Ir=5,jr=6,Pr=7,Lr=8;Y("M",["MM",2],"Mo",function(){return this.month()+1}),Y("MMM",0,0,function(e){return this.localeData().monthsShort(this,e)}),Y("MMMM",0,0,function(e){return this.localeData().months(this,e)}),P("month","M"),Q("M",gr),Q("MM",gr,dr),Q("MMM",function(e,t){return t.monthsShortRegex(e)}),Q("MMMM",function(e,t){return t.monthsRegex(e)}),ee(["M","MM"],function(e,t){t[Mr]=y(e)-1}),ee(["MMM","MMMM"],function(e,t,n,r){var i=n._locale.monthsParse(e,r,n._strict);null!=i?t[Mr]=i:f(n).invalidMonth=e});var Rr=/D[oD]?(\[[^\[\]]*\]|\s+)+MMMM?/,Ur="January_February_March_April_May_June_July_August_September_October_November_December".split("_"),Vr="Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),zr=Er,Hr=Er,qr=/^\s*((?:[+-]\d{6}|\d{4})-(?:\d\d-\d\d|W\d\d-\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?::\d\d(?::\d\d(?:[.,]\d+)?)?)?)([\+\-]\d\d(?::?\d\d)?|\s*Z)?)?/,Yr=/^\s*((?:[+-]\d{6}|\d{4})(?:\d\d\d\d|W\d\d\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?:\d\d(?:\d\d(?:[.,]\d+)?)?)?)([\+\-]\d\d(?::?\d\d)?|\s*Z)?)?/,Wr=/Z|[+-]\d\d(?::?\d\d)?/,Br=[["YYYYYY-MM-DD",/[+-]\d{6}-\d\d-\d\d/],["YYYY-MM-DD",/\d{4}-\d\d-\d\d/],["GGGG-[W]WW-E",/\d{4}-W\d\d-\d/],["GGGG-[W]WW",/\d{4}-W\d\d/,!1],["YYYY-DDD",/\d{4}-\d{3}/],["YYYY-MM",/\d{4}-\d\d/,!1],["YYYYYYMMDD",/[+-]\d{10}/],["YYYYMMDD",/\d{8}/],["GGGG[W]WWE",/\d{4}W\d{3}/],["GGGG[W]WW",/\d{4}W\d{2}/,!1],["YYYYDDD",/\d{7}/]],Gr=[["HH:mm:ss.SSSS",/\d\d:\d\d:\d\d\.\d+/],["HH:mm:ss,SSSS",/\d\d:\d\d:\d\d,\d+/],["HH:mm:ss",/\d\d:\d\d:\d\d/],["HH:mm",/\d\d:\d\d/],["HHmmss.SSSS",/\d\d\d\d\d\d\.\d+/],["HHmmss,SSSS",/\d\d\d\d\d\d,\d+/],["HHmmss",/\d\d\d\d\d\d/],["HHmm",/\d\d\d\d/],["HH",/\d\d/]],Zr=/^\/?Date\((\-?\d+)/i;n.createFromInputFallback=x("moment construction falls back to js Date. This is discouraged and will be removed in upcoming major release. Please refer to https://github.com/moment/moment/issues/1407 for more info.",function(e){e._d=new Date(e._i+(e._useUTC?" UTC":""))}),Y("Y",0,0,function(){var e=this.year();return 9999>=e?""+e:"+"+e}),Y(0,["YY",2],0,function(){return this.year()%100}),Y(0,["YYYY",4],0,"year"),Y(0,["YYYYY",5],0,"year"),Y(0,["YYYYYY",6,!0],0,"year"),P("year","y"),Q("Y",kr),Q("YY",gr,dr),Q("YYYY",br,pr),Q("YYYYY",wr,mr),Q("YYYYYY",wr,mr),ee(["YYYYY","YYYYYY"],Ar),ee("YYYY",function(e,t){t[Ar]=2===e.length?n.parseTwoDigitYear(e):y(e)}),ee("YY",function(e,t){t[Ar]=n.parseTwoDigitYear(e)}),ee("Y",function(e,t){t[Ar]=parseInt(e,10)}),n.parseTwoDigitYear=function(e){return y(e)+(y(e)>68?1900:2e3)};var Qr=U("FullYear",!1);n.ISO_8601=function(){};var Xr=x("moment().min is deprecated, use moment.max instead. https://github.com/moment/moment/issues/1548",function(){var e=Pe.apply(null,arguments);return this.isValid()&&e.isValid()?this>e?this:e:h()}),Jr=x("moment().max is deprecated, use moment.min instead. https://github.com/moment/moment/issues/1548",function(){var e=Pe.apply(null,arguments);return this.isValid()&&e.isValid()?e>this?this:e:h()}),Kr=function(){return Date.now?Date.now():+new Date};He("Z",":"),He("ZZ",""),Q("Z",Sr),Q("ZZ",Sr),ee(["Z","ZZ"],function(e,t,n){n._useUTC=!0,n._tzm=qe(Sr,e)});var ei=/([\+\-]|\d\d)/gi;n.updateOffset=function(){};var ti=/^(\-)?(?:(\d*)[. ])?(\d+)\:(\d+)(?:\:(\d+)\.?(\d{3})?\d*)?$/,ni=/^(-)?P(?:([0-9,.]*)Y)?(?:([0-9,.]*)M)?(?:([0-9,.]*)W)?(?:([0-9,.]*)D)?(?:T(?:([0-9,.]*)H)?(?:([0-9,.]*)M)?(?:([0-9,.]*)S)?)?$/;it.fn=Ve.prototype;var ri=lt(1,"add"),ii=lt(-1,"subtract");n.defaultFormat="YYYY-MM-DDTHH:mm:ssZ";var oi=x("moment().lang() is deprecated. Instead, use moment().localeData() to get the language configuration. Use moment().locale() to change languages.",function(e){return void 0===e?this.localeData():this.locale(e)});Y(0,["gg",2],0,function(){return this.weekYear()%100}),Y(0,["GG",2],0,function(){return this.isoWeekYear()%100}),zt("gggg","weekYear"),zt("ggggg","weekYear"),zt("GGGG","isoWeekYear"),zt("GGGGG","isoWeekYear"),P("weekYear","gg"),P("isoWeekYear","GG"),Q("G",kr),Q("g",kr),Q("GG",gr,dr),Q("gg",gr,dr),Q("GGGG",br,pr),Q("gggg",br,pr),Q("GGGGG",wr,mr),Q("ggggg",wr,mr),te(["gggg","ggggg","GGGG","GGGGG"],function(e,t,n,r){t[r.substr(0,2)]=y(e)}),te(["gg","GG"],function(e,t,r,i){t[i]=n.parseTwoDigitYear(e)}),Y("Q",0,"Qo","quarter"),P("quarter","Q"),Q("Q",fr),ee("Q",function(e,t){t[Mr]=3*(y(e)-1)}),Y("w",["ww",2],"wo","week"),Y("W",["WW",2],"Wo","isoWeek"),P("week","w"),P("isoWeek","W"),Q("w",gr),Q("ww",gr,dr),Q("W",gr),Q("WW",gr,dr),te(["w","ww","W","WW"],function(e,t,n,r){t[r.substr(0,1)]=y(e)});var ai={dow:0,doy:6};Y("D",["DD",2],"Do","date"),P("date","D"),Q("D",gr),Q("DD",gr,dr),Q("Do",function(e,t){return e?t._ordinalParse:t._ordinalParseLenient}),ee(["D","DD"],Or),ee("Do",function(e,t){t[Or]=y(e.match(gr)[0],10)});var si=U("Date",!0);Y("d",0,"do","day"),Y("dd",0,0,function(e){return this.localeData().weekdaysMin(this,e)}),Y("ddd",0,0,function(e){return this.localeData().weekdaysShort(this,e)}),Y("dddd",0,0,function(e){return this.localeData().weekdays(this,e)}),Y("e",0,0,"weekday"),Y("E",0,0,"isoWeekday"),P("day","d"),P("weekday","e"),P("isoWeekday","E"),Q("d",gr),Q("e",gr),Q("E",gr),Q("dd",Er),Q("ddd",Er),Q("dddd",Er),te(["dd","ddd","dddd"],function(e,t,n,r){var i=n._locale.weekdaysParse(e,r,n._strict);null!=i?t.d=i:f(n).invalidWeekday=e}),te(["d","e","E"],function(e,t,n,r){t[r]=y(e)});var ui="Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),li="Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),ci="Su_Mo_Tu_We_Th_Fr_Sa".split("_");Y("DDD",["DDDD",3],"DDDo","dayOfYear"),P("dayOfYear","DDD"),Q("DDD",yr),Q("DDDD",hr),ee(["DDD","DDDD"],function(e,t,n){n._dayOfYear=y(e)}),Y("H",["HH",2],0,"hour"),Y("h",["hh",2],0,fn),Y("hmm",0,0,function(){return""+fn.apply(this)+q(this.minutes(),2)}),Y("hmmss",0,0,function(){return""+fn.apply(this)+q(this.minutes(),2)+q(this.seconds(),2)}),Y("Hmm",0,0,function(){return""+this.hours()+q(this.minutes(),2)}),Y("Hmmss",0,0,function(){return""+this.hours()+q(this.minutes(),2)+q(this.seconds(),2)}),dn("a",!0),dn("A",!1),P("hour","h"),Q("a",hn),Q("A",hn),Q("H",gr),Q("h",gr),Q("HH",gr,dr),Q("hh",gr,dr),Q("hmm",vr),Q("hmmss",$r),Q("Hmm",vr),Q("Hmmss",$r),ee(["H","HH"],Fr),ee(["a","A"],function(e,t,n){n._isPm=n._locale.isPM(e),n._meridiem=e}),ee(["h","hh"],function(e,t,n){t[Fr]=y(e),f(n).bigHour=!0}),ee("hmm",function(e,t,n){var r=e.length-2;t[Fr]=y(e.substr(0,r)),t[Nr]=y(e.substr(r)),f(n).bigHour=!0}),ee("hmmss",function(e,t,n){var r=e.length-4,i=e.length-2;t[Fr]=y(e.substr(0,r)),t[Nr]=y(e.substr(r,2)),t[Ir]=y(e.substr(i)),f(n).bigHour=!0}),ee("Hmm",function(e,t,n){var r=e.length-2;t[Fr]=y(e.substr(0,r)),t[Nr]=y(e.substr(r))}),ee("Hmmss",function(e,t,n){var r=e.length-4,i=e.length-2;t[Fr]=y(e.substr(0,r)),t[Nr]=y(e.substr(r,2)),t[Ir]=y(e.substr(i))});var fi=/[ap]\.?m?\.?/i,di=U("Hours",!0);Y("m",["mm",2],0,"minute"),P("minute","m"),Q("m",gr),Q("mm",gr,dr),ee(["m","mm"],Nr);var hi=U("Minutes",!1);Y("s",["ss",2],0,"second"),P("second","s"),Q("s",gr),Q("ss",gr,dr),ee(["s","ss"],Ir);var pi=U("Seconds",!1);Y("S",0,0,function(){return~~(this.millisecond()/100)}),Y(0,["SS",2],0,function(){return~~(this.millisecond()/10)}),Y(0,["SSS",3],0,"millisecond"),Y(0,["SSSS",4],0,function(){return 10*this.millisecond()}),Y(0,["SSSSS",5],0,function(){return 100*this.millisecond()}),Y(0,["SSSSSS",6],0,function(){return 1e3*this.millisecond()}),Y(0,["SSSSSSS",7],0,function(){return 1e4*this.millisecond()}),Y(0,["SSSSSSSS",8],0,function(){return 1e5*this.millisecond()}),Y(0,["SSSSSSSSS",9],0,function(){return 1e6*this.millisecond()}),P("millisecond","ms"),Q("S",yr,fr),Q("SS",yr,dr),Q("SSS",yr,hr);var mi;for(mi="SSSS";mi.length<=9;mi+="S")Q(mi,xr);for(mi="S";mi.length<=9;mi+="S")ee(mi,gn);var gi=U("Milliseconds",!1);Y("z",0,0,"zoneAbbr"),Y("zz",0,0,"zoneName");var vi=g.prototype;vi.add=ri,vi.calendar=ft,vi.clone=dt,vi.diff=yt,vi.endOf=Mt,vi.format=kt,vi.from=Ct,vi.fromNow=St,vi.to=_t,vi.toNow=Et,vi.get=H,vi.invalidAt=Ut,vi.isAfter=ht,vi.isBefore=pt,vi.isBetween=mt,vi.isSame=gt,vi.isSameOrAfter=vt,vi.isSameOrBefore=$t,vi.isValid=Lt,vi.lang=oi,vi.locale=Dt,vi.localeData=Tt,vi.max=Jr,vi.min=Xr,vi.parsingFlags=Rt,vi.set=H,vi.startOf=At,vi.subtract=ii,vi.toArray=It,vi.toObject=jt,vi.toDate=Nt,vi.toISOString=xt,vi.toJSON=Pt,vi.toString=wt,vi.unix=Ft,vi.valueOf=Ot,vi.creationData=Vt,vi.year=Qr,vi.isLeapYear=be,vi.weekYear=Ht,vi.isoWeekYear=qt,vi.quarter=vi.quarters=Zt,vi.month=ue,vi.daysInMonth=le,vi.week=vi.weeks=Kt,vi.isoWeek=vi.isoWeeks=en,vi.weeksInYear=Wt,vi.isoWeeksInYear=Yt,vi.date=si,vi.day=vi.days=sn,vi.weekday=un,vi.isoWeekday=ln,vi.dayOfYear=cn,vi.hour=vi.hours=di,vi.minute=vi.minutes=hi,vi.second=vi.seconds=pi,vi.millisecond=vi.milliseconds=gi,vi.utcOffset=Be,vi.utc=Ze,vi.local=Qe,vi.parseZone=Xe,vi.hasAlignedHourOffset=Je,vi.isDST=Ke,vi.isDSTShifted=et,vi.isLocal=tt,vi.isUtcOffset=nt,vi.isUtc=rt,vi.isUTC=rt,vi.zoneAbbr=vn,vi.zoneName=$n,vi.dates=x("dates accessor is deprecated. Use date instead.",si),vi.months=x("months accessor is deprecated. Use month instead",ue),vi.years=x("years accessor is deprecated. Use year instead",Qr),vi.zone=x("moment().zone is deprecated, use moment().utcOffset instead. https://github.com/moment/moment/issues/1779",Ge); var $i=vi,yi={sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},bi={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"},wi="Invalid date",xi="%d",ki=/\d{1,2}/,Ci={future:"in %s",past:"%s ago",s:"a few seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"},Si=D.prototype;Si._calendar=yi,Si.calendar=wn,Si._longDateFormat=bi,Si.longDateFormat=xn,Si._invalidDate=wi,Si.invalidDate=kn,Si._ordinal=xi,Si.ordinal=Cn,Si._ordinalParse=ki,Si.preparse=Sn,Si.postformat=Sn,Si._relativeTime=Ci,Si.relativeTime=_n,Si.pastFuture=En,Si.set=_,Si.months=ie,Si._months=Ur,Si.monthsShort=oe,Si._monthsShort=Vr,Si.monthsParse=ae,Si._monthsRegex=Hr,Si.monthsRegex=fe,Si._monthsShortRegex=zr,Si.monthsShortRegex=ce,Si.week=Qt,Si._week=ai,Si.firstDayOfYear=Jt,Si.firstDayOfWeek=Xt,Si.weekdays=nn,Si._weekdays=ui,Si.weekdaysMin=on,Si._weekdaysMin=ci,Si.weekdaysShort=rn,Si._weekdaysShort=li,Si.weekdaysParse=an,Si.isPM=pn,Si._meridiemParse=fi,Si.meridiem=mn,O("en",{ordinalParse:/\d{1,2}(th|st|nd|rd)/,ordinal:function(e){var t=e%10,n=1===y(e%100/10)?"th":1===t?"st":2===t?"nd":3===t?"rd":"th";return e+n}}),n.lang=x("moment.lang is deprecated. Use moment.locale instead.",O),n.langData=x("moment.langData is deprecated. Use moment.localeData instead.",I);var _i=Math.abs,Ei=Yn("ms"),Di=Yn("s"),Ti=Yn("m"),Ai=Yn("h"),Mi=Yn("d"),Oi=Yn("w"),Fi=Yn("M"),Ni=Yn("y"),Ii=Bn("milliseconds"),ji=Bn("seconds"),Pi=Bn("minutes"),Li=Bn("hours"),Ri=Bn("days"),Ui=Bn("months"),Vi=Bn("years"),zi=Math.round,Hi={s:45,m:45,h:22,d:26,M:11},qi=Math.abs,Yi=Ve.prototype;Yi.abs=In,Yi.add=Pn,Yi.subtract=Ln,Yi.as=Hn,Yi.asMilliseconds=Ei,Yi.asSeconds=Di,Yi.asMinutes=Ti,Yi.asHours=Ai,Yi.asDays=Mi,Yi.asWeeks=Oi,Yi.asMonths=Fi,Yi.asYears=Ni,Yi.valueOf=qn,Yi._bubble=Un,Yi.get=Wn,Yi.milliseconds=Ii,Yi.seconds=ji,Yi.minutes=Pi,Yi.hours=Li,Yi.days=Ri,Yi.weeks=Gn,Yi.months=Ui,Yi.years=Vi,Yi.humanize=Jn,Yi.toISOString=Kn,Yi.toString=Kn,Yi.toJSON=Kn,Yi.locale=Dt,Yi.localeData=Tt,Yi.toIsoString=x("toIsoString() is deprecated. Please use toISOString() instead (notice the capitals)",Kn),Yi.lang=oi,Y("X",0,0,"unix"),Y("x",0,0,"valueOf"),Q("x",kr),Q("X",_r),ee("X",function(e,t,n){n._d=new Date(1e3*parseFloat(e,10))}),ee("x",function(e,t,n){n._d=new Date(y(e))}),n.version="2.12.0",r(Pe),n.fn=$i,n.min=Re,n.max=Ue,n.now=Kr,n.utc=l,n.unix=yn,n.months=An,n.isDate=o,n.locale=O,n.invalid=h,n.duration=it,n.isMoment=v,n.weekdays=On,n.parseZone=bn,n.localeData=I,n.isDuration=ze,n.monthsShort=Mn,n.weekdaysMin=Nn,n.defineLocale=F,n.updateLocale=N,n.locales=j,n.weekdaysShort=Fn,n.normalizeUnits=L,n.relativeTimeThreshold=Xn,n.prototype=$i;var Wi=n;return Wi})},{}],12:[function(e,t,n){!function(e,n){"use strict";var r,i,o,a=e,s=a.document,u=a.navigator,l=a.setTimeout,c=a.clearTimeout,f=a.setInterval,d=a.clearInterval,h=a.getComputedStyle,p=a.encodeURIComponent,m=a.ActiveXObject,g=a.Error,v=a.Number.parseInt||a.parseInt,$=a.Number.parseFloat||a.parseFloat,y=a.Number.isNaN||a.isNaN,b=a.Date.now,w=a.Object.keys,x=a.Object.defineProperty,k=a.Object.prototype.hasOwnProperty,C=a.Array.prototype.slice,S=function(){var e=function(e){return e};if("function"==typeof a.wrap&&"function"==typeof a.unwrap)try{var t=s.createElement("div"),n=a.unwrap(t);1===t.nodeType&&n&&1===n.nodeType&&(e=a.unwrap)}catch(r){}return e}(),_=function(e){return C.call(e,0)},E=function(){var e,t,r,i,o,a,s=_(arguments),u=s[0]||{};for(e=1,t=s.length;t>e;e++)if(null!=(r=s[e]))for(i in r)k.call(r,i)&&(o=u[i],a=r[i],u!==a&&a!==n&&(u[i]=a));return u},D=function(e){var t,n,r,i;if("object"!=typeof e||null==e||"number"==typeof e.nodeType)t=e;else if("number"==typeof e.length)for(t=[],n=0,r=e.length;r>n;n++)k.call(e,n)&&(t[n]=D(e[n]));else{t={};for(i in e)k.call(e,i)&&(t[i]=D(e[i]))}return t},T=function(e,t){for(var n={},r=0,i=t.length;i>r;r++)t[r]in e&&(n[t[r]]=e[t[r]]);return n},A=function(e,t){var n={};for(var r in e)-1===t.indexOf(r)&&(n[r]=e[r]);return n},M=function(e){if(e)for(var t in e)k.call(e,t)&&delete e[t];return e},O=function(e,t){if(e&&1===e.nodeType&&e.ownerDocument&&t&&(1===t.nodeType&&t.ownerDocument&&t.ownerDocument===e.ownerDocument||9===t.nodeType&&!t.ownerDocument&&t===e.ownerDocument))do{if(e===t)return!0;e=e.parentNode}while(e);return!1},F=function(e){var t;return"string"==typeof e&&e&&(t=e.split("#")[0].split("?")[0],t=e.slice(0,e.lastIndexOf("/")+1)),t},N=function(e){var t,n;return"string"==typeof e&&e&&(n=e.match(/^(?:|[^:@]*@|.+\)@(?=http[s]?|file)|.+?\s+(?: at |@)(?:[^:\(]+ )*[\(]?)((?:http[s]?|file):\/\/[\/]?.+?\/[^:\)]*?)(?::\d+)(?::\d+)?/),n&&n[1]?t=n[1]:(n=e.match(/\)@((?:http[s]?|file):\/\/[\/]?.+?\/[^:\)]*?)(?::\d+)(?::\d+)?/),n&&n[1]&&(t=n[1]))),t},I=function(){var e,t;try{throw new g}catch(n){t=n}return t&&(e=t.sourceURL||t.fileName||N(t.stack)),e},j=function(){var e,t,r;if(s.currentScript&&(e=s.currentScript.src))return e;if(t=s.getElementsByTagName("script"),1===t.length)return t[0].src||n;if("readyState"in t[0])for(r=t.length;r--;)if("interactive"===t[r].readyState&&(e=t[r].src))return e;return"loading"===s.readyState&&(e=t[t.length-1].src)?e:(e=I())?e:n},P=function(){var e,t,r,i=s.getElementsByTagName("script");for(e=i.length;e--;){if(!(r=i[e].src)){t=null;break}if(r=F(r),null==t)t=r;else if(t!==r){t=null;break}}return t||n},L=function(){var e=F(j())||P()||"";return e+"ZeroClipboard.swf"},R=function(){return null==e.opener&&(!!e.top&&e!=e.top||!!e.parent&&e!=e.parent)}(),U={bridge:null,version:"0.0.0",pluginType:"unknown",disabled:null,outdated:null,sandboxed:null,unavailable:null,degraded:null,deactivated:null,overdue:null,ready:null},V="11.0.0",z={},H={},q=null,Y=0,W=0,B={ready:"Flash communication is established",error:{"flash-disabled":"Flash is disabled or not installed. May also be attempting to run Flash in a sandboxed iframe, which is impossible.","flash-outdated":"Flash is too outdated to support ZeroClipboard","flash-sandboxed":"Attempting to run Flash in a sandboxed iframe, which is impossible","flash-unavailable":"Flash is unable to communicate bidirectionally with JavaScript","flash-degraded":"Flash is unable to preserve data fidelity when communicating with JavaScript","flash-deactivated":"Flash is too outdated for your browser and/or is configured as click-to-activate.\nThis may also mean that the ZeroClipboard SWF object could not be loaded, so please check your `swfPath` configuration and/or network connectivity.\nMay also be attempting to run Flash in a sandboxed iframe, which is impossible.","flash-overdue":"Flash communication was established but NOT within the acceptable time limit","version-mismatch":"ZeroClipboard JS version number does not match ZeroClipboard SWF version number","clipboard-error":"At least one error was thrown while ZeroClipboard was attempting to inject your data into the clipboard","config-mismatch":"ZeroClipboard configuration does not match Flash's reality","swf-not-found":"The ZeroClipboard SWF object could not be loaded, so please check your `swfPath` configuration and/or network connectivity"}},G=["flash-unavailable","flash-degraded","flash-overdue","version-mismatch","config-mismatch","clipboard-error"],Z=["flash-disabled","flash-outdated","flash-sandboxed","flash-unavailable","flash-degraded","flash-deactivated","flash-overdue"],Q=new RegExp("^flash-("+Z.map(function(e){return e.replace(/^flash-/,"")}).join("|")+")$"),X=new RegExp("^flash-("+Z.slice(1).map(function(e){return e.replace(/^flash-/,"")}).join("|")+")$"),J={swfPath:L(),trustedDomains:e.location.host?[e.location.host]:[],cacheBust:!0,forceEnhancedClipboard:!1,flashLoadTimeout:3e4,autoActivate:!0,bubbleEvents:!0,containerId:"global-zeroclipboard-html-bridge",containerClass:"global-zeroclipboard-container",swfObjectId:"global-zeroclipboard-flash-bridge",hoverClass:"zeroclipboard-is-hover",activeClass:"zeroclipboard-is-active",forceHandCursor:!1,title:null,zIndex:999999999},K=function(e){if("object"==typeof e&&null!==e)for(var t in e)if(k.call(e,t))if(/^(?:forceHandCursor|title|zIndex|bubbleEvents)$/.test(t))J[t]=e[t];else if(null==U.bridge)if("containerId"===t||"swfObjectId"===t){if(!pe(e[t]))throw new Error("The specified `"+t+"` value is not valid as an HTML4 Element ID");J[t]=e[t]}else J[t]=e[t];{if("string"!=typeof e||!e)return D(J);if(k.call(J,e))return J[e]}},ee=function(){return We(),{browser:T(u,["userAgent","platform","appName"]),flash:A(U,["bridge"]),zeroclipboard:{version:Ge.version,config:Ge.config()}}},te=function(){return!!(U.disabled||U.outdated||U.sandboxed||U.unavailable||U.degraded||U.deactivated)},ne=function(e,t){var i,o,a,s={};if("string"==typeof e&&e)a=e.toLowerCase().split(/\s+/);else if("object"==typeof e&&e&&"undefined"==typeof t)for(i in e)k.call(e,i)&&"string"==typeof i&&i&&"function"==typeof e[i]&&Ge.on(i,e[i]);if(a&&a.length){for(i=0,o=a.length;o>i;i++)e=a[i].replace(/^on/,""),s[e]=!0,z[e]||(z[e]=[]),z[e].push(t);if(s.ready&&U.ready&&Ge.emit({type:"ready"}),s.error){for(i=0,o=Z.length;o>i;i++)if(U[Z[i].replace(/^flash-/,"")]===!0){Ge.emit({type:"error",name:Z[i]});break}r!==n&&Ge.version!==r&&Ge.emit({type:"error",name:"version-mismatch",jsVersion:Ge.version,swfVersion:r})}}return Ge},re=function(e,t){var n,r,i,o,a;if(0===arguments.length)o=w(z);else if("string"==typeof e&&e)o=e.split(/\s+/);else if("object"==typeof e&&e&&"undefined"==typeof t)for(n in e)k.call(e,n)&&"string"==typeof n&&n&&"function"==typeof e[n]&&Ge.off(n,e[n]);if(o&&o.length)for(n=0,r=o.length;r>n;n++)if(e=o[n].toLowerCase().replace(/^on/,""),a=z[e],a&&a.length)if(t)for(i=a.indexOf(t);-1!==i;)a.splice(i,1),i=a.indexOf(t,i);else a.length=0;return Ge},ie=function(e){var t;return t="string"==typeof e&&e?D(z[e])||null:D(z)},oe=function(e){var t,n,r;return e=me(e),e&&!xe(e)?"ready"===e.type&&U.overdue===!0?Ge.emit({type:"error",name:"flash-overdue"}):(t=E({},e),be.call(this,t),"copy"===e.type&&(r=Ae(H),n=r.data,q=r.formatMap),n):void 0},ae=function(){var e=U.sandboxed;if(We(),"boolean"!=typeof U.ready&&(U.ready=!1),U.sandboxed!==e&&U.sandboxed===!0)U.ready=!1,Ge.emit({type:"error",name:"flash-sandboxed"});else if(!Ge.isFlashUnusable()&&null===U.bridge){var t=J.flashLoadTimeout;"number"==typeof t&&t>=0&&(Y=l(function(){"boolean"!=typeof U.deactivated&&(U.deactivated=!0),U.deactivated===!0&&Ge.emit({type:"error",name:"flash-deactivated"})},t)),U.overdue=!1,De()}},se=function(){Ge.clearData(),Ge.blur(),Ge.emit("destroy"),Te(),Ge.off()},ue=function(e,t){var n;if("object"==typeof e&&e&&"undefined"==typeof t)n=e,Ge.clearData();else{if("string"!=typeof e||!e)return;n={},n[e]=t}for(var r in n)"string"==typeof r&&r&&k.call(n,r)&&"string"==typeof n[r]&&n[r]&&(H[r]=n[r])},le=function(e){"undefined"==typeof e?(M(H),q=null):"string"==typeof e&&k.call(H,e)&&delete H[e]},ce=function(e){return"undefined"==typeof e?D(H):"string"==typeof e&&k.call(H,e)?H[e]:void 0},fe=function(e){if(e&&1===e.nodeType){i&&(Le(i,J.activeClass),i!==e&&Le(i,J.hoverClass)),i=e,Pe(e,J.hoverClass);var t=e.getAttribute("title")||J.title;if("string"==typeof t&&t){var n=Ee(U.bridge);n&&n.setAttribute("title",t)}var r=J.forceHandCursor===!0||"pointer"===Re(e,"cursor");qe(r),He()}},de=function(){var e=Ee(U.bridge);e&&(e.removeAttribute("title"),e.style.left="0px",e.style.top="-9999px",e.style.width="1px",e.style.height="1px"),i&&(Le(i,J.hoverClass),Le(i,J.activeClass),i=null)},he=function(){return i||null},pe=function(e){return"string"==typeof e&&e&&/^[A-Za-z][A-Za-z0-9_:\-\.]*$/.test(e)},me=function(e){var t;if("string"==typeof e&&e?(t=e,e={}):"object"==typeof e&&e&&"string"==typeof e.type&&e.type&&(t=e.type),t){t=t.toLowerCase(),!e.target&&(/^(copy|aftercopy|_click)$/.test(t)||"error"===t&&"clipboard-error"===e.name)&&(e.target=o),E(e,{type:t,target:e.target||i||null,relatedTarget:e.relatedTarget||null,currentTarget:U&&U.bridge||null,timeStamp:e.timeStamp||b()||null});var n=B[e.type];return"error"===e.type&&e.name&&n&&(n=n[e.name]),n&&(e.message=n),"ready"===e.type&&E(e,{target:null,version:U.version}),"error"===e.type&&(Q.test(e.name)&&E(e,{target:null,minimumVersion:V}),X.test(e.name)&&E(e,{version:U.version})),"copy"===e.type&&(e.clipboardData={setData:Ge.setData,clearData:Ge.clearData}),"aftercopy"===e.type&&(e=Me(e,q)),e.target&&!e.relatedTarget&&(e.relatedTarget=ge(e.target)),ve(e)}},ge=function(e){var t=e&&e.getAttribute&&e.getAttribute("data-clipboard-target");return t?s.getElementById(t):null},ve=function(e){if(e&&/^_(?:click|mouse(?:over|out|down|up|move))$/.test(e.type)){var t=e.target,r="_mouseover"===e.type&&e.relatedTarget?e.relatedTarget:n,i="_mouseout"===e.type&&e.relatedTarget?e.relatedTarget:n,o=Ue(t),u=a.screenLeft||a.screenX||0,l=a.screenTop||a.screenY||0,c=s.body.scrollLeft+s.documentElement.scrollLeft,f=s.body.scrollTop+s.documentElement.scrollTop,d=o.left+("number"==typeof e._stageX?e._stageX:0),h=o.top+("number"==typeof e._stageY?e._stageY:0),p=d-c,m=h-f,g=u+p,v=l+m,$="number"==typeof e.movementX?e.movementX:0,y="number"==typeof e.movementY?e.movementY:0;delete e._stageX,delete e._stageY,E(e,{srcElement:t,fromElement:r,toElement:i,screenX:g,screenY:v,pageX:d,pageY:h,clientX:p,clientY:m,x:p,y:m,movementX:$,movementY:y,offsetX:0,offsetY:0,layerX:0,layerY:0})}return e},$e=function(e){var t=e&&"string"==typeof e.type&&e.type||"";return!/^(?:(?:before)?copy|destroy)$/.test(t)},ye=function(e,t,n,r){r?l(function(){e.apply(t,n)},0):e.apply(t,n)},be=function(e){if("object"==typeof e&&e&&e.type){var t=$e(e),n=z["*"]||[],r=z[e.type]||[],i=n.concat(r);if(i&&i.length){var o,s,u,l,c,f=this;for(o=0,s=i.length;s>o;o++)u=i[o],l=f,"string"==typeof u&&"function"==typeof a[u]&&(u=a[u]),"object"==typeof u&&u&&"function"==typeof u.handleEvent&&(l=u,u=u.handleEvent),"function"==typeof u&&(c=E({},e),ye(u,l,[c],t))}return this}},we=function(e){var t=null;return(R===!1||e&&"error"===e.type&&e.name&&-1!==G.indexOf(e.name))&&(t=!1),t},xe=function(e){var t=e.target||i||null,n="swf"===e._source;switch(delete e._source,e.type){case"error":var a="flash-sandboxed"===e.name||we(e);"boolean"==typeof a&&(U.sandboxed=a),-1!==Z.indexOf(e.name)?E(U,{disabled:"flash-disabled"===e.name,outdated:"flash-outdated"===e.name,unavailable:"flash-unavailable"===e.name,degraded:"flash-degraded"===e.name,deactivated:"flash-deactivated"===e.name,overdue:"flash-overdue"===e.name,ready:!1}):"version-mismatch"===e.name&&(r=e.swfVersion,E(U,{disabled:!1,outdated:!1,unavailable:!1,degraded:!1,deactivated:!1,overdue:!1,ready:!1})),ze();break;case"ready":r=e.swfVersion;var s=U.deactivated===!0;E(U,{disabled:!1,outdated:!1,sandboxed:!1,unavailable:!1,degraded:!1,deactivated:!1,overdue:s,ready:!s}),ze();break;case"beforecopy":o=t;break;case"copy":var u,l,c=e.relatedTarget;!H["text/html"]&&!H["text/plain"]&&c&&(l=c.value||c.outerHTML||c.innerHTML)&&(u=c.value||c.textContent||c.innerText)?(e.clipboardData.clearData(),e.clipboardData.setData("text/plain",u),l!==u&&e.clipboardData.setData("text/html",l)):!H["text/plain"]&&e.target&&(u=e.target.getAttribute("data-clipboard-text"))&&(e.clipboardData.clearData(),e.clipboardData.setData("text/plain",u));break;case"aftercopy":ke(e),Ge.clearData(),t&&t!==je()&&t.focus&&t.focus();break;case"_mouseover":Ge.focus(t),J.bubbleEvents===!0&&n&&(t&&t!==e.relatedTarget&&!O(e.relatedTarget,t)&&Ce(E({},e,{type:"mouseenter",bubbles:!1,cancelable:!1})),Ce(E({},e,{type:"mouseover"})));break;case"_mouseout":Ge.blur(),J.bubbleEvents===!0&&n&&(t&&t!==e.relatedTarget&&!O(e.relatedTarget,t)&&Ce(E({},e,{type:"mouseleave",bubbles:!1,cancelable:!1})),Ce(E({},e,{type:"mouseout"})));break;case"_mousedown":Pe(t,J.activeClass),J.bubbleEvents===!0&&n&&Ce(E({},e,{type:e.type.slice(1)}));break;case"_mouseup":Le(t,J.activeClass),J.bubbleEvents===!0&&n&&Ce(E({},e,{type:e.type.slice(1)}));break;case"_click":o=null,J.bubbleEvents===!0&&n&&Ce(E({},e,{type:e.type.slice(1)}));break;case"_mousemove":J.bubbleEvents===!0&&n&&Ce(E({},e,{type:e.type.slice(1)}))}return/^_(?:click|mouse(?:over|out|down|up|move))$/.test(e.type)?!0:void 0},ke=function(e){if(e.errors&&e.errors.length>0){var t=D(e);E(t,{type:"error",name:"clipboard-error"}),delete t.success,l(function(){Ge.emit(t)},0)}},Ce=function(e){if(e&&"string"==typeof e.type&&e){var t,n=e.target||null,r=n&&n.ownerDocument||s,i={view:r.defaultView||a,canBubble:!0,cancelable:!0,detail:"click"===e.type?1:0,button:"number"==typeof e.which?e.which-1:"number"==typeof e.button?e.button:r.createEvent?0:1},o=E(i,e);n&&r.createEvent&&n.dispatchEvent&&(o=[o.type,o.canBubble,o.cancelable,o.view,o.detail,o.screenX,o.screenY,o.clientX,o.clientY,o.ctrlKey,o.altKey,o.shiftKey,o.metaKey,o.button,o.relatedTarget],t=r.createEvent("MouseEvents"),t.initMouseEvent&&(t.initMouseEvent.apply(t,o),t._source="js",n.dispatchEvent(t)))}},Se=function(){var e=J.flashLoadTimeout;if("number"==typeof e&&e>=0){var t=Math.min(1e3,e/10),n=J.swfObjectId+"_fallbackContent";W=f(function(){var e=s.getElementById(n);Ve(e)&&(ze(),U.deactivated=null,Ge.emit({type:"error",name:"swf-not-found"}))},t)}},_e=function(){var e=s.createElement("div");return e.id=J.containerId,e.className=J.containerClass,e.style.position="absolute",e.style.left="0px",e.style.top="-9999px",e.style.width="1px",e.style.height="1px",e.style.zIndex=""+Ye(J.zIndex),e},Ee=function(e){for(var t=e&&e.parentNode;t&&"OBJECT"===t.nodeName&&t.parentNode;)t=t.parentNode;return t||null},De=function(){var e,t=U.bridge,n=Ee(t);if(!t){var r=Ie(a.location.host,J),i="never"===r?"none":"all",o=Fe(E({jsVersion:Ge.version},J)),u=J.swfPath+Oe(J.swfPath,J);n=_e();var l=s.createElement("div");n.appendChild(l),s.body.appendChild(n);var c=s.createElement("div"),f="activex"===U.pluginType;c.innerHTML='"+(f?'':"")+'
     
    ',t=c.firstChild,c=null,S(t).ZeroClipboard=Ge,n.replaceChild(t,l),Se()}return t||(t=s[J.swfObjectId],t&&(e=t.length)&&(t=t[e-1]),!t&&n&&(t=n.firstChild)),U.bridge=t||null,t},Te=function(){var e=U.bridge;if(e){var t=Ee(e);t&&("activex"===U.pluginType&&"readyState"in e?(e.style.display="none",function i(){if(4===e.readyState){for(var n in e)"function"==typeof e[n]&&(e[n]=null);e.parentNode&&e.parentNode.removeChild(e),t.parentNode&&t.parentNode.removeChild(t)}else l(i,10)}()):(e.parentNode&&e.parentNode.removeChild(e),t.parentNode&&t.parentNode.removeChild(t))),ze(),U.ready=null,U.bridge=null,U.deactivated=null,r=n}},Ae=function(e){var t={},n={};if("object"==typeof e&&e){for(var r in e)if(r&&k.call(e,r)&&"string"==typeof e[r]&&e[r])switch(r.toLowerCase()){case"text/plain":case"text":case"air:text":case"flash:text":t.text=e[r],n.text=r;break;case"text/html":case"html":case"air:html":case"flash:html":t.html=e[r],n.html=r;break;case"application/rtf":case"text/rtf":case"rtf":case"richtext":case"air:rtf":case"flash:rtf":t.rtf=e[r],n.rtf=r}return{data:t,formatMap:n}}},Me=function(e,t){if("object"!=typeof e||!e||"object"!=typeof t||!t)return e;var n={};for(var r in e)if(k.call(e,r))if("errors"===r){n[r]=e[r]?e[r].slice():[];for(var i=0,o=n[r].length;o>i;i++)n[r][i].format=t[n[r][i].format]}else if("success"!==r&&"data"!==r)n[r]=e[r];else{n[r]={};var a=e[r];for(var s in a)s&&k.call(a,s)&&k.call(t,s)&&(n[r][t[s]]=a[s])}return n},Oe=function(e,t){var n=null==t||t&&t.cacheBust===!0;return n?(-1===e.indexOf("?")?"?":"&")+"noCache="+b():""},Fe=function(e){var t,n,r,i,o="",s=[];if(e.trustedDomains&&("string"==typeof e.trustedDomains?i=[e.trustedDomains]:"object"==typeof e.trustedDomains&&"length"in e.trustedDomains&&(i=e.trustedDomains)),i&&i.length)for(t=0,n=i.length;n>t;t++)if(k.call(i,t)&&i[t]&&"string"==typeof i[t]){if(r=Ne(i[t]),!r)continue;if("*"===r){s.length=0,s.push(r);break}s.push.apply(s,[r,"//"+r,a.location.protocol+"//"+r])}return s.length&&(o+="trustedOrigins="+p(s.join(","))),e.forceEnhancedClipboard===!0&&(o+=(o?"&":"")+"forceEnhancedClipboard=true"),"string"==typeof e.swfObjectId&&e.swfObjectId&&(o+=(o?"&":"")+"swfObjectId="+p(e.swfObjectId)),"string"==typeof e.jsVersion&&e.jsVersion&&(o+=(o?"&":"")+"jsVersion="+p(e.jsVersion)),o},Ne=function(e){if(null==e||""===e)return null;if(e=e.replace(/^\s+|\s+$/g,""),""===e)return null;var t=e.indexOf("//");e=-1===t?e:e.slice(t+2);var n=e.indexOf("/");return e=-1===n?e:-1===t||0===n?null:e.slice(0,n),e&&".swf"===e.slice(-4).toLowerCase()?null:e||null},Ie=function(){var e=function(e){var t,n,r,i=[];if("string"==typeof e&&(e=[e]),"object"!=typeof e||!e||"number"!=typeof e.length)return i;for(t=0,n=e.length;n>t;t++)if(k.call(e,t)&&(r=Ne(e[t]))){if("*"===r){i.length=0,i.push("*");break}-1===i.indexOf(r)&&i.push(r)}return i};return function(t,n){var r=Ne(n.swfPath);null===r&&(r=t);var i=e(n.trustedDomains),o=i.length;if(o>0){if(1===o&&"*"===i[0])return"always";if(-1!==i.indexOf(t))return 1===o&&t===r?"sameDomain":"always"}return"never"}}(),je=function(){try{return s.activeElement}catch(e){return null}},Pe=function(e,t){var n,r,i,o=[];if("string"==typeof t&&t&&(o=t.split(/\s+/)),e&&1===e.nodeType&&o.length>0)if(e.classList)for(n=0,r=o.length;r>n;n++)e.classList.add(o[n]);else if(e.hasOwnProperty("className")){for(i=" "+e.className+" ",n=0,r=o.length;r>n;n++)-1===i.indexOf(" "+o[n]+" ")&&(i+=o[n]+" ");e.className=i.replace(/^\s+|\s+$/g,"")}return e},Le=function(e,t){var n,r,i,o=[];if("string"==typeof t&&t&&(o=t.split(/\s+/)),e&&1===e.nodeType&&o.length>0)if(e.classList&&e.classList.length>0)for(n=0,r=o.length;r>n;n++)e.classList.remove(o[n]);else if(e.className){for(i=(" "+e.className+" ").replace(/[\r\n\t]/g," "),n=0,r=o.length;r>n;n++)i=i.replace(" "+o[n]+" "," ");e.className=i.replace(/^\s+|\s+$/g,"")}return e},Re=function(e,t){var n=h(e,null).getPropertyValue(t);return"cursor"!==t||n&&"auto"!==n||"A"!==e.nodeName?n:"pointer"},Ue=function(e){var t={left:0,top:0,width:0,height:0};if(e.getBoundingClientRect){var n=e.getBoundingClientRect(),r=a.pageXOffset,i=a.pageYOffset,o=s.documentElement.clientLeft||0,u=s.documentElement.clientTop||0,l=0,c=0;if("relative"===Re(s.body,"position")){var f=s.body.getBoundingClientRect(),d=s.documentElement.getBoundingClientRect();l=f.left-d.left||0,c=f.top-d.top||0}t.left=n.left+r-o-l,t.top=n.top+i-u-c,t.width="width"in n?n.width:n.right-n.left,t.height="height"in n?n.height:n.bottom-n.top}return t},Ve=function(e){if(!e)return!1;var t=h(e,null),n=$(t.height)>0,r=$(t.width)>0,i=$(t.top)>=0,o=$(t.left)>=0,a=n&&r&&i&&o,s=a?null:Ue(e),u="none"!==t.display&&"collapse"!==t.visibility&&(a||!!s&&(n||s.height>0)&&(r||s.width>0)&&(i||s.top>=0)&&(o||s.left>=0));return u},ze=function(){c(Y),Y=0,d(W),W=0},He=function(){var e;if(i&&(e=Ee(U.bridge))){var t=Ue(i);E(e.style,{width:t.width+"px",height:t.height+"px",top:t.top+"px",left:t.left+"px",zIndex:""+Ye(J.zIndex)})}},qe=function(e){U.ready===!0&&(U.bridge&&"function"==typeof U.bridge.setHandCursor?U.bridge.setHandCursor(e):U.ready=!1)},Ye=function(e){if(/^(?:auto|inherit)$/.test(e))return e;var t;return"number"!=typeof e||y(e)?"string"==typeof e&&(t=Ye(v(e,10))):t=e,"number"==typeof t?t:"auto"},We=function(t){var n,r,i,o=U.sandboxed,a=null;if(t=t===!0,R===!1)a=!1;else{try{r=e.frameElement||null}catch(s){i={name:s.name,message:s.message}}if(r&&1===r.nodeType&&"IFRAME"===r.nodeName)try{a=r.hasAttribute("sandbox")}catch(s){a=null}else{try{n=document.domain||null}catch(s){n=null}(null===n||i&&"SecurityError"===i.name&&/(^|[\s\(\[@])sandbox(es|ed|ing|[\s\.,!\)\]@]|$)/.test(i.message.toLowerCase()))&&(a=!0)}}return U.sandboxed=a,o===a||t||Be(m),a},Be=function(e){function t(e){var t=e.match(/[\d]+/g);return t.length=3,t.join(".")}function n(e){return!!e&&(e=e.toLowerCase())&&(/^(pepflashplayer\.dll|libpepflashplayer\.so|pepperflashplayer\.plugin)$/.test(e)||"chrome.plugin"===e.slice(-13))}function r(e){e&&(s=!0,e.version&&(f=t(e.version)),!f&&e.description&&(f=t(e.description)),e.filename&&(c=n(e.filename)))}var i,o,a,s=!1,l=!1,c=!1,f="";if(u.plugins&&u.plugins.length)i=u.plugins["Shockwave Flash"],r(i),u.plugins["Shockwave Flash 2.0"]&&(s=!0,f="2.0.0.11");else if(u.mimeTypes&&u.mimeTypes.length)a=u.mimeTypes["application/x-shockwave-flash"],i=a&&a.enabledPlugin,r(i);else if("undefined"!=typeof e){l=!0;try{o=new e("ShockwaveFlash.ShockwaveFlash.7"),s=!0,f=t(o.GetVariable("$version"))}catch(d){try{o=new e("ShockwaveFlash.ShockwaveFlash.6"),s=!0,f="6.0.21"}catch(h){try{o=new e("ShockwaveFlash.ShockwaveFlash"),s=!0,f=t(o.GetVariable("$version"))}catch(p){l=!1}}}}U.disabled=s!==!0,U.outdated=f&&$(f)<$(V),U.version=f||"0.0.0",U.pluginType=c?"pepper":l?"activex":s?"netscape":"unknown"};Be(m),We(!0);var Ge=function(){return this instanceof Ge?void("function"==typeof Ge._createClient&&Ge._createClient.apply(this,_(arguments))):new Ge};x(Ge,"version",{value:"2.2.0",writable:!1,configurable:!0,enumerable:!0}),Ge.config=function(){return K.apply(this,_(arguments))},Ge.state=function(){return ee.apply(this,_(arguments))},Ge.isFlashUnusable=function(){return te.apply(this,_(arguments))},Ge.on=function(){return ne.apply(this,_(arguments))},Ge.off=function(){return re.apply(this,_(arguments))},Ge.handlers=function(){return ie.apply(this,_(arguments))},Ge.emit=function(){return oe.apply(this,_(arguments))},Ge.create=function(){return ae.apply(this,_(arguments))},Ge.destroy=function(){return se.apply(this,_(arguments))},Ge.setData=function(){return ue.apply(this,_(arguments))},Ge.clearData=function(){return le.apply(this,_(arguments))},Ge.getData=function(){return ce.apply(this,_(arguments))},Ge.focus=Ge.activate=function(){return fe.apply(this,_(arguments))},Ge.blur=Ge.deactivate=function(){return de.apply(this,_(arguments))},Ge.activeElement=function(){return he.apply(this,_(arguments))};var Ze=0,Qe={},Xe=0,Je={},Ke={};E(J,{autoActivate:!0});var et=function(e){var t=this;t.id=""+Ze++,Qe[t.id]={instance:t,elements:[],handlers:{}},e&&t.clip(e),Ge.on("*",function(e){return t.emit(e)}),Ge.on("destroy",function(){t.destroy()}),Ge.create()},tt=function(e,t){var i,o,a,s={},u=Qe[this.id],l=u&&u.handlers;if(!u)throw new Error("Attempted to add new listener(s) to a destroyed ZeroClipboard client instance");if("string"==typeof e&&e)a=e.toLowerCase().split(/\s+/);else if("object"==typeof e&&e&&"undefined"==typeof t)for(i in e)k.call(e,i)&&"string"==typeof i&&i&&"function"==typeof e[i]&&this.on(i,e[i]);if(a&&a.length){for(i=0,o=a.length;o>i;i++)e=a[i].replace(/^on/,""),s[e]=!0,l[e]||(l[e]=[]),l[e].push(t);if(s.ready&&U.ready&&this.emit({type:"ready",client:this}),s.error){for(i=0,o=Z.length;o>i;i++)if(U[Z[i].replace(/^flash-/,"")]){this.emit({type:"error",name:Z[i],client:this});break}r!==n&&Ge.version!==r&&this.emit({type:"error",name:"version-mismatch",jsVersion:Ge.version,swfVersion:r})}}return this},nt=function(e,t){var n,r,i,o,a,s=Qe[this.id],u=s&&s.handlers;if(!u)return this;if(0===arguments.length)o=w(u);else if("string"==typeof e&&e)o=e.split(/\s+/);else if("object"==typeof e&&e&&"undefined"==typeof t)for(n in e)k.call(e,n)&&"string"==typeof n&&n&&"function"==typeof e[n]&&this.off(n,e[n]);if(o&&o.length)for(n=0,r=o.length;r>n;n++)if(e=o[n].toLowerCase().replace(/^on/,""),a=u[e],a&&a.length)if(t)for(i=a.indexOf(t);-1!==i;)a.splice(i,1),i=a.indexOf(t,i);else a.length=0;return this},rt=function(e){var t=null,n=Qe[this.id]&&Qe[this.id].handlers;return n&&(t="string"==typeof e&&e?n[e]?n[e].slice(0):[]:D(n)),t},it=function(e){if(lt.call(this,e)){"object"==typeof e&&e&&"string"==typeof e.type&&e.type&&(e=E({},e));var t=E({},me(e),{client:this});ct.call(this,t)}return this},ot=function(e){if(!Qe[this.id])throw new Error("Attempted to clip element(s) to a destroyed ZeroClipboard client instance");e=ft(e);for(var t=0;t0,i=!e.target||r&&-1!==n.indexOf(e.target),o=e.relatedTarget&&r&&-1!==n.indexOf(e.relatedTarget),a=e.client&&e.client===this;return t&&(i||o||a)?!0:!1},ct=function(e){var t=Qe[this.id];if("object"==typeof e&&e&&e.type&&t){var n=$e(e),r=t&&t.handlers["*"]||[],i=t&&t.handlers[e.type]||[],o=r.concat(i);if(o&&o.length){var s,u,l,c,f,d=this;for(s=0,u=o.length;u>s;s++)l=o[s],c=d,"string"==typeof l&&"function"==typeof a[l]&&(l=a[l]),"object"==typeof l&&l&&"function"==typeof l.handleEvent&&(c=l,l=l.handleEvent),"function"==typeof l&&(f=E({},e),ye(l,c,[f],n))}}},ft=function(e){return"string"==typeof e&&(e=[]),"number"!=typeof e.length?[e]:e},dt=function(e){if(e&&1===e.nodeType){var t=function(e){(e||(e=a.event))&&("js"!==e._source&&(e.stopImmediatePropagation(),e.preventDefault()),delete e._source)},n=function(n){(n||(n=a.event))&&(t(n),Ge.focus(e))};e.addEventListener("mouseover",n,!1),e.addEventListener("mouseout",t,!1),e.addEventListener("mouseenter",t,!1),e.addEventListener("mouseleave",t,!1),e.addEventListener("mousemove",t,!1),Ke[e.zcClippingId]={mouseover:n,mouseout:t,mouseenter:t,mouseleave:t,mousemove:t}}},ht=function(e){if(e&&1===e.nodeType){var t=Ke[e.zcClippingId];if("object"==typeof t&&t){for(var n,r,i=["move","leave","enter","out","over"],o=0,a=i.length;a>o;o++)n="mouse"+i[o],r=t[n],"function"==typeof r&&e.removeEventListener(n,r,!1);delete Ke[e.zcClippingId]}}};Ge._createClient=function(){et.apply(this,_(arguments))},Ge.prototype.on=function(){return tt.apply(this,_(arguments))},Ge.prototype.off=function(){return nt.apply(this,_(arguments))},Ge.prototype.handlers=function(){return rt.apply(this,_(arguments))},Ge.prototype.emit=function(){return it.apply(this,_(arguments))},Ge.prototype.clip=function(){return ot.apply(this,_(arguments))},Ge.prototype.unclip=function(){return at.apply(this,_(arguments))},Ge.prototype.elements=function(){return st.apply(this,_(arguments))},Ge.prototype.destroy=function(){return ut.apply(this,_(arguments))},Ge.prototype.setText=function(e){if(!Qe[this.id])throw new Error("Attempted to set pending clipboard data from a destroyed ZeroClipboard client instance");return Ge.setData("text/plain",e),this},Ge.prototype.setHtml=function(e){if(!Qe[this.id])throw new Error("Attempted to set pending clipboard data from a destroyed ZeroClipboard client instance");return Ge.setData("text/html",e),this},Ge.prototype.setRichText=function(e){if(!Qe[this.id])throw new Error("Attempted to set pending clipboard data from a destroyed ZeroClipboard client instance");return Ge.setData("application/rtf",e),this},Ge.prototype.setData=function(){if(!Qe[this.id])throw new Error("Attempted to set pending clipboard data from a destroyed ZeroClipboard client instance");return Ge.setData.apply(this,_(arguments)),this},Ge.prototype.clearData=function(){if(!Qe[this.id])throw new Error("Attempted to clear pending clipboard data from a destroyed ZeroClipboard client instance");return Ge.clearData.apply(this,_(arguments)), -this},Ge.prototype.getData=function(){if(!Qe[this.id])throw new Error("Attempted to get pending clipboard data from a destroyed ZeroClipboard client instance");return Ge.getData.apply(this,_(arguments))},"function"==typeof define&&define.amd?define(function(){return Ge}):"object"==typeof t&&t&&"object"==typeof t.exports&&t.exports?t.exports=Ge:e.ZeroClipboard=Ge}(function(){return this||window}())},{}],13:[function(e,t,n){t.exports='
    \n
    Drop files or click here to upload
    \n
    '},{}],14:[function(e,t,n){t.exports='\n
    \n
    \n Image Preview\n Image Preview\n
    \n \n
    \n\n \n |\n \n\n \n
    '},{}],15:[function(e,t,n){t.exports='
    \n \n
    \n
    '},{}],16:[function(e,t,n){"use strict";var r=e("moment");t.exports=function(t,n){t.controller("ImageManagerController",["$scope","$attrs","$http","$timeout","imageManagerService",function(e,t,r,i,o){function a(){e.searching=!1,e.searchTerm="",e.images=m,e.hasMore=g}function s(t){p&&p(t),e.showing=!1}function u(t){p=t,e.showing=!0,h||(l(),h=!0)}function l(){var t=v+c+"?",n={};e.uploadedTo&&(n.page_id=e.uploadedTo),e.searching&&(n.term=e.searchTerm);var i=Object.keys(n).map(function(e){return e+"="+encodeURIComponent(n[e])}).join("&");t+=i,r.get(t).then(function(t){e.images=e.images.concat(t.data.images),e.hasMore=t.data.hasMore,c++})}e.images=[],e.imageType=t.imageType,e.selectedImage=!1,e.dependantPages=!1,e.showing=!1,e.hasMore=!1,e.imageUpdateSuccess=!1,e.imageDeleteSuccess=!1,e.uploadedTo=t.uploadedTo,e.view="all",e.searching=!1,e.searchTerm="";var c=0,f=0,d=0,h=!1,p=!1,m=[],g=!1;e.getUploadUrl=function(){return"/images/"+e.imageType+"/upload"},e.cancelSearch=a,e.uploadSuccess=function(t,r){e.$apply(function(){e.images.unshift(r)}),n.emit("success","Image uploaded")},e.imageSelect=function(t){var n=300,r=Date.now(),i=r-f;n>i&&t.id===d?s(t):(e.selectedImage=t,e.dependantPages=!1),f=r,d=t.id},e.selectButtonClick=function(){s(e.selectedImage)},o.show=u,o.showExternal=function(t){e.$apply(function(){u(t)})},window.ImageManager=o,e.hide=function(){e.showing=!1};var v="/images/"+e.imageType+"/all/";e.fetchData=l,e.searchImages=function(){return""===e.searchTerm?void a():(e.searching||(m=e.images,g=e.hasMore),e.searching=!0,e.images=[],e.hasMore=!1,c=0,v="/images/"+e.imageType+"/search/",void l())},e.setView=function(t){a(),e.images=[],e.hasMore=!1,c=0,e.view=t,v="/images/"+e.imageType+"/"+t+"/",l()},e.saveImageDetails=function(t){t.preventDefault();var i="/images/update/"+e.selectedImage.id;r.put(i,this.selectedImage).then(function(e){n.emit("success","Image details updated")},function(e){if(422===e.status){var t=e.data,r="";Object.keys(t).forEach(function(e){r+=t[e].join("\n")}),n.emit("error",r)}else 403===e.status&&n.emit("error",e.data.error)})},e.deleteImage=function(t){t.preventDefault();var i=e.dependantPages!==!1,o="/images/"+e.selectedImage.id;i&&(o+="?force=true"),r["delete"](o).then(function(t){e.images.splice(e.images.indexOf(e.selectedImage),1),e.selectedImage=!1,n.emit("success","Image successfully deleted")},function(t){400===t.status?e.dependantPages=t.data:403===t.status&&n.emit("error",t.data.error)})},e.getDate=function(e){return new Date(e)}}]),t.controller("BookShowController",["$scope","$http","$attrs","$sce",function(e,t,n,r){e.searching=!1,e.searchTerm="",e.searchResults="",e.searchBook=function(i){i.preventDefault();var o=e.searchTerm;if(0!=o.length){e.searching=!0,e.searchResults="";var a="/search/book/"+n.bookId;a+="?term="+encodeURIComponent(o),t.get(a).then(function(t){e.searchResults=r.trustAsHtml(t.data)})}},e.checkSearchForm=function(){e.searchTerm.length<1&&(e.searching=!1)},e.clearSearch=function(){e.searching=!1,e.searchTerm=""}}]),t.controller("PageEditController",["$scope","$http","$attrs","$interval","$timeout","$sce",function(t,i,o,a,s,u){function l(){g.title=$("#name").val(),g.html=t.editContent,m=a(function(){var e=$("#name").val(),n=t.editContent;(e!==g.title||n!==g.html)&&(g.html=n,g.title=e,c())},1e3*h)}function c(){var e={name:$("#name").val(),html:p?u.getTrustedHtml(t.displayContent):t.editContent};p&&(e.markdown=t.editContent),i.put("/ajax/page/"+f+"/save-draft",e).then(function(e){var n=r.utc(r.unix(e.data.timestamp)).toDate();t.draftText=e.data.message+r(n).format("HH:mm"),t.isNewPageDraft||(t.isUpdateDraft=!0)})}t.editorOptions=e("./pages/page-form"),t.editContent="",t.draftText="";var f=Number(o.pageId),d=0!==f,h=30,p="markdown"===o.editorType;t.isUpdateDraft=1===Number(o.pageUpdateDraft),t.isNewPageDraft=1===Number(o.pageNewDraft),t.isUpdateDraft||t.isNewPageDraft?t.draftText="Editing Draft":t.draftText="Editing Page";var m=!1,g={title:!1,html:!1};d&&setTimeout(function(){l()},1e3),p&&(t.displayContent="",t.editorChange=function(e){t.displayContent=u.trustAsHtml(e)}),p||(t.editorChange=function(){}),t.forceDraftSave=function(){c()},t.discardDraft=function(){i.get("/ajax/page/"+f).then(function(e){m&&a.cancel(m),t.draftText="Editing Page",t.isUpdateDraft=!1,t.$broadcast("html-update",e.data.html),t.$broadcast("markdown-update",e.data.markdown||e.data.html),$("#name").val(e.data.name),s(function(){l()},1e3),n.emit("success","Draft discarded, The editor has been updated with the current page content")})}}])}},{"./pages/page-form":19,moment:11}],17:[function(e,t,n){"use strict";var r=e("dropzone"),i=e("marked"),o=e("./components/toggle-switch.html"),a=e("./components/image-picker.html"),s=e("./components/drop-zone.html");t.exports=function(e,t){e.directive("toggleSwitch",function(){return{restrict:"E",template:o,scope:!0,link:function(e,t,n){e.name=n.name,e.value=n.value,e.isActive=1==e.value&&"false"!=e.value,e.value=1==e.value&&"false"!=e.value?"true":"false",e["switch"]=function(){e.isActive=!e.isActive,e.value=e.isActive?"true":"false"}}}}),e.directive("imagePicker",["$http","imageManagerService",function(e,t){return{restrict:"E",template:a,scope:{name:"@",resizeHeight:"@",resizeWidth:"@",resizeCrop:"@",showRemove:"=",currentImage:"@",currentId:"@",defaultImage:"@",imageClass:"@"},link:function(n,r,i){function o(e,t){n.image=t,n.value=a?e.id:t}var a="undefined"!=typeof n.currentId||"false"===n.currentId;n.image=n.currentImage,n.value=n.currentImage||"",a&&(n.value=n.currentId),n.reset=function(){o({id:0},n.defaultImage)},n.remove=function(){n.image="none",n.value="none"},n.showImageManager=function(){t.show(function(e){n.updateImageFromModel(e)})},n.updateImageFromModel=function(t){var r=n.resizeWidth&&n.resizeHeight;if(!r)return void n.$apply(function(){o(t,t.url)});var i=n.resizeCrop?"true":"false",a="/images/thumb/"+t.id+"/"+n.resizeWidth+"/"+n.resizeHeight+"/"+i;e.get(a).then(function(e){o(t,e.data.url)})}}}}]),e.directive("dropZone",[function(){return{restrict:"E",template:s,scope:{uploadUrl:"@",eventSuccess:"=",eventError:"=",uploadedTo:"@"},link:function(e,t,n){new r(t[0].querySelector(".dropzone-container"),{url:e.uploadUrl,init:function(){var t=this;t.on("sending",function(t,n,r){var i=window.document.querySelector("meta[name=token]").getAttribute("content");r.append("_token",i);var o="undefined"==typeof e.uploadedTo?0:e.uploadedTo;r.append("uploaded_to",o)}),"undefined"!=typeof e.eventSuccess&&t.on("success",e.eventSuccess),t.on("success",function(e,n){$(e.previewElement).fadeOut(400,function(){t.removeFile(e)})}),"undefined"!=typeof e.eventError&&t.on("error",e.eventError),t.on("error",function(e,t,n){function r(t){$(e.previewElement).find("[data-dz-errormessage]").text(t)}console.log(t),console.log(n),413===n.status&&r("The server does not allow uploads of this size. Please try a smaller file."),t.file&&r(t.file[0])})}})}}}]),e.directive("dropdown",[function(){return{restrict:"A",link:function(e,t,n){var r=t.find("ul");t.find("[dropdown-toggle]").on("click",function(){r.show().addClass("anim menuIn"),t.mouseleave(function(){r.hide(),r.removeClass("anim menuIn")})})}}}]),e.directive("tinymce",["$timeout",function(e){return{restrict:"A",scope:{tinymce:"=",mceModel:"=",mceChange:"="},link:function(t,n,r){function i(n){n.on("ExecCommand change NodeChange ObjectResized",function(r){var i=n.getContent();e(function(){t.mceModel=i}),t.mceChange(i)}),n.on("init",function(e){t.mceModel=n.getContent()}),t.$on("html-update",function(e,r){n.setContent(r),n.selection.select(n.getBody(),!0),n.selection.collapse(!1),t.mceModel=n.getContent()})}t.tinymce.extraSetups.push(i),tinymce.init(t.tinymce)}}}]),e.directive("markdownInput",["$timeout",function(e){return{restrict:"A",scope:{mdModel:"=",mdChange:"="},link:function(t,n,r){var o=n.val();t.mdModel=o,t.mdChange(i(o)),n.on("change input",function(r){o=n.val(),e(function(){t.mdModel=o,t.mdChange(i(o))})}),t.$on("markdown-update",function(e,r){n.val(r),t.mdModel=r,t.mdChange(i(r))})}}}]),e.directive("markdownEditor",["$timeout",function(e){return{restrict:"A",link:function(e,t,n){var r=t.find("textarea[markdown-input]"),i=t.find('button[data-action="insertImage"]'),o=0;r.blur(function(e){o=r[0].selectionStart}),r.keydown(function(e){if(73===e.which&&e.ctrlKey&&e.shiftKey){e.preventDefault();var t=r[0].selectionStart,n=r.val(),i="![](http://)";r.val(n.substring(0,t)+i+n.substring(t)),r.focus(),r[0].selectionStart=t+"![](".length,r[0].selectionEnd=t+"![](http://".length}}),i.click(function(e){window.ImageManager.showExternal(function(e){var t=o,n=r.val(),i="!["+e.name+"]("+e.url+")";r.val(n.substring(0,t)+i+n.substring(t)),r.change()})})}}}])}},{"./components/drop-zone.html":13,"./components/image-picker.html":14,"./components/toggle-switch.html":15,dropzone:9,marked:10}],18:[function(e,t,n){"use strict";var r=e("angular"),i=(e("angular-resource"),e("angular-animate"),e("angular-sanitize"),r.module("bookStack",["ngResource","ngAnimate","ngSanitize"])),o={listeners:{},emit:function(e,t){if("undefined"==typeof this.listeners[e])return this;for(var n=this.listeners[e],r=0;r=0}}),$(function(){var e=$(".notification"),t=e.filter(".pos"),n=e.filter(".neg"),r=e.filter(".warning");window.Events.listen("success",function(e){t.hide(),t.find("span").text(e),setTimeout(function(){t.show()},1)}),window.Events.listen("warning",function(e){r.find("span").text(e),r.show()}),window.Events.listen("error",function(e){n.find("span").text(e),n.show()}),e.click(function(){$(this).fadeOut(100)}),$(".chapter-toggle").click(function(e){e.preventDefault(),$(this).toggleClass("open"),$(this).closest(".chapter").find(".inset-list").slideToggle(180)}),$("#back-to-top").click(function(){$("#header").smoothScrollTo()});var i=!1,o=document.getElementById("back-to-top"),a=1200;window.addEventListener("scroll",function(){!i&&document.body.scrollTop>a?(o.style.display="block",i=!0,setTimeout(function(){o.style.opacity=.4},1)):i&&document.body.scrollTop';i+=''+t.name+'',i+="
    ",r.tinyMCE.activeEditor.execCommand("mceInsertContent",!1,i)})},paste_preprocess:function(e,t){var n=t.content;-1!==n.indexOf('';n+=''+t.name+'',n+="",e.execCommand("mceInsertContent",!1,n)})}}),e.on("paste",function(t){if(t.clipboardData){var n=t.clipboardData.items;if(n)for(var r=0;r');var c="image-"+Date.now()+"."+a;o.append("file",i,c),o.append("_token",document.querySelector('meta[name="token"]').getAttribute("content")),s.open("POST","/images/gallery/upload"),s.onload=function(){if(200===s.status||201===s.status){var t=JSON.parse(s.responseText);e.dom.setAttrib(l,"src",t.url)}else console.log("An error occured uploading the image"),console.log(s.responseText),e.dom.remove(l)},s.send(o)}}})}}},{}],20:[function(e,t,n){"use strict";var r=e("zeroclipboard");r.config({swfPath:"/ZeroClipboard.swf"}),window.setupPageShow=t.exports=function(e){function t(e){var t=$(".page-content #"+e).first();0!==t.length?(t.smoothScrollTo(),t.css("background-color","rgba(244, 249, 54, 0.25)")):$(".page-content").find(':contains("'+e+'")').smoothScrollTo()}function n(){f.width(m+48+15),f.addClass("fixed"),p=!0}function i(){f.css("width","auto"),f.removeClass("fixed"),p=!1}function o(e){var t=c.scrollTop()>h;!t||p&&!e?t||!p&&!e||i():n()}var a=$("#pointer").detach(),s=a.children("div.pointer").first(),u=!1;if(a.on("click","input",function(e){$(this).select(),e.stopPropagation()}),new r(a.find("button").first()[0]),$(document.body).find("*").on("click focus",function(e){u||a.detach()}),$('.page-content [id^="bkmrk"]').on("mouseup keyup",function(t){t.stopPropagation();var n=window.getSelection();if(0!==n.toString().length){var r=$(this),i=window.location.protocol+"//"+window.location.host+"/link/"+e+"#"+r.attr("id");a.find("input").val(i),a.find("button").first().attr("data-clipboard-text",i),r.before(a),a.show();var o=t.pageX-r.offset().left-s.width()/2;0>o&&(o=0);var l=o/r.width()*100;s.css("left",l+"%"),u=!0,setTimeout(function(){u=!1},100)}}),window.location.hash){var l=window.location.hash.replace(/\%20/g," ").substr(1);t(l)}var c=$(window),f=$(".book-tree"),d=$(document).height()>c.height()&&f.height()<$(".page-content").height(),h=$("#header").height()+$(".toolbar").height(),p=c.scrollTop()>h,m=f.width();d&&c.width()>1e3&&(c.scroll(function(){o(!1)}),o(!0))}},{zeroclipboard:12}],21:[function(e,t,n){"use strict";t.exports=function(e,t){e.factory("imageManagerService",function(){return{show:!1,showExternal:!1}})}},{}]},{},[18]); \ No newline at end of file +this},Ge.prototype.getData=function(){if(!Qe[this.id])throw new Error("Attempted to get pending clipboard data from a destroyed ZeroClipboard client instance");return Ge.getData.apply(this,_(arguments))},"function"==typeof define&&define.amd?define(function(){return Ge}):"object"==typeof t&&t&&"object"==typeof t.exports&&t.exports?t.exports=Ge:e.ZeroClipboard=Ge}(function(){return this||window}())},{}],13:[function(e,t,n){t.exports='
    \n
    Drop files or click here to upload
    \n
    '},{}],14:[function(e,t,n){t.exports='\n
    \n
    \n Image Preview\n Image Preview\n
    \n \n
    \n\n \n |\n \n\n \n
    '},{}],15:[function(e,t,n){t.exports='
    \n \n
    \n
    '},{}],16:[function(e,t,n){"use strict";var r=e("moment");t.exports=function(t,n){t.controller("ImageManagerController",["$scope","$attrs","$http","$timeout","imageManagerService",function(e,t,r,i,o){function a(){e.searching=!1,e.searchTerm="",e.images=m,e.hasMore=g}function s(t){p&&p(t),e.showing=!1}function u(t){p=t,e.showing=!0,h||(l(),h=!0)}function l(){var t=v+c+"?",n={};e.uploadedTo&&(n.page_id=e.uploadedTo),e.searching&&(n.term=e.searchTerm);var i=Object.keys(n).map(function(e){return e+"="+encodeURIComponent(n[e])}).join("&");t+=i,r.get(t).then(function(t){e.images=e.images.concat(t.data.images),e.hasMore=t.data.hasMore,c++})}e.images=[],e.imageType=t.imageType,e.selectedImage=!1,e.dependantPages=!1,e.showing=!1,e.hasMore=!1,e.imageUpdateSuccess=!1,e.imageDeleteSuccess=!1,e.uploadedTo=t.uploadedTo,e.view="all",e.searching=!1,e.searchTerm="";var c=0,f=0,d=0,h=!1,p=!1,m=[],g=!1;e.getUploadUrl=function(){return"/images/"+e.imageType+"/upload"},e.cancelSearch=a,e.uploadSuccess=function(t,r){e.$apply(function(){e.images.unshift(r)}),n.emit("success","Image uploaded")},e.imageSelect=function(t){var n=300,r=Date.now(),i=r-f;n>i&&t.id===d?s(t):(e.selectedImage=t,e.dependantPages=!1),f=r,d=t.id},e.selectButtonClick=function(){s(e.selectedImage)},o.show=u,o.showExternal=function(t){e.$apply(function(){u(t)})},window.ImageManager=o,e.hide=function(){e.showing=!1};var v="/images/"+e.imageType+"/all/";e.fetchData=l,e.searchImages=function(){return""===e.searchTerm?void a():(e.searching||(m=e.images,g=e.hasMore),e.searching=!0,e.images=[],e.hasMore=!1,c=0,v="/images/"+e.imageType+"/search/",void l())},e.setView=function(t){a(),e.images=[],e.hasMore=!1,c=0,e.view=t,v="/images/"+e.imageType+"/"+t+"/",l()},e.saveImageDetails=function(t){t.preventDefault();var i="/images/update/"+e.selectedImage.id;r.put(i,this.selectedImage).then(function(e){n.emit("success","Image details updated")},function(e){if(422===e.status){var t=e.data,r="";Object.keys(t).forEach(function(e){r+=t[e].join("\n")}),n.emit("error",r)}else 403===e.status&&n.emit("error",e.data.error)})},e.deleteImage=function(t){t.preventDefault();var i=e.dependantPages!==!1,o="/images/"+e.selectedImage.id;i&&(o+="?force=true"),r["delete"](o).then(function(t){e.images.splice(e.images.indexOf(e.selectedImage),1),e.selectedImage=!1,n.emit("success","Image successfully deleted")},function(t){400===t.status?e.dependantPages=t.data:403===t.status&&n.emit("error",t.data.error)})},e.getDate=function(e){return new Date(e)}}]),t.controller("BookShowController",["$scope","$http","$attrs","$sce",function(e,t,n,r){e.searching=!1,e.searchTerm="",e.searchResults="",e.searchBook=function(i){i.preventDefault();var o=e.searchTerm;if(0!=o.length){e.searching=!0,e.searchResults="";var a="/search/book/"+n.bookId;a+="?term="+encodeURIComponent(o),t.get(a).then(function(t){e.searchResults=r.trustAsHtml(t.data)})}},e.checkSearchForm=function(){e.searchTerm.length<1&&(e.searching=!1)},e.clearSearch=function(){e.searching=!1,e.searchTerm=""}}]),t.controller("PageEditController",["$scope","$http","$attrs","$interval","$timeout","$sce",function(t,i,o,a,s,u){function l(){g.title=$("#name").val(),g.html=t.editContent,m=a(function(){var e=$("#name").val(),n=t.editContent;(e!==g.title||n!==g.html)&&(g.html=n,g.title=e,c())},1e3*h)}function c(){var e={name:$("#name").val(),html:p?u.getTrustedHtml(t.displayContent):t.editContent};p&&(e.markdown=t.editContent),i.put("/ajax/page/"+f+"/save-draft",e).then(function(e){var n=r.utc(r.unix(e.data.timestamp)).toDate();t.draftText=e.data.message+r(n).format("HH:mm"),t.isNewPageDraft||(t.isUpdateDraft=!0)})}t.editorOptions=e("./pages/page-form"),t.editContent="",t.draftText="";var f=Number(o.pageId),d=0!==f,h=30,p="markdown"===o.editorType;t.isUpdateDraft=1===Number(o.pageUpdateDraft),t.isNewPageDraft=1===Number(o.pageNewDraft),t.isUpdateDraft||t.isNewPageDraft?t.draftText="Editing Draft":t.draftText="Editing Page";var m=!1,g={title:!1,html:!1};d&&setTimeout(function(){l()},1e3),p&&(t.displayContent="",t.editorChange=function(e){t.displayContent=u.trustAsHtml(e)}),p||(t.editorChange=function(){}),t.forceDraftSave=function(){c()},t.discardDraft=function(){i.get("/ajax/page/"+f).then(function(e){m&&a.cancel(m),t.draftText="Editing Page",t.isUpdateDraft=!1,t.$broadcast("html-update",e.data.html),t.$broadcast("markdown-update",e.data.markdown||e.data.html),$("#name").val(e.data.name),s(function(){l()},1e3),n.emit("success","Draft discarded, The editor has been updated with the current page content")})}}])}},{"./pages/page-form":19,moment:11}],17:[function(e,t,n){"use strict";var r=e("dropzone"),i=e("marked"),o=e("./components/toggle-switch.html"),a=e("./components/image-picker.html"),s=e("./components/drop-zone.html");t.exports=function(e,t){e.directive("toggleSwitch",function(){return{restrict:"E",template:o,scope:!0,link:function(e,t,n){e.name=n.name,e.value=n.value,e.isActive=1==e.value&&"false"!=e.value,e.value=1==e.value&&"false"!=e.value?"true":"false",e["switch"]=function(){e.isActive=!e.isActive,e.value=e.isActive?"true":"false"}}}}),e.directive("imagePicker",["$http","imageManagerService",function(e,t){return{restrict:"E",template:a,scope:{name:"@",resizeHeight:"@",resizeWidth:"@",resizeCrop:"@",showRemove:"=",currentImage:"@",currentId:"@",defaultImage:"@",imageClass:"@"},link:function(n,r,i){function o(e,t){n.image=t,n.value=a?e.id:t}var a="undefined"!=typeof n.currentId||"false"===n.currentId;n.image=n.currentImage,n.value=n.currentImage||"",a&&(n.value=n.currentId),n.reset=function(){o({id:0},n.defaultImage)},n.remove=function(){n.image="none",n.value="none"},n.showImageManager=function(){t.show(function(e){n.updateImageFromModel(e)})},n.updateImageFromModel=function(t){var r=n.resizeWidth&&n.resizeHeight;if(!r)return void n.$apply(function(){o(t,t.url)});var i=n.resizeCrop?"true":"false",a="/images/thumb/"+t.id+"/"+n.resizeWidth+"/"+n.resizeHeight+"/"+i;e.get(a).then(function(e){o(t,e.data.url)})}}}}]),e.directive("dropZone",[function(){return{restrict:"E",template:s,scope:{uploadUrl:"@",eventSuccess:"=",eventError:"=",uploadedTo:"@"},link:function(e,t,n){new r(t[0].querySelector(".dropzone-container"),{url:e.uploadUrl,init:function(){var t=this;t.on("sending",function(t,n,r){var i=window.document.querySelector("meta[name=token]").getAttribute("content");r.append("_token",i);var o="undefined"==typeof e.uploadedTo?0:e.uploadedTo;r.append("uploaded_to",o)}),"undefined"!=typeof e.eventSuccess&&t.on("success",e.eventSuccess),t.on("success",function(e,n){$(e.previewElement).fadeOut(400,function(){t.removeFile(e)})}),"undefined"!=typeof e.eventError&&t.on("error",e.eventError),t.on("error",function(e,t,n){function r(t){$(e.previewElement).find("[data-dz-errormessage]").text(t)}console.log(t),console.log(n),413===n.status&&r("The server does not allow uploads of this size. Please try a smaller file."),t.file&&r(t.file[0])})}})}}}]),e.directive("dropdown",[function(){return{restrict:"A",link:function(e,t,n){var r=t.find("ul");t.find("[dropdown-toggle]").on("click",function(){r.show().addClass("anim menuIn"),t.mouseleave(function(){r.hide(),r.removeClass("anim menuIn")})})}}}]),e.directive("tinymce",["$timeout",function(e){return{restrict:"A",scope:{tinymce:"=",mceModel:"=",mceChange:"="},link:function(t,n,r){function i(n){n.on("ExecCommand change NodeChange ObjectResized",function(r){var i=n.getContent();e(function(){t.mceModel=i}),t.mceChange(i)}),n.on("init",function(e){t.mceModel=n.getContent()}),t.$on("html-update",function(e,r){n.setContent(r),n.selection.select(n.getBody(),!0),n.selection.collapse(!1),t.mceModel=n.getContent()})}t.tinymce.extraSetups.push(i),tinymce.init(t.tinymce)}}}]),e.directive("markdownInput",["$timeout",function(e){return{restrict:"A",scope:{mdModel:"=",mdChange:"="},link:function(t,n,r){var o=n.val();t.mdModel=o,t.mdChange(i(o)),n.on("change input",function(r){o=n.val(),e(function(){t.mdModel=o,t.mdChange(i(o))})}),t.$on("markdown-update",function(e,r){n.val(r),t.mdModel=r,t.mdChange(i(r))})}}}]),e.directive("markdownEditor",["$timeout",function(e){return{restrict:"A",link:function(e,t,n){var r=t.find("textarea[markdown-input]"),i=t.find('button[data-action="insertImage"]'),o=0;r.blur(function(e){o=r[0].selectionStart}),r.keydown(function(e){if(73===e.which&&e.ctrlKey&&e.shiftKey){e.preventDefault();var t=r[0].selectionStart,n=r.val(),i="![](http://)";r.val(n.substring(0,t)+i+n.substring(t)),r.focus(),r[0].selectionStart=t+"![](".length,r[0].selectionEnd=t+"![](http://".length}}),i.click(function(e){window.ImageManager.showExternal(function(e){var t=o,n=r.val(),i="!["+e.name+"]("+e.url+")";r.val(n.substring(0,t)+i+n.substring(t)),r.change()})})}}}])}},{"./components/drop-zone.html":13,"./components/image-picker.html":14,"./components/toggle-switch.html":15,dropzone:9,marked:10}],18:[function(e,t,n){"use strict";var r=e("angular"),i=(e("angular-resource"),e("angular-animate"),e("angular-sanitize"),r.module("bookStack",["ngResource","ngAnimate","ngSanitize"])),o={listeners:{},emit:function(e,t){if("undefined"==typeof this.listeners[e])return this;for(var n=this.listeners[e],r=0;r=0}}),$(function(){var e=$(".notification"),t=e.filter(".pos"),n=e.filter(".neg"),r=e.filter(".warning");window.Events.listen("success",function(e){t.hide(),t.find("span").text(e),setTimeout(function(){t.show()},1)}),window.Events.listen("warning",function(e){r.find("span").text(e),r.show()}),window.Events.listen("error",function(e){n.find("span").text(e),n.show()}),e.click(function(){$(this).fadeOut(100)}),$(".chapter-toggle").click(function(e){e.preventDefault(),$(this).toggleClass("open"),$(this).closest(".chapter").find(".inset-list").slideToggle(180)}),$("#back-to-top").click(function(){$("#header").smoothScrollTo()});var i=!1,o=document.getElementById("back-to-top"),a=1200;window.addEventListener("scroll",function(){!i&&document.body.scrollTop>a?(o.style.display="block",i=!0,setTimeout(function(){o.style.opacity=.4},1)):i&&document.body.scrollTop';i+=''+t.name+'',i+="",r.tinyMCE.activeEditor.execCommand("mceInsertContent",!1,i)})},paste_preprocess:function(e,t){var n=t.content;-1!==n.indexOf('';n+=''+t.name+'',n+="",e.execCommand("mceInsertContent",!1,n)})}}),e.on("paste",function(t){if(t.clipboardData){var n=t.clipboardData.items;if(n)for(var r=0;r');var c="image-"+Date.now()+"."+a;o.append("file",i,c),o.append("_token",document.querySelector('meta[name="token"]').getAttribute("content")),s.open("POST","/images/gallery/upload"),s.onload=function(){if(200===s.status||201===s.status){var t=JSON.parse(s.responseText);e.dom.setAttrib(l,"src",t.url)}else console.log("An error occured uploading the image"),console.log(s.responseText),e.dom.remove(l)},s.send(o)}}})}}},{}],20:[function(e,t,n){"use strict";var r=e("zeroclipboard");r.config({swfPath:"/ZeroClipboard.swf"}),window.setupPageShow=t.exports=function(e){function t(e){var t=$(".page-content #"+e).first();0!==t.length?(t.smoothScrollTo(),t.css("background-color","rgba(244, 249, 54, 0.25)")):$(".page-content").find(':contains("'+e+'")').smoothScrollTo()}function n(){f.width(m+48+15),f.addClass("fixed"),p=!0}function i(){f.css("width","auto"),f.removeClass("fixed"),p=!1}function o(e){var t=c.scrollTop()>h;!t||p&&!e?t||!p&&!e||i():n()}var a=$("#pointer").detach(),s=a.children("div.pointer").first(),u=!1;if(a.on("click","input",function(e){$(this).select(),e.stopPropagation()}),new r(a.find("button").first()[0]),$(document.body).find("*").on("click focus",function(e){u||a.detach()}),$('.page-content [id^="bkmrk"]').on("mouseup keyup",function(t){t.stopPropagation();var n=window.getSelection();if(0!==n.toString().length){var r=$(this),i=window.location.protocol+"//"+window.location.host+"/link/"+e+"#"+r.attr("id");a.find("input").val(i),a.find("button").first().attr("data-clipboard-text",i),r.before(a),a.show();var o=t.pageX-r.offset().left-s.width()/2;0>o&&(o=0);var l=o/r.width()*100;s.css("left",l+"%"),u=!0,setTimeout(function(){u=!1},100)}}),window.location.hash){var l=window.location.hash.replace(/\%20/g," ").substr(1);t(l)}var c=$(window),f=$(".book-tree"),d=$(document).height()>c.height()&&f.height()<$(".page-content").height(),h=$("#header").height()+$(".toolbar").height(),p=c.scrollTop()>h,m=f.width();d&&c.width()>1e3&&(c.scroll(function(){o(!1)}),o(!0))}},{zeroclipboard:12}],21:[function(e,t,n){"use strict";t.exports=function(e,t){e.factory("imageManagerService",function(){return{show:!1,showExternal:!1}})}},{}]},{},[18]); \ No newline at end of file