text: !function(e){function n(n){for(var a,o,l=n[0],s=n[1],u=n[2],d=0,f=[];d<l.length;d++)o=l[d],Object.prototype.hasOwnProperty.call(r,o)&&r[o]&&f.push(r[o][0]),r[o]=0;for(a in s)Object.prototype.hasOwnProperty.call(s,a)&&(e[a]=s[a]);for(c&&c(n);f.length;)f.shift()();return i.push.apply(i,u||[]),t()}function t(){for(var e,n=0;n<i.length;n++){for(var t=i[n],a=!0,l=1;l<t.length;l++){var s=t[l];0!==r[s]&&(a=!1)}a&&(i.splice(n--,1),e=o(o.s=t[0]))}return e}var a={},r={6:0},i=[];function o(n){if(a[n])return a[n].exports;var t=a[n]={i:n,l:!1,exports:{}};return e[n].call(t.exports,t,t.exports,o),t.l=!0,t.exports}o.m=e,o.c=a,o.d=function(e,n,t){o.o(e,n)||Object.defineProperty(e,n,{enumerable:!0,get:t})},o.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},o.t=function(e,n){if(1&n&&(e=o(e)),8&n)return e;if(4&n&&"object"==typeof e&&e&&e.__esModule)return e;var t=Object.create(null);if(o.r(t),Object.defineProperty(t,"default",{enumerable:!0,value:e}),2&n&&"string"!=typeof e)for(var a in e)o.d(t,a,function(n){return e[n]}.bind(null,a));return t},o.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return o.d(n,"a",n),n},o.o=function(e,n){return Object.prototype.hasOwnProperty.call(e,n)},o.p="";var l=window.webpackJsonp=window.webpackJsonp||[],s=l.push.bind(l);l.push=n,l=l.slice();for(var u=0;u<l.length;u++)n(l[u]);var c=s;i.push([48,0]),t()}({2:function(e,n,t){"use strict";var a=t(0),r=t.n(a),i=t(1),o=t.n(i),l=t(3),s=t.n(l),u={baseUrl:function(){var e=r()("head").attr("data-rooturl");return e||(e=""),e},stringify:function(e){if(!Array.prototype.toJSON)return JSON.stringify(e);var n={a:Array.prototype.toJSON,o:Object.prototype.toJSON,h:Hash.prototype.toJSON,s:String.prototype.toJSON};try{return delete Array.prototype.toJSON,delete Object.prototype.toJSON,delete Hash.prototype.toJSON,delete String.prototype.toJSON,JSON.stringify(e)}finally{n.a&&(Array.prototype.toJSON=n.a),n.o&&(Object.prototype.toJSON=n.o),n.h&&(Hash.prototype.toJSON=n.h),n.s&&(String.prototype.toJSON=n.s)}},goTo:function(e){o.a.getWindow().location.replace(u.baseUrl()+e)},get:function(e,n,t){var a={url:u.baseUrl()+e,type:"GET",cache:!1,dataType:"json",success:n};t instanceof Object&&r.a.extend(a,t),r.a.ajax(a)},post:function(e,n,t,a){var i,l={},s=o.a.getWindow();"crumb"in a?i=a.crumb:"crumb"in s&&(i=s.crumb),i&&(l[i.fieldName]=i.value);var c=n;c instanceof Object&&(i&&((c=r.a.extend({},c))[i.fieldName]=i.value),c=u.stringify(c));var d={url:u.baseUrl()+e,type:"POST",cache:!1,dataType:"json",data:c,contentType:"application/json",success:t,headers:l};a instanceof Object&&r.a.extend(d,a),r.a.ajax(d)},initHandlebars:function(){return s.a},loadTranslations:function(e,n,t){u.get("/i18n/resourceBundle?baseName="+e,(function(e){if("ok"!==e.status)throw t&&t(e.message),"Unable to load localization data: "+e.message;var a=e.data;"undefined"!=typeof Proxy&&(a=new Proxy(a,{get:function(e,n){return n in e?e[n]:n}})),n(a)}))},testConnectivity:function(e,n){!function t(){u.get("/updateCenter/connectionStatus?siteId="+e,(function(e){"ok"!==e.status&&n(!1,!0,e.message);var a=["PRECHECK","CHECKING","UNCHECKED"];a.indexOf(e.data.updatesite)>=0||a.indexOf(e.data.internet)>=0?setTimeout(t,100):"ok"!==e.status||"OK"!==e.data.updatesite||"OK"!==e.data.internet&&"SKIPPED"!==e.data.internet?n(!1,!1):n(!0)}),{error:function(e,t,a){403===e.status?u.goTo("/login"):n.call({isError:!0,errorMessage:a})}})}()},getWindow:function(e){e=r()(e);var n=o.a.getWindow();return r()(top.document).find("iframe").each((function(){var t=this.contentWindow;r()(this).contents().find("form").each((function(){e[0]===this&&(n=t)}))})),n},buildFormPost:function(e){e=r()(e);var n=u.getWindow(e),t=e[0];return n.buildFormTree(t)?e.serialize()+"&"+r.a.param({"core:apply":"",Submit:"Save",json:e.find("input[name=json]").val()}):""},getFormCrumb:function(e){return e=r()(e),u.getWindow(e).crumb},staplerPost:function(e,n,t,a){n=r()(n);var i=u.buildFormPost(n),o=u.getFormCrumb(n);u.post(e,i,t,r.a.extend({processData:!1,contentType:"application/x-www-form-urlencoded",crumb:o},a))}};n.a=u},36:function(e,n,t){var a=t(3);e.exports=(a.default||a).template({1:function(e,n,t,a){var r,i=this.lambda,o=this.escapeExpression;return'    <tr data-plugin-id="'+o(i(null!=e?e.name:e,e))+'" data-plugin-version="'+o(i(null!=e?e.version:e,e))+'">\n'+(null!=(r=n.if.call(e,(r=a&&a.root)&&r.admin,{name:"if",hash:{},fn:this.program(2,a,0),inverse:this.noop,data:a}))?r:"")+'        <td class="pane">\n            <div>\n                <a href="'+o(i(null!=e?e.wiki:e,e))+'" target="_blank" rel="noopener noreferrer">\n                    '+o(i(null!=e?e.displayName:e,e))+"\n                </a>\n            </div>\n"+(null!=(r=n.if.call(e,null!=e?e.categories:e,{name:"if",hash:{},fn:this.program(4,a,0),inverse:this.noop,data:a}))?r:"")+(null!=(r=n.if.call(e,null!=e?e.excerpt:e,{name:"if",hash:{},fn:this.program(7,a,0),inverse:this.noop,data:a}))?r:"")+(null!=(r=n.if.call(e,null!=e?e.newerCoreRequired:e,{name:"if",hash:{},fn:this.program(9,a,0),inverse:this.noop,data:a}))?r:"")+(null!=(r=n.if.call(e,null!=e?e.dependenciesNewerJava:e,{name:"if",hash:{},fn:this.program(11,a,0),inverse:this.noop,data:a}))?r:"")+(null!=(r=n.if.call(e,null!=e?e.unresolvedSecurityWarnings:e,{name:"if",hash:{},fn:this.program(13,a,0),inverse:this.noop,data:a}))?r:"")+(null!=(r=n.if.call(e,null!=e?e.deprecated:e,{name:"if",hash:{},fn:this.program(16,a,0),inverse:this.noop,data:a}))?r:"")+(null!=(r=n.if.call(e,null!=e?e.adoptMe:e,{name:"if",hash:{},fn:this.program(18,a,0),inverse:this.noop,data:a}))?r:"")+(null!=(r=n.if.call(e,null!=e?e.newerVersionAvailableNotOffered:e,{name:"if",hash:{},fn:this.program(20,a,0),inverse:this.noop,data:a}))?r:"")+'        </td>\n        <td class="pane">\n            '+o(i(null!=e?e.version:e,e))+'\n        </td>\n        <td class="pane">\n'+(null!=(r=n.if.call(e,null!=e?e.releaseTimestamp:e,{name:"if",hash:{},fn:this.program(22,a,0),inverse:this.noop,data:a}))?r:"")+"        </td>\n    </tr>\n"},2:function(e,n,t,a){var r=this.lambda,i=this.escapeExpression;return'            <td class="pane">\n                <input type="checkbox" name="plugin.'+i(r(null!=e?e.name:e,e))+"."+i(r(null!=e?e.sourceId:e,e))+'">\n            </td>\n'},4:function(e,n,t,a){var r;return'                <div class="plugin-manager__categories">\n'+(null!=(r=n.each.call(e,null!=e?e.categories:e,{name:"each",hash:{},fn:this.program(5,a,0),inverse:this.noop,data:a}))?r:"")+"                </div>\n"},5:function(e,n,t,a){var r=this.lambda,i=this.escapeExpression;return'                        <a href="?filter='+i(r(e,e))+'" class="plugin-manager__category-label">\n                        '+i(r(e,e))+"\n                        </a>\n"},7:function(e,n,t,a){var r;return'                <div class="except">\n                    '+(null!=(r=this.lambda(null!=e?e.excerpt:e,e))?r:"")+"\n                </div>\n"},9:function(e,n,t,a){var r;return'                <div class="alert alert-danger">\n                    '+(null!=(r=this.lambda(null!=e?e.newerCoreRequired:e,e))?r:"")+"\n                </div>\n"},11:function(e,n,t,a){var r;return'                <div class="alert alert-danger">\n                    '+(null!=(r=this.lambda(null!=e?e.dependenciesNewerJava:e,e))?r:"")+"\n                </div>\n"},13:function(e,n,t,a){var r;return'                <div class="alert alert-danger">\n                    '+this.escapeExpression(this.lambda(null!=(r=null!=e?e.unresolvedSecurityWarnings:e)?r.text:r,e))+"\n                    <ul>\n"+(null!=(r=n.each.call(e,null!=(r=null!=e?e.unresolvedSecurityWarnings:e)?r.warnings:r,{name:"each",hash:{},fn:this.program(14,a,0),inverse:this.noop,data:a}))?r:"")+"                    </ul>\n                </div>\n"},14:function(e,n,t,a){var r=this.lambda,i=this.escapeExpression;return'                            <li>\n                                <a href="'+i(r(null!=e?e.url:e,e))+'" target="_blank" rel="noopener noreferrer">\n                                    '+i(r(null!=e?e.message:e,e))+"\n                                </a>\n                            </li>\n"},16:function(e,n,t,a){var r;return'                <div class="alert alert-warning">\n                    '+(null!=(r=this.lambda(null!=e?e.deprecated:e,e))?r:"")+"\n                </div>\n"},18:function(e,n,t,a){var r;return'                <div class="alert alert-warning">\n                    '+(null!=(r=this.lambda(null!=e?e.adoptMe:e,e))?r:"")+"\n                </div>\n"},20:function(e,n,t,a){var r;return'                <div class="alert alert-info">\n                    '+(null!=(r=this.lambda(null!=e?e.newerVersionAvailableNotOffered:e,e))?r:"")+"\n                </div>\n"},22:function(e,n,t,a){var r,i=this.lambda,o=this.escapeExpression;return'                <time datetime="'+o(i(null!=(r=null!=e?e.releaseTimestamp:e)?r.iso8601:r,e))+'">\n                    '+o(i(null!=(r=null!=e?e.releaseTimestamp:e)?r.displayValue:r,e))+"\n                </time>\n"},compiler:[6,">= 2.0.0-beta.1"],main:function(e,n,t,a){var r;return null!=(r=n.each.call(e,null!=e?e.plugins:e,{name:"each",hash:{},fn:this.program(1,a,0),inverse:this.noop,data:a}))?r:""},useData:!0})},48:function(e,n,t){t(49),e.exports=t(60)},49:function(e,n,t){"use strict";t.r(n);var a=t(34),r=t.n(a),i=t(35),o=t.n(i),l=t(36),s=t.n(l),u=t(5);function c(e){u.a.availablePluginsSearch(e.toLowerCase().trim(),50,(function(e){var n=document.getElementById("plugins"),t=n.querySelector("tbody"),a=[],r="true"===n.dataset.hasadmin;!function(){if(r){var e=t.querySelectorAll("tr");e&&(a=[],e.forEach((function(e){var n=e.querySelector("input");if(!0===n.checked){var t=n.name.split(".")[1];a.push(t)}else e.remove()})))}else t.innerHTML=""}();var i=s()({plugins:e.filter((function(e){return-1===a.indexOf(e.name)})),admin:r});t.insertAdjacentHTML("beforeend",i),o()((function(){layoutUpdateCallback.call()}))}))}var d=r()((function(e){c(e.target.value)}),150);document.addEventListener("DOMContentLoaded",(function(){var e=document.getElementById("filter-box");e.addEventListener("input",d),c(e.value),setTimeout((function(){layoutUpdateCallback.call()}),350)}))},5:function(e,n,t){"use strict";var a,r=t(2),i={initialPluginList:function(e){r.a.get("/setupWizard/platformPluginList",(function(n){"ok"===n.status?e.call({isError:!1},n.data):e.call({isError:!0,data:n.data})}),{timeout:o,error:function(n,t,a){e.call({isError:!0,errorMessage:a})}})},init:function(e){i.initialPluginList((function(n){(a={}).names=[],a.recommendedPlugins=[],a.availablePlugins=n;for(var t=0;t<n.length;t++)for(var r=n[t],i=r.plugins,o=0;o<i.length;o++){var l=i[o],s=l.name;if(-1===a.names.indexOf(s))if(a.names.push(s),l.suggested)a.recommendedPlugins.push(s);else if("Languages"===r.category){s==="localization-"+(window.navigator.userLanguage||window.navigator.language).toLocaleLowerCase()&&a.recommendedPlugins.push(s)}}e()}))}},o=1e4;i.plugins=function(){return a.availablePlugins},i.pluginNames=function(){return a.names},i.recommendedPluginNames=function(){return a.recommendedPlugins.slice()},i.installPlugins=function(e,n){r.a.post("/pluginManager/installPlugins",{dynamicLoad:!0,plugins:e},(function(e){"ok"===e.status?n.call({isError:!1},e.data.correlationId):n.call({isError:!0,errorMessage:e.message})}),{timeout:o,error:function(e,t,a){n.call({isError:!0,errorMessage:a})}})},i.installStatus=function(e,n){var t="/updateCenter/installStatus";void 0!==n&&(t+="?correlationId="+n),r.a.get(t,(function(n){"ok"===n.status?e.call({isError:!1},n.data):e.call({isError:!0,errorMessage:n.message})}),{timeout:o,error:function(n,t,a){e.call({isError:!0,errorMessage:a})}})},i.availablePlugins=function(e){r.a.get("/pluginManager/plugins",(function(n){"ok"===n.status?e.call({isError:!1},n.data):e.call({isError:!0,errorMessage:n.message})}),{timeout:o,error:function(n,t,a){e.call({isError:!0,errorMessage:a})}})},i.availablePluginsSearch=function(e,n,t){r.a.get("/pluginManager/pluginsSearch?query="+e+"&limit="+n,(function(e){"ok"===e.status?t.call({isError:!1},e.data):t.call({isError:!0,errorMessage:e.message})}),{timeout:o,error:function(e,n,a){t.call({isError:!0,errorMessage:a})}})},i.incompleteInstallStatus=function(e,n){var t="/updateCenter/incompleteInstallStatus";void 0!==n&&(t+="?correlationId="+n),r.a.get(t,(function(n){"ok"===n.status?e.call({isError:!1},n.data):e.call({isError:!0,errorMessage:n.message})}),{timeout:o,error:function(n,t,a){e.call({isError:!0,errorMessage:a})}})},i.completeInstall=function(e){r.a.post("/setupWizard/completeInstall",{},(function(){e.call({isError:!1})}),{timeout:o,error:function(n,t,a){e.call({isError:!0,message:a})}})},i.getRestartStatus=function(e){r.a.get("/setupWizard/restartStatus",(function(n){e.call({isError:!1},n.data)}),{timeout:o,error:function(n,t,a){e.call({isError:!0,message:a})}})},i.installPluginsDone=function(e){r.a.post("/pluginManager/installPluginsDone",{},(function(){e()}),{timeout:o,error:function(n,t,a){e.call({isError:!0,message:a})}})},i.restartJenkins=function(e){r.a.post("/updateCenter/safeRestart",{},(function(){e.call({isError:!1})}),{timeout:o,error:function(n,t,a){e.call({isError:!0,message:a})}})},n.a=i},60:function(e,n,t){var a=t(8),r=t(61);"string"==typeof(r=r.__esModule?r.default:r)&&(r=[[e.i,r,""]]);var i={insert:"head",singleton:!1};a(r,i);e.exports=r.locals||{}},61:function(e,n,t){}});
  //# sourceMappingURL=plugin-manager-ui.js.map