"use strict";!function(e){var r={preferences:{}};function n(n,t,o,i,p){var c,u=n?"PUBURL":"PUBURLPATH",a=[];return c=r.getPreference(u)||"/",void 0!==t&&(c+="/"+t.replace(/\./g,"/")),void 0!==o&&(c+="/"+encodeURIComponent(o)),void 0!==i&&(c+="/"+encodeURIComponent(i)),void 0!==p&&(e.each(p,(function(e,r){a.push(e+"="+r)})),c+=a.length?"?"+a.join("&"):""),c}function t(n,t,o,i,p){var c=r.getPreference("SCRIPTSUFFIX")||"",u=r.getPreference("SCRIPTURLPATHS"),a=r.getPreference("SCRIPTURLSEPARATOR"),f="",d=[];return t=t||"",n&&(f=r.getPreference("URLHOST")),void 0===u[t]?f+=r.getPreference("SCRIPTURLPATH")+"/"+t+c:f+=u[t],void 0!==i&&i.match(/^(.*)(?:\.|\/)(.*?)$/)&&(o=RegExp.$1,i=RegExp.$2),void 0!==o&&("view"===t&&a&&(o=r.spaceOutWikiWord(o,a)),f+="/"+o),void 0!==i&&("view"===t&&a&&!/^(WebHome)$/.test(i)&&(i=r.spaceOutWikiWord(i,a)),f+="/"+i),void 0!==p&&(e.each(p,(function(e,r){d.push(e+"="+r)})),f+=d.length?"?"+d.join("&"):""),f}r.RE={upper:"A-ZÀ-ÖØ-ÞĀĂĄĆĈĊČĎĐĒĔĖĘĚĜĞĠĢĤĦĨĪĬĮİĲĴĶĹĻĽĿŁŃŅŇŊŌŎŐŒŔŖŘŚŜŞŠŢŤŦŨŪŬŮŰŲŴŶŸ-ŹŻŽƁ-ƂƄƆ-ƇƉ-ƋƎ-ƑƓ-ƔƖ-ƘƜ-ƝƟ-ƠƢƤƦ-ƧƩƬƮ-ƯƱ-ƳƵƷ-ƸƼǄǇǊǍǏǑǓǕǗǙǛǞǠǢǤǦǨǪǬǮǱǴǶ-ǸǺǼǾȀȂȄȆȈȊȌȎȐȒȔȖȘȚȜȞȠȢȤȦȨȪȬȮȰȲȺ-ȻȽ-ȾɁɃ-ɆɈɊɌɎͰͲͶΆΈ-ΊΌΎ-ΏΑ-ΡΣ-ΫϏϒ-ϔϘϚϜϞϠϢϤϦϨϪϬϮϴϷϹ-ϺϽ-ЯѠѢѤѦѨѪѬѮѰѲѴѶѸѺѼѾҀҊҌҎҐҒҔҖҘҚҜҞҠҢҤҦҨҪҬҮҰҲҴҶҸҺҼҾӀ-ӁӃӅӇӉӋӍӐӒӔӖӘӚӜӞӠӢӤӦӨӪӬӮӰӲӴӶӸӺӼӾԀԂԄԆԈԊԌԎԐԒԔԖԘԚԜԞԠԢԤԦԱ-ՖႠ-ჅჇჍḀḂḄḆḈḊḌḎḐḒḔḖḘḚḜḞḠḢḤḦḨḪḬḮḰḲḴḶḸḺḼḾṀṂṄṆṈṊṌṎṐṒṔṖṘṚṜṞṠṢṤṦṨṪṬṮṰṲṴṶṸṺṼṾẀẂẄẆẈẊẌẎẐẒẔẞẠẢẤẦẨẪẬẮẰẲẴẶẸẺẼẾỀỂỄỆỈỊỌỎỐỒỔỖỘỚỜỞỠỢỤỦỨỪỬỮỰỲỴỶỸỺỼỾἈ-ἏἘ-ἝἨ-ἯἸ-ἿὈ-ὍὙὛὝὟὨ-ὯᾸ-ΆῈ-ΉῘ-ΊῨ-ῬῸ-Ώℂℇℋ-ℍℐ-ℒℕℙ-ℝℤΩℨK-ℭℰ-ℳℾ-ℿⅅⅠ-ⅯↃⒶ-ⓏⰀ-ⰮⱠⱢ-ⱤⱧⱩⱫⱭ-ⱰⱲⱵⱾ-ⲀⲂⲄⲆⲈⲊⲌⲎⲐⲒⲔⲖⲘⲚⲜⲞⲠⲢⲤⲦⲨⲪⲬⲮⲰⲲⲴⲶⲸⲺⲼⲾⳀⳂⳄⳆⳈⳊⳌⳎⳐⳒⳔⳖⳘⳚⳜⳞⳠⳢⳫⳭⳲꙀꙂꙄꙆꙈꙊꙌꙎꙐꙒꙔꙖꙘꙚꙜꙞꙠꙢꙤꙦꙨꙪꙬꚀꚂꚄꚆꚈꚊꚌꚎꚐꚒꚔꚖꜢꜤꜦꜨꜪꜬꜮꜲꜴꜶꜸꜺꜼꜾꝀꝂꝄꝆꝈꝊꝌꝎꝐꝒꝔꝖꝘꝚꝜꝞꝠꝢꝤꝦꝨꝪꝬꝮꝹꝻꝽ-ꝾꞀꞂꞄꞆꞋꞍꞐꞒꞠꞢꞤꞦꞨꞪＡ-Ｚ",lower:"a-zªµºß-öø-ÿāăąćĉċčďđēĕėęěĝğġģĥħĩīĭįıĳĵķ-ĸĺļľŀłńņň-ŉŋōŏőœŕŗřśŝşšţťŧũūŭůűųŵŷźżž-ƀƃƅƈƌ-ƍƒƕƙ-ƛƞơƣƥƨƪ-ƫƭưƴƶƹ-ƺƽ-ƿǆǉǌǎǐǒǔǖǘǚǜ-ǝǟǡǣǥǧǩǫǭǯ-ǰǳǵǹǻǽǿȁȃȅȇȉȋȍȏȑȓȕȗșțȝȟȡȣȥȧȩȫȭȯȱȳ-ȹȼȿ-ɀɂɇɉɋɍɏ-ʓʕ-ʸˀ-ˁˠ-ˤͅͱͳͷͺ-ͽΐά-ώϐ-ϑϕ-ϗϙϛϝϟϡϣϥϧϩϫϭϯ-ϳϵϸϻ-ϼа-џѡѣѥѧѩѫѭѯѱѳѵѷѹѻѽѿҁҋҍҏґғҕҗҙқҝҟҡңҥҧҩҫҭүұҳҵҷҹһҽҿӂӄӆӈӊӌӎ-ӏӑӓӕӗәӛӝӟӡӣӥӧөӫӭӯӱӳӵӷӹӻӽӿԁԃԅԇԉԋԍԏԑԓԕԗԙԛԝԟԡԣԥԧա-ևᴀ-ᶿḁḃḅḇḉḋḍḏḑḓḕḗḙḛḝḟḡḣḥḧḩḫḭḯḱḳḵḷḹḻḽḿṁṃṅṇṉṋṍṏṑṓṕṗṙṛṝṟṡṣṥṧṩṫṭṯṱṳṵṷṹṻṽṿẁẃẅẇẉẋẍẏẑẓẕ-ẝẟạảấầẩẫậắằẳẵặẹẻẽếềểễệỉịọỏốồổỗộớờởỡợụủứừửữựỳỵỷỹỻỽỿ-ἇἐ-ἕἠ-ἧἰ-ἷὀ-ὅὐ-ὗὠ-ὧὰ-ώᾀ-ᾇᾐ-ᾗᾠ-ᾧᾰ-ᾴᾶ-ᾷιῂ-ῄῆ-ῇῐ-ΐῖ-ῗῠ-ῧῲ-ῴῶ-ῷⁱⁿₐ-ₜℊℎ-ℏℓℯℴℹℼ-ℽⅆ-ⅉⅎⅰ-ⅿↄⓐ-ⓩⰰ-ⱞⱡⱥ-ⱦⱨⱪⱬⱱⱳ-ⱴⱶ-ⱽⲁⲃⲅⲇⲉⲋⲍⲏⲑⲓⲕⲗⲙⲛⲝⲟⲡⲣⲥⲧⲩⲫⲭⲯⲱⲳⲵⲷⲹⲻⲽⲿⳁⳃⳅⳇⳉⳋⳍⳏⳑⳓⳕⳗⳙⳛⳝⳟⳡⳣ-ⳤⳬⳮⳳⴀ-ⴥⴧⴭꙁꙃꙅꙇꙉꙋꙍꙏꙑꙓꙕꙗꙙꙛꙝꙟꙡꙣꙥꙧꙩꙫꙭꚁꚃꚅꚇꚉꚋꚍꚏꚑꚓꚕꚗꜣꜥꜧꜩꜫꜭꜯ-ꜱꜳꜵꜷꜹꜻꜽꜿꝁꝃꝅꝇꝉꝋꝍꝏꝑꝓꝕꝗꝙꝛꝝꝟꝡꝣꝥꝧꝩꝫꝭꝯ-ꝸꝺꝼꝿꞁꞃꞅꞇꞌꞎꞑꞓꞡꞣꞥꞧꞩꟸ-ꟺﬀ-ﬆﬓ-ﬗａ-ｚ",digit:"0-9٠-٩۰-۹߀-߉०-९০-৯੦-੯૦-૯୦-୯௦-௯౦-౯೦-೯൦-൯๐-๙໐-໙༠-༩၀-၉႐-႙០-៩᠐-᠙᥆-᥏᧐-᧙᪀-᪉᪐-᪙᭐-᭙᮰-᮹᱀-᱉᱐-᱙꘠-꘩꣐-꣙꤀-꤉꧐-꧙꩐-꩙꯰-꯹０-９"},r.RE.alnum=r.RE.upper+r.RE.lower+r.RE.digit,r.RE.wikiword=new RegExp("^["+r.RE.upper+"]+["+r.RE.lower+r.RE.digit+"]+["+r.RE.upper+"]+["+r.RE.alnum+"]*$"),e.log=function(e){console.warn("deprecated call to $.log()")},e.fn.debug=function(){console.warn("deprecated call to $.fn.debug()")},r.debounce=function(e,n,t){return n=n||"default",t=t||1e3,function(...o){r.debounce.prototype[n]&&(window.clearTimeout(r.debounce.prototype[n]),delete r.debounce.prototype[n]),r.debounce.prototype[n]=window.setTimeout((function(){delete r.debounce.prototype[n],e(...o)}),t)}},r.getUniqueID=function(){var e,r=(new Date).getTime().toString(32);for(e=0;e<5;e++)r+=Math.floor(65535*Math.random()).toString(32);return r},r.normalizeWebTopicName=function(e,n){if(void 0!==n){var t=n.match(/^(.*)[.\/](.*?)$/);t&&(e=t[1],n=t[2])}return[e=e||r.getPreference("USERSWEB"),n=n||"WebHome"]},r.spaceOutWikiWord=function(e,n){return r._lowerUpper=r._lowerUpper||new RegExp("(["+r.RE.lower+"])(["+r.RE.upper+r.RE.digit+"]+)","g"),r._numberUpper=r._numberUpper||new RegExp("("+r.RE.digit+")("+r.RE.upper+"+)","g"),r._upperLower=r._upperLower||new RegExp("(["+r.RE.upper+"])(["+r.RE.upper+"])(?=["+r.RE.lower+"])","g"),n=n||" ",(e=e||"").replace(r._lowerUpper,"$1"+n+"$2").replace(r._numberUpper,"$1"+n+"$2").replace(r._upperLower,"$1"+n+"$2")},r.getPreference=function(n,t){var o;return void 0!==r.preferences[n]?r.preferences[n]:void 0!==(o=e('meta[name="foswiki.'+n+'"]').attr("content"))?(o=unescape(o),r.preferences[n]=o,o):t?(e.ajax({url:r.getScriptUrl("view",r.getPreference("SYSTEMWEB"),"JQueryAjaxHelper"),data:{skin:"text",section:"expand",expression:n,scope:r.getPreference("WEB")+"."+r.getPreference("TOPIC")},async:!1,dataType:"text",success:function(e,t,o){r.preferences[n]=e}}),r.preferences[n]):void 0},r.getPubUrl=function(e,r,t,o){return n(1,e,r,t,o)},r.getPubUrlPath=function(e,r,t,o){return n(0,e,r,t,o)},r.getScriptUrl=function(e,r,n,o){return t(1,e,r,n,o)},r.getScriptUrlPath=function(e,r,n,o){return t(0,e,r,n,o)},r.getMetaTag=function(r){return e("meta[name="+r+"]").attr("content")},r.getElementsByClassName=function(r,n,t){var o=t||"";return e(r).find(o+"."+n).get()},e((function(){e("body").removeClass("foswikiNoJs").addClass("foswikiJs"),e(".foswikiPreferences").livequery((function(){e.extend(!0,r.preferences,JSON.parse(e(this).html()))})),void 0!==r.preferences.NAMEFILTER&&(r.preferences.NAMEFILTER=new RegExp(r.preferences.NAMEFILTER,"g"))})),window.foswiki=r}(jQuery);
