(()=>{"use strict";(()=>{var e=function e(){throw function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),new Error("Don't construct ResolvablePromise objects directly: rely on ResolvablePromise.new() instead")};function t(e){if(e.fulfilled)throw new Error("Promise already fulfilled")}function n(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}e.new=function(){var e={},n=new Promise((function(t,n){e._resolve=t,e._reject=n}));return Object.assign(n,e,{fulfilled:!1,rejected:!1,rejection:void 0,resolution:void 0,resolved:!1}),n.resolve=function(e){return function(e,n){t(e),e.fulfilled=!0,e.resolved=!0,e.resolution=n,e._resolve(n)}(n,e)},n.reject=function(e){return function(e,n){t(e),e.fulfilled=!0,e.rejected=!0,e.rejection=n,e._reject(n)}(n,e)},"undefined"!=typeof jest&&n.catch((function(){})),n};var r=function(){function t(n){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),this._name=n,this._dependencies=void 0,this._factory=void 0,this._implementation={},this._useESM=!1,this._map=void 0,this._state={_define:e.new(),_fetch:e.new(),_implement:e.new()}}var r,o;return r=t,(o=[{key:"name",get:function(){return this._name},set:function(e){throw new Error("Name of module ".concat(this.name," is read-only"))}},{key:"dependencies",get:function(){return this._dependencies},set:function(e){if(this._dependencies)throw new Error("Dependencies of module ".concat(this.name," already set"));this._dependencies=e}},{key:"factory",get:function(){return this._factory},set:function(e){if(this._factory)throw new Error("Factory of module ".concat(this.name," already set"));this._factory=e}},{key:"implementation",get:function(){return this._implementation},set:function(e){this._implementation=e}},{key:"map",get:function(){return this._map},set:function(e){if(this._map)throw new Error("Local module map of module ".concat(this.name," already set"));this._map=e}},{key:"esModule",get:function(){return this._implementation.__esModule},set:function(e){Object.defineProperty(this._implementation,"__esModule",{configurable:!0,value:e,writable:!0})}},{key:"fetch",get:function(){return this._state._fetch}},{key:"fetched",get:function(){return this.fetch.resolved}},{key:"define",get:function(){return this._state._define}},{key:"defined",get:function(){return this.define.resolved}},{key:"implement",get:function(){return this._state._implement}},{key:"implemented",get:function(){return this.implement.resolved}},{key:"useESM",get:function(){return this._useESM},set:function(e){this._useESM=e}}])&&n(r.prototype,o),t}();function o(e){return(o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function i(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i=[],a=!0,l=!1;try{for(n=n.call(e);!(a=(r=n.next()).done)&&(i.push(r.value),!t||i.length!==t);a=!0);}catch(e){l=!0,o=e}finally{try{a||null==n.return||n.return()}finally{if(l)throw o}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return a(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?a(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function a(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function l(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function u(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}var s=function(){function e(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};l(this,e),this._modules={},this._maps={},this._paths={},this._config={maps:{},paths:{}},this._parse(t,"defaultURLParams",{}),this._parse(t,"explainResolutions",!1),this._parse(t,"showWarnings",!1),this._parse(t,"waitTimeout",7e3),this._parse(t,"basePath","/"),this._parse(t,"resolvePath","/o/js_resolve_modules"),this._parse(t,"combine",!1),this._parse(t,"nonce",""),this._parse(t,"url",""),this._parse(t,"urlMaxLength",2e3),this._parse(t,"logLevel","error"),this._parse(t,"moduleType","module")}var t,n;return t=e,(n=[{key:"explainResolutions",get:function(){return this._config.explainResolutions}},{key:"showWarnings",get:function(){return this._config.showWarnings}},{key:"waitTimeout",get:function(){return this._config.waitTimeout}},{key:"basePath",get:function(){return this._config.basePath}},{key:"resolvePath",get:function(){return this._config.resolvePath}},{key:"combine",get:function(){return this._config.combine}},{key:"url",get:function(){return this._config.url}},{key:"urlMaxLength",get:function(){return this._config.urlMaxLength}},{key:"logLevel",get:function(){return this._config.logLevel}},{key:"moduleType",get:function(){return this._config.moduleType}},{key:"defaultURLParams",get:function(){return this._config.defaultURLParams}},{key:"paths",get:function(){return this._paths}},{key:"nonce",get:function(){return this._config.nonce}},{key:"addModule",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(this._modules[e])throw new Error("Module is already registered: ".concat(e));var n=new r(e);return Object.entries(t).forEach((function(e){var t=i(e,2),r=t[0],o=t[1];n[r]=o})),this._modules[e]=n,n}},{key:"addMappings",value:function(e){Object.assign(this._maps,e)}},{key:"addPaths",value:function(e){Object.assign(this._paths,e)}},{key:"getModules",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:void 0;return void 0===t?Object.values(this._modules):t.map((function(t){return e.getModule(t)}))}},{key:"getModule",value:function(e){var t=this._modules[e];if(!t){var n=this._mapModule(e);t=this._modules[n]}return t}},{key:"getDependency",value:function(e,t){var n=this.getModule(e),r=this._modules[t];if(!r){var o=this._mapModule(t,n.map);r=this._modules[o]}return r}},{key:"updateResolvePath",value:function(e){var t="".concat(window.location.protocol,"//").concat(window.location.host);e.startsWith(t)&&(e=e.substr(t.length)),this._config.resolvePath=e}},{key:"_parse",value:function(e,t,n){this._config[t]=Object.prototype.hasOwnProperty.call(e,t)?e[t]:n}},{key:"_mapModule",value:function(e,t){return t&&(e=this._mapMatches(e,t)),Object.keys(this._maps).length&&(e=this._mapMatches(e,this._maps)),e}},{key:"_mapMatches",value:function(e,t){var n=t[e];return n?"object"===o(n)?n.value:n:((n=this._mapExactMatch(e,t))||(n=this._mapPartialMatch(e,t)),n||(n=this._mapWildcardMatch(e,t)),n||e)}},{key:"_mapExactMatch",value:function(e,t){for(var n in t)if(Object.prototype.hasOwnProperty.call(t,n)){var r=t[n];if(r.value&&r.exactMatch&&e===n)return r.value}}},{key:"_mapPartialMatch",value:function(e,t){for(var n in t)if(Object.prototype.hasOwnProperty.call(t,n)){var r=t[n];if(!r.exactMatch&&(r.value&&(r=r.value),e===n||0===e.indexOf(n+"/")))return r+e.substring(n.length)}}},{key:"_mapWildcardMatch",value:function(e,t){if("function"==typeof t["*"])return t["*"](e)}}])&&u(t.prototype,n),e}();function c(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function f(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?c(Object(n),!0).forEach((function(t){h(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):c(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function h(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function d(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}var p=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this._config=t,this._cachedResolutions={}}var t,n;return t=e,(n=[{key:"resolve",value:function(e){var t=this;if(void 0===e||!e.length)throw new Error("Argument 'modules' cannot be undefined or empty");var n=this._config;return new Promise((function(r,o){var i=t._cachedResolutions[e];if(i)r(i);else{var a="modules=".concat(encodeURIComponent(e)),l="".concat(n.resolvePath,"?").concat(a),u={redirect:"follow"};l.length>n.urlMaxLength&&(l=n.resolvePath,u=f(f({},u),{},{body:a,method:"POST"})),fetch(l,u).then((function(n){n.redirected?(t._config.updateResolvePath(n.url),t.resolve(e).then(r).catch(o)):n.text().then((function(n){var o=JSON.parse(n);t._cachedResolutions[e]=o,r(o)})).catch(o)})).catch(o)}}))}}])&&d(t.prototype,n),e}();function m(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}var g={off:0,error:1,warn:2,info:3,debug:4},v="liferay-amd-loader |",y=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this._config=t}var t,n;return t=e,(n=[{key:"error",value:function(){var e;if(this._applies("error")){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];(e=console).error.apply(e,[v].concat(n))}}},{key:"warn",value:function(){var e;if(this._applies("warn")){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];(e=console).warn.apply(e,[v].concat(n))}}},{key:"info",value:function(){var e;if(this._applies("info")){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];(e=console).info.apply(e,[v].concat(n))}}},{key:"debug",value:function(){var e;if(this._applies("debug")){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];(e=console).debug.apply(e,[v].concat(n))}}},{key:"resolution",value:function(){var e;if(this._config.explainResolutions){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];(e=console).log.apply(e,[v].concat(n))}}},{key:"_applies",value:function(e){var t=g[this._config.logLevel];return g[e]<=t}}])&&m(t.prototype,n),e}();function _(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function w(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?_(Object(n),!0).forEach((function(t){b(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):_(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function b(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function k(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}var M=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this._config=t}var t,n;return t=e,(n=[{key:"build",value:function(e){var t=this._config,n=[],r=e.filter((function(e){return!t.getModule(e).useESM}));n=n.concat(this._build(r));var o=e.filter((function(e){return t.getModule(e).useESM})),i=this._build(o).map((function(e){return w(w({},e),{},{useESM:!0})}));return n.concat(i)}},{key:"_build",value:function(e){var t=this,n=this._config,r=[],o=[],i=[],a=n.basePath;return a.length&&"/"!==a.charAt(a.length-1)&&(a+="/"),e.forEach((function(e){var l=n.getModule(e),u=t._getModulePath(l);n.combine?(r.push(u),o.push(l.name)):i.push({modules:[l.name],url:t._getURLWithParams(n.url+a+u)})})),r.length&&(i=i.concat(this._generateBufferURLs(o,r,{basePath:a,url:n.url,urlMaxLength:n.urlMaxLength})),r.length=0),i}},{key:"_generateBufferURLs",value:function(e,t,n){for(var r=n.basePath,o=[],i=n.urlMaxLength,a={modules:[e[0]],url:n.url+r+t[0]},l=1;l<t.length;l++){var u=e[l],s=t[l];a.url.length+r.length+s.length+1<i?(a.modules.push(u),a.url+="&"+r+s):(o.push(a),a={modules:[u],url:n.url+r+s})}return a.url=this._getURLWithParams(a.url),o.push(a),o}},{key:"_getModulePath",value:function(e){var t=this._config.paths,n=e.name;return Object.keys(t).forEach((function(e){n!==e&&0!==n.indexOf(e+"/")||(n=t[e]+n.substring(e.length))})),n.lastIndexOf(".js")!==n.length-3&&(n+=".js"),n}},{key:"_getURLWithParams",value:function(e){var t=this._config.defaultURLParams||{},n=Object.keys(t);if(!n.length)return e;var r=n.map((function(e){return e+"="+t[e]})).join("&");return e+(e.indexOf("?")>-1?"&":"?")+r}}])&&k(t.prototype,n),e}();function j(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}var O=function(){function e(t,n,r){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this._document=t,this._config=n,this._log=r,this._urlBuilder=new M(n),this._injectedScripts={}}var t,n;return t=e,(n=[{key:"loadModules",value:function(e){var t=this,n=this._urlBuilder;if(!e.length)return Promise.resolve();var r=n.build(e).map((function(e){return t._loadScript(e)}));return Promise.all(r)}},{key:"_loadScript",value:function(e){var t=this,n=this._config,r=n.getModules(e.modules),o=this._injectedScripts[e.url];return o||((o=this._document.createElement("script")).src=e.url,o.async=!1,n.nonce&&o.setAttribute("nonce",n.nonce),e.useESM&&(o.type=n.moduleType),o.onload=o.onreadystatechange=function(){t.readyState&&"complete"!==t.readyState&&"load"!==t.readyState||(o.onload=o.onreadystatechange=null,o.onerror=null,r.forEach((function(e){e.fetch.fulfilled?t._log.warn("Module '".concat(e.name,"' is being fetched from\n"),o.src,"but was already fetched from\n",e.fetch.resolved?e.fetch.resolution.src:e.fetch.rejection.script.src):e.fetch.resolve(o)})))},o.onerror=function(){o.onload=o.onreadystatechange=null,o.onerror=null;var t=Object.assign(new Error("Unable to load script from URL ".concat(e.url)),{modules:e.modules,script:o,url:e.url});r.forEach((function(e){return e.fetch.reject(t)}))},this._injectedScripts[e.url]=o,this._document.head.appendChild(o)),Promise.all(r.map((function(e){return e.fetch})))}}])&&j(t.prototype,n),e}();function P(e){return function(e){if(Array.isArray(e))return E(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return E(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?E(e,t):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function E(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function S(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function L(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}var R=function(){function e(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;S(this,e),this._config=new s(t||window.__CONFIG__),this._log=new y(this._config),this._dependencyResolver=new p(this._config),this._urlBuilder=new M(this._config),this._scriptLoader=new O(n||window.document,this._config,this._log),this._requireCallId=0}var t,n;return t=e,(n=[{key:"version",value:function(){return"5.4.2"}},{key:"define",value:function(){for(var e=this._config,t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];var o=n[0],i=e.getModule(o);if(i&&i.defined)this._log.warn("Module '".concat(o,"' is being redefined. Only the first"),"definition will be used");else{var a=n[1],l=n[2];if(2===n.length&&(l=a,a=["require","exports","module"]),"function"!=typeof l){var u=l;l=function(){return u}}if(!(i=e.getModule(o)))throw new Error("Trying to define a module that was not registered: ".concat(o,"\n")+"This usually means that someone is calling define() for a module that has not been previously required.");if(i.defined)throw new Error("Trying to define a module more than once: ".concat(o,"\n")+"This usually means that someone is calling define() more than once for the same module, which can lead to unexpected results.");this._log.resolution("Defining",i.name),i.factory=l,i.dependencies=a,i.define.resolve(n)}}},{key:"require",value:function(){for(var e,t,n,r,o,i,a=this,l=this._scriptLoader,u=this._config,s=this._requireCallId++,c=arguments.length,f=new Array(c),h=0;h<c;h++)f[h]=arguments[h];if(1===f.length)e=f[0],t=void 0,n=void 0;else if(2===f.length){var d=f[f.length-1];"function"==typeof d?(e=f[0],t=d,n=void 0):null==d?(e=f[0],t=void 0,n=void 0):(e=f,t=void 0,n=void 0)}else{var p=f[f.length-1],m=!1;if("function"!=typeof p&&null!=p||(m=!0),m){var g=f[f.length-2],v=!1;"function"!=typeof g&&null!=g||(v=!0),v?(e=f.slice(0,f.length-2),t=g,n=p):(e=f.slice(0,f.length-1),t=p,n=void 0)}else e=f,t=void 0,n=void 0}if("string"==typeof e)e=[e];else if(1===e.length&&Array.isArray(e[0])){var y;e=(y=[]).concat.apply(y,P(e))}if(void 0===t&&(t=function(){}),void 0===n){var _=new Error("");n=function(t){var n="(n/a)";_.stack&&(n=_.stack.split("\n").map((function(e){return"        ".concat(e)})).join("\n"),n="\n".concat(n)),a._log.error("\n","A require() call has failed but no failure handler was","provided.\n","Note that even if the call stack of this error trace","looks like coming from the Liferay AMD Loader, it is not","an error in the Loader what has caused it, but an error","caused by the require() call.\n","The reason why the Loader is in the stack trace is","because it is printing the error so that it doesn't get","lost.\n","However, we recommend providing a failure handler in all","require() calls to be able to recover from errors better","and to avoid the appearance of this message.\n","\n","Some information about the require() call follows:\n","  · Require call id:",s,"\n","  · Required modules:",e,"\n","  · Missing modules:",t.missingModules?t.missingModules:"(n/a)","\n","  · Stack trace of the require() call:","".concat(n),"\n",t)}}t=this._interceptHandler(t,"success",s),n=this._interceptHandler(n,"failure",s);var w=!1;this._dependencyResolver.resolve(e).then((function(t){if(a._log.resolution("Require call",s,"resolved modules",e,"to",t),a._throwOnLegacyProtocolResolutionErrors(t),a._logServerMessages(e,t),t.errors&&t.errors.length>1)throw Object.assign(new Error("The server generated some errors while resolving modules"),{resolutionErrors:t.errors});return u.addMappings(t.configMap),u.addPaths(t.pathMap),r=t.resolvedModules,(o=a._getUnregisteredModuleNames(r)).forEach((function(e){var n={map:t.moduleMap[e]},r=t.moduleFlags?t.moduleFlags[e]:{};(r=r||{}).esModule&&(n.esModule=!0),r.useESM&&(n.useESM=!0),u.addModule(e,n)})),i=a._setRejectTimeout(e,t,(function(){w=!0,n.apply(void 0,arguments)})),a._log.resolution("Fetching",o,"from require call",s),l.loadModules(o)})).then((function(){if(!w)return a._waitForModuleDefinitions(r)})).then((function(){if(!w){clearTimeout(i),a._setModuleImplementations(s,r);var n=a._getModuleImplementations(e);t.apply(void 0,P(n))}})).catch((function(e){w||(i&&clearTimeout(i),n(e))}))}},{key:"_interceptHandler",value:function(e,t,n){var r=this;return function(){r._log.resolution("Invoking",t,"handler for","require call",n);try{e.apply(void 0,arguments)}catch(e){r._log.error("\n","A require() call",t,"handler has thrown an error.\n","Note that even if the call stack of this error trace","looks like coming from the Liferay AMD Loader, it is not","an error in the Loader what has caused it, but an error","in the handler's code.\n","The reason why the Loader is in the stack trace is","because it is printing the error on behalf of the handler","so that it doesn't get lost.\n","However, we recommend wrapping all handler code inside a","try/catch to be able to recover from errors better and to","avoid the appearance of this message.\n","\n",e)}}}},{key:"_getUnregisteredModuleNames",value:function(e){var t=this._config;return e.filter((function(e){return!t.getModule(e)}))}},{key:"_logServerMessages",value:function(e,t){t.errors&&t.errors.length&&this._log.error("Errors returned from server for require(",e,"):",t.errors),t.warnings&&t.warnings.length&&this._log.warn("Warnings returned from server for require(",e,"):",t.warnings)}},{key:"_setRejectTimeout",value:function(e,t,n){var r=this._config;if(0!==r.waitTimeout)return setTimeout((function(){var o=t.resolvedModules.filter((function(e){var t=r.getModule(e);return!t||!t.implemented})),i=Object.assign(new Error("Load timeout for modules: "+e),{missingModules:o,modules:e,resolution:t});n(i)}),r.waitTimeout)}},{key:"_throwOnLegacyProtocolResolutionErrors",value:function(e){var t=e.resolvedModules.filter((function(e){return 0===e.indexOf(":ERROR:")})).map((function(e){return e.substr(7)}));if(t.length)throw Object.assign(new Error("The following problems where detected while resolving modules:\n"+t.map((function(e){return"    · ".concat(e)})).join("\n")),{resolutionErrors:t})}},{key:"_waitForModuleDefinitions",value:function(e){var t=this._config;return Promise.all(t.getModules(e).map((function(e){return e.define})))}},{key:"_waitForModuleImplementations",value:function(e){var t=this._config;return Promise.all(t.getModules(e).map((function(e){return e.implement})))}},{key:"_setModuleImplementations",value:function(e,t){var n=this,r=this._config;r.getModules(t).forEach((function(t){if(!t.implemented){if(t.implement.rejected)throw t.implement.rejection;n._log.resolution("Implementing",t.name,"from require call",e);try{var o={get exports(){return t.implementation},set exports(e){t.implementation=e}},i=t.dependencies.map((function(e){if("exports"===e)return o.exports;if("module"===e)return o;if("require"===e)return n._createLocalRequire(t);var i=r.getDependency(t.name,e);if(!i)throw new Error("Unsatisfied dependency: ".concat(e," ")+"found in module ".concat(t.name));if(!i.implementation&&!i.implemented)throw new Error('Module "'+i.name+'" has not been loaded yet for context: '+t.name);return i.implementation})),a=t.factory.apply(t,P(i));void 0!==a&&(t.implementation=a),t.implement.resolve(t.implementation)}catch(e){throw t.implement.fulfilled||t.implement.reject(e),e}}}))}},{key:"_createLocalRequire",value:function(e){var t=this,n=this._config,r=function(r){for(var o=arguments.length,i=new Array(o>1?o-1:0),a=1;a<o;a++)i[a-1]=arguments[a];if(i.length)return t.require.apply(t,[r].concat(i));var l=n.getDependency(e.name,r);if(!l||!("implementation"in l))throw new Error('Module "'+r+'" has not been loaded yet for context: '+e.name);return l.implementation};return r.toUrl=function(e){return t._urlBuilder.build([e])[0].url},r}},{key:"_getModuleImplementations",value:function(e){return this._config.getModules(e).map((function(e){return e.implementation}))}}])&&L(t.prototype,n),e}();R.prototype.define.amd={};var T=window.__CONFIG__||{},x="string"==typeof T.namespace?T.namespace:void 0,A=void 0===T.exposeGlobal||T.exposeGlobal,q=new R(T);if(x){var I=window[x]?window[x]:{};I.Loader=q,window[x]=I}else window.Loader=q;A&&(window.Loader=q,window.require=R.prototype.require.bind(q),window.define=R.prototype.define.bind(q),window.define.amd={})})()})();

/**
 * SPDX-FileCopyrightText: (c) 2000 Liferay, Inc. https://liferay.com
 * SPDX-License-Identifier: LGPL-2.1-or-later OR LicenseRef-Liferay-DXP-EULA-2.0.0-2023-06
 */

/**
 * @deprecated As of Athanasius (7.3.x), with no direct replacement
 */
(function () {
	const LiferayAUI = Liferay.AUI;

	const COMBINE = LiferayAUI.getCombine();

	const PATH_EDITOR_CKEDITOR = LiferayAUI.getEditorCKEditorPath();

	const PATH_JAVASCRIPT = '/o/frontend-js-aui-web';

	window.YUI_config = {
		base:
			Liferay.ThemeDisplay.getCDNBaseURL() +
			Liferay.ThemeDisplay.getPathContext() +
			PATH_JAVASCRIPT +
			'/aui/',
		combine: COMBINE,
		comboBase: LiferayAUI.getComboPath(),
		filter: 'min', // If you need to debug this file, replace this with 'raw'
		groups: {
			editor: {
				base: PATH_EDITOR_CKEDITOR,
				combine: COMBINE,
				modules: {
					'inline-editor-ckeditor': {
						path: 'ckeditor/main.js',
					},
				},
				root: PATH_EDITOR_CKEDITOR,
			},

			liferay: {
				base:
					Liferay.ThemeDisplay.getCDNBaseURL() +
					Liferay.ThemeDisplay.getPathContext() +
					PATH_JAVASCRIPT +
					'/liferay/',
				combine: COMBINE,
				filter: Liferay.AUI.getFilterConfig(),
				modules: {
					'liferay-auto-fields': {
						path: 'auto_fields.js',
						requires: [
							'aui-base',
							'aui-data-set-deprecated',
							'aui-parse-content',
							'base',
							'liferay-form',
							'liferay-menu',
							'liferay-portlet-base',
							'liferay-undo-manager',
							'sortable',
						],
					},
					'liferay-autocomplete-input': {
						path: 'autocomplete_input.js',
						requires: [
							'aui-base',
							'autocomplete',
							'autocomplete-filters',
							'autocomplete-highlighters',
						],
					},
					'liferay-dynamic-select': {
						path: 'dynamic_select.js',
						requires: ['aui-base'],
					},
					'liferay-form': {
						path: 'form.js',
						requires: ['aui-base', 'aui-form-validator'],
					},
					'liferay-fullscreen-source-editor': {
						path: 'fullscreen_source_editor.js',
						requires: ['liferay-source-editor'],
					},
					'liferay-icon': {
						path: 'icon.js',
						requires: ['aui-base'],
					},
					'liferay-inline-editor-base': {
						path: 'inline_editor_base.js',
						requires: ['aui-base', 'aui-overlay-base-deprecated'],
					},
					'liferay-input-localized': {
						path: 'input_localized.js',
						requires: [
							'aui-base',
							'aui-component',
							'aui-event-input',
							'aui-palette',
							'aui-set',
						],
					},
					'liferay-input-move-boxes': {
						path: 'input_move_boxes.js',
						plugins: {
							'liferay-input-move-boxes-touch': {
								condition: {
									name: 'liferay-input-move-boxes-touch',
									test(A) {
										return (
											A.UA.touchEnabled && !!A.UA.mobile
										);
									},
									trigger: 'liferay-input-move-boxes',
								},
							},
						},
						requires: ['aui-base', 'aui-toolbar'],
					},
					'liferay-input-move-boxes-touch': {
						path: 'input_move_boxes_touch.js',
						requires: [
							'aui-base',
							'aui-template-deprecated',
							'liferay-input-move-boxes',
							'sortable',
						],
					},
					'liferay-layout': {
						path: 'layout.js',
					},
					'liferay-layout-column': {
						path: 'layout_column.js',
						requires: ['aui-sortable-layout', 'dd'],
					},
					'liferay-logo-editor': {
						path: 'logo_editor.js',
						requires: ['aui-image-cropper', 'liferay-portlet-base'],
					},
					'liferay-menu': {
						path: 'menu.js',
						requires: ['aui-debounce', 'aui-node'],
					},
					'liferay-menu-filter': {
						path: 'menu_filter.js',
						requires: [
							'autocomplete-base',
							'autocomplete-filters',
							'autocomplete-highlighters',
						],
					},
					'liferay-menu-toggle': {
						path: 'menu_toggle.js',
						requires: [
							'aui-node',
							'event-outside',
							'event-tap',
							'liferay-menu-filter',
						],
					},
					'liferay-navigation': {
						path: 'navigation.js',
						requires: ['aui-component', 'event-mouseenter'],
					},
					'liferay-navigation-interaction': {
						path: 'navigation_interaction.js',
						plugins: {
							'liferay-navigation-interaction-touch': {
								condition: {
									name: 'liferay-navigation-interaction-touch',
									test(A) {
										return A.UA.touchEnabled;
									},
									trigger: 'liferay-navigation-interaction',
								},
							},
						},
						requires: [
							'aui-base',
							'aui-component',
							'event-mouseenter',
							'node-focusmanager',
							'plugin',
						],
					},
					'liferay-navigation-interaction-touch': {
						path: 'navigation_interaction_touch.js',
						requires: [
							'event-tap',
							'event-touch',
							'liferay-navigation-interaction',
						],
					},
					'liferay-portlet-base': {
						path: 'portlet_base.js',
						requires: ['aui-base'],
					},
					'liferay-portlet-url': {
						path: 'portlet_url.js',
						requires: ['aui-base'],
					},
					'liferay-progress': {
						path: 'progress.js',
						requires: ['aui-progressbar'],
					},
					'liferay-search-container': {
						path: 'search_container.js',
						requires: ['aui-base', 'aui-datatable-core'],
					},
					'liferay-search-container-move': {
						path: 'search_container_move.js',
						requires: [
							'aui-component',
							'dd-constrain',
							'dd-delegate',
							'dd-drag',
							'dd-drop',
							'dd-proxy',
							'plugin',
						],
					},
					'liferay-search-container-select': {
						path: 'search_container_select.js',
						requires: ['aui-component', 'aui-url', 'plugin'],
					},
					'liferay-session': {
						path: 'session.js',
						requires: [
							'aui-base',
							'aui-component',
							'aui-timer',
							'cookie',
							'plugin',
						],
					},
					'liferay-source-editor': {
						path: 'source_editor.js',
						requires: ['aui-ace-editor'],
					},
					'liferay-store': {
						path: 'store.js',
					},
					'liferay-translation-manager': {
						path: 'translation_manager.js',
						requires: ['aui-base'],
					},
					'liferay-undo-manager': {
						path: 'undo_manager.js',
						requires: ['aui-data-set-deprecated', 'base'],
					},
					'liferay-upload': {
						path: 'upload.js',
						requires: [
							'aui-template-deprecated',
							'collection',
							'liferay-portlet-base',
							'uploader',
						],
					},
					'liferay-util-window': {
						path: 'util_window.js',
						requires: [
							'aui-dialog-iframe-deprecated',
							'aui-modal',
							'aui-url',
							'event-resize',
							'liferay-widget-zindex',
						],
					},
					'liferay-widget-zindex': {
						path: 'widget_zindex.js',
						requires: ['aui-modal', 'plugin'],
					},
				},
				root: PATH_JAVASCRIPT + '/liferay/',
			},
		},
		insertBefore: 'liferayAUICSS',
		lang: themeDisplay.getBCP47LanguageId(),
		root: PATH_JAVASCRIPT + '/aui/',
		useBrowserConsole: false,
	};
})();

/**
 * SPDX-FileCopyrightText: (c) 2000 Liferay, Inc. https://liferay.com
 * SPDX-License-Identifier: LGPL-2.1-or-later OR LicenseRef-Liferay-DXP-EULA-2.0.0-2023-06
 */

/**
 * @deprecated As of Athanasius (7.3.x), with no direct replacement
 */
(function () {
	const ALLOY = YUI();

	if (ALLOY.html5shiv) {
		ALLOY.html5shiv();
	}

	const originalUse = ALLOY.use;

	ALLOY.use = function () {
		const args = Array.prototype.slice.call(arguments, 0);

		const currentURL = Liferay.currentURL;

		const originalCallback = args[args.length - 1];

		if (typeof originalCallback === 'function') {
			args[args.length - 1] = function () {
				if (Liferay.currentURL === currentURL) {
					originalCallback.apply(this, arguments);
				}
			};
		}

		return originalUse.apply(this, args);
	};

	window.AUI = function () {
		return ALLOY;
	};

	ALLOY.mix(AUI, YUI);

	AUI.$ = window.jQuery;
	AUI._ = window._;
})();

YUI.add("attribute-base",function(e,t){function n(){e.AttributeCore.apply(this,arguments),e.AttributeObservable.apply(this,arguments),e.AttributeExtras.apply(this,arguments)}e.mix(n,e.AttributeCore,!1,null,1),e.mix(n,e.AttributeExtras,!1,null,1),e.mix(n,e.AttributeObservable,!0,null,1),n.INVALID_VALUE=e.AttributeCore.INVALID_VALUE,n._ATTR_CFG=e.AttributeCore._ATTR_CFG.concat(e.AttributeObservable._ATTR_CFG),n.protectAttrs=e.AttributeCore.protectAttrs,e.Attribute=n},"patched-v3.20.6",{requires:["attribute-core","attribute-observable","attribute-extras"]});

YUI.add("attribute-complex",function(e,t){var n=e.Attribute;n.Complex=function(){},n.Complex.prototype={_normAttrVals:n.prototype._normAttrVals,_getAttrInitVal:n.prototype._getAttrInitVal},e.AttributeComplex=n.Complex},"patched-v3.20.6",{requires:["attribute-base"]});

YUI.add("attribute-core",function(e,t){function b(e,t,n){this._yuievt=null,this._initAttrHost(e,t,n)}e.State=function(){this.data={}},e.State.prototype={add:function(e,t,n){var r=this.data[e];r||(r=this.data[e]={}),r[t]=n},addAll:function(e,t){var n=this.data[e],r;n||(n=this.data[e]={});for(r in t)t.hasOwnProperty(r)&&(n[r]=t[r])},remove:function(e,t){var n=this.data[e];n&&delete n[t]},removeAll:function(t,n){var r;n?e.each(n,function(e,n){this.remove(t,typeof n=="string"?n:e)},this):(r=this.data,t in r&&delete r[t])},get:function(e,t){var n=this.data[e];if(n)return n[t]},getAll:function(e,t){var n=this.data[e],r,i;if(t)i=n;else if(n){i={};for(r in n)n.hasOwnProperty(r)&&(i[r]=n[r])}return i}};var n=e.Object,r=e.Lang,i=".",s="getter",o="setter",u="readOnly",a="writeOnce",f="initOnly",l="validator",c="value",h="valueFn",p="lazyAdd",d="added",v="_bypassProxy",m="initValue",g="lazy",y;b.INVALID_VALUE={},y=b.INVALID_VALUE,b._ATTR_CFG=[o,s,l,c,h,a,u,p,v],b.protectAttrs=function(t){if(t){t=e.merge(t);for(var n in t)t.hasOwnProperty(n)&&(t[n]=e.merge(t[n]))}return t},b.prototype={_initAttrHost:function(t,n,r){this._state=new e.State,this._initAttrs(t,n,r)},addAttr:function(e,t,n){var r=this,i=r._state,s=i.data,o,u,a;t=t||{},p in t&&(n=t[p]),u=i.get(e,d);if(n&&!u)i.data[e]={lazy:t,added:!0};else if(!u||t.isLazyAdd)a=c in t,a&&(o=t.value,t.value=undefined),t.added=!0,t.initializing=!0,s[e]=t,a&&r.set(e,o),t.initializing=!1;return r},attrAdded:function(e){return!!this._state.get(e,d)},get:function(e){return this._getAttr(e)},_isLazyAttr:function(e){return this._state.get(e,g)},_addLazyAttr:function(e,t){var n=this._state;t=t||n.get(e,g),t&&(n.data[e].lazy=undefined,t.isLazyAdd=!0,this.addAttr(e,t))},set:function(e,t,n){return this._setAttr(e,t,n)},_set:function(e,t,n){return this._setAttr(e,t,n,!0)},_setAttr:function(t,r,s,o){var u=!0,a=this._state,l=this._stateProxy,c=this._tCfgs,h,p,d,v,m,g,y;t.indexOf(i)!==-1&&(d=t,v=t.split(i),t=v.shift()),c&&c[t]&&this._addOutOfOrder(t,c[t]),h=a.data[t]||{},h.lazy&&(h=h.lazy,this._addLazyAttr(t,h)),p=h.value===undefined,l&&t in l&&!h._bypassProxy&&(p=!1),g=h.writeOnce,y=h.initializing,!p&&!o&&(g&&(u=!1),h.readOnly&&(u=!1)),!y&&!o&&g===f&&(u=!1);if(u){p||(m=this.get(t));if(v){var b=[m].reduce(function(e,t){return Object.keys(t).forEach(function(n){e[n]=t[n]}),e},{}),w=b,E=v.length-1;for(var S=0;S<E&&w;S++)w=w[v[S]];w&&delete w[v[E]],r=n.setValue(e.clone(b),v,r),r===undefined&&(u=!1)}u&&(!this._fireAttrChange||y?this._setAttrVal(t,d,m,r,s,h):this._fireAttrChange(t,d,m,r,s,h))}return this},_addOutOfOrder:function(e,t){var n={};n[e]=t,delete this._tCfgs[e],this._addAttrs(n,this._tVals)},_getAttr:function(e){var t=e,r=this._tCfgs,s,o,u,a;return e.indexOf(i)!==-1&&(s=e.split(i),e=s.shift()),r&&r[e]&&this._addOutOfOrder(e,r[e]),a=this._state.data[e]||{},a.lazy&&(a=a.lazy,this._addLazyAttr(e,a)),u=this._getStateVal(e,a),o=a.getter,o&&!o.call&&(o=this[o]),u=o?o.call(this,u,t):u,u=s?n.getValue(u,s):u,u},_getStateVal:function(e,t){var n=this._stateProxy;return t||(t=this._state.getAll(e)||{}),n&&e in n&&!t._bypassProxy?n[e]:t.value},_setStateVal:function(e,t){var n=this._stateProxy;n&&e in n&&!this._state.get(e,v)?n[e]=t:this._state.add(e,c,t)},_setAttrVal:function(e,t,n,i,s,o){var u=this,a=!0,f=o||this._state.data[e]||{},l=f.validator,c=f.setter,h=f.initializing,p=this._getStateVal(e,f),d=t||e,v,g;return l&&(l.call||(l=this[l]),l&&(g=l.call(u,i,d,s),!g&&h&&(i=f.defaultValue,g=!0))),!l||g?(c&&(c.call||(c=this[c]),c&&(v=c.call(u,i,d,s),v===y?h?i=f.defaultValue:a=!1:v!==undefined&&(i=v))),a&&(!t&&i===p&&!r.isObject(i)?a=!1:(m in f||(f.initValue=i),u._setStateVal(e,i)))):a=!1,a},setAttrs:function(e,t){return this._setAttrs(e,t)},_setAttrs:function(e,t){var n;for(n in e)e.hasOwnProperty(n)&&this.set(n,e[n],t);return this},getAttrs:function(e){return this._getAttrs(e)},_getAttrs:function(e){var t={},r,i,s,o=e===!0;if(!e||o)e=n.keys(this._state.data);for(i=0,s=e.length;i<s;i++){r=e[i];if(!o||this._getStateVal(r)!=this._state.get(r,m))t[r]=this.get(r)}return t},addAttrs:function(e,t,n){return e&&(this._tCfgs=e,this._tVals=t?this._normAttrVals(t):null,this._addAttrs(e,this._tVals,n),this._tCfgs=this._tVals=null),this},_addAttrs:function(e,t,n){var r=this._tCfgs,i=this._tVals,s,o,u;for(s in e)e.hasOwnProperty(s)&&(o=e[s],o.defaultValue=o.value,u=this._getAttrInitVal(s,o,i),u!==undefined&&(o.value=u),r[s]&&(r[s]=undefined),this.addAttr(s,o,n))},_protectAttrs:b.protectAttrs,_normAttrVals:function(e){var t,n,r,s,o,u;if(!e)return null;t={};for(u in e)e.hasOwnProperty(u)&&(u.indexOf(i)!==-1?(r=u.split(i),s=r.shift(),n=n||{},o=n[s]=n[s]||[],o[o.length]={path:r,value:e[u]}):t[u]=e[u]);return{simple:t,complex:n}},_getAttrInitVal:function(e,t,r){var i=t.value,s=t.valueFn,o,u=!1,a=t.readOnly,f,l,c,h,p,d,v;!a&&r&&(f=r.simple,f&&f.hasOwnProperty(e)&&(i=f[e],u=!0)),s&&!u&&(s.call||(s=this[s]),s&&(o=s.call(this,e),i=o));if(!a&&r){l=r.complex;if(l&&l.hasOwnProperty(e)&&i!==undefined&&i!==null){v=l[e];for(c=0,h=v.length;c<h;++c)p=v[c].path,d=v[c].value,n.setValue(i,p,d)}}return i},_initAttrs:function(t,n,r){t=t||this.constructor.ATTRS;var i=e.Base,s=e.BaseCore,o=i&&e.instanceOf(this,i),u=!o&&s&&e.instanceOf(this,s);t&&!o&&!u&&this.addAttrs(e.AttributeCore.protectAttrs(t),n,r)}},e.AttributeCore=b},"patched-v3.20.6",{requires:["oop"]});

YUI.add("attribute-observable",function(e,t){function s(){this._ATTR_E_FACADE={},n.call(this,{emitFacade:!0})}var n=e.EventTarget,r="Change",i="broadcast";s._ATTR_CFG=[i],s.prototype={set:function(e,t,n){return this._setAttr(e,t,n)},_set:function(e,t,n){return this._setAttr(e,t,n,!0)},setAttrs:function(e,t){return this._setAttrs(e,t)},_setAttrs:function(e,t){var n;for(n in e)e.hasOwnProperty(n)&&this.set(n,e[n],t);return this},_fireAttrChange:function(t,n,i,s,o,u){var a=this,f=this._getFullType(t+r),l=a._state,c,h,p;u||(u=l.data[t]||{}),u.published||(p=a._publish(f),p.emitFacade=!0,p.defaultTargetOnly=!0,p.defaultFn=a._defAttrChangeFn,h=u.broadcast,h!==undefined&&(p.broadcast=h),u.published=!0),o?(c=e.merge(o),c._attrOpts=o):c=a._ATTR_E_FACADE,c.attrName=t,c.subAttrName=n,c.prevVal=i,c.newVal=s,a._hasPotentialSubscribers(f)?a.fire(f,c):this._setAttrVal(t,n,i,s,o,u)},_defAttrChangeFn:function(e,t){var n=e._attrOpts;n&&delete e._attrOpts,this._setAttrVal(e.attrName,e.subAttrName,e.prevVal,e.newVal,n)?t||(e.newVal=this.get(e.attrName)):t||e.stopImmediatePropagation()}},e.mix(s,n,!1,null,1),e.AttributeObservable=s,e.AttributeEvents=s},"patched-v3.20.6",{requires:["event-custom"]});

YUI.add("attribute-extras",function(e,t){function o(){}var n="broadcast",r="published",i="initValue",s={readOnly:1,writeOnce:1,getter:1,broadcast:1};o.prototype={modifyAttr:function(e,t){var i=this,o,u;if(i.attrAdded(e)){i._isLazyAttr(e)&&i._addLazyAttr(e),u=i._state;for(o in t)s[o]&&t.hasOwnProperty(o)&&(u.add(e,o,t[o]),o===n&&u.remove(e,r))}},removeAttr:function(e){this._state.removeAll(e)},reset:function(t){var n=this;return t?(n._isLazyAttr(t)&&n._addLazyAttr(t),n.set(t,n._state.get(t,i))):e.Object.each(n._state.data,function(e,t){n.reset(t)}),n},_getAttrCfg:function(t){var n,r=this._state;return t?n=r.getAll(t)||{}:(n={},e.each(r.data,function(e,t){n[t]=r.getAll(t)})),n}},e.AttributeExtras=o},"patched-v3.20.6",{requires:["oop"]});

YUI.add("event-custom-base",function(e,t){e.Env.evt={handles:{},plugins:{}};var n=0,r=1,i={objs:null,before:function(t,r,i,s){var o=t,u;return s&&(u=[t,s].concat(e.Array(arguments,4,!0)),o=e.rbind.apply(e,u)),this._inject(n,o,r,i)},after:function(t,n,i,s){var o=t,u;return s&&(u=[t,s].concat(e.Array(arguments,4,!0)),o=e.rbind.apply(e,u)),this._inject(r,o,n,i)},_inject:function(t,n,r,i){var s=e.stamp(r),o,u;return r._yuiaop||(r._yuiaop={}),o=r._yuiaop,o[i]||(o[i]=new e.Do.Method(r,i),r[i]=function(){return o[i].exec.apply(o[i],arguments)}),u=s+e.stamp(n)+i,o[i].register(u,n,t),new e.EventHandle(o[i],u)},detach:function(e){e.detach&&e.detach()}};e.Do=i,i.Method=function(e,t){this.obj=e,this.methodName=t,this.method=e[t],this.before={},this.after={}},i.Method.prototype.register=function(e,t,n){n?this.after[e]=t:this.before[e]=t},i.Method.prototype._delete=function(e){delete this.before[e],delete this.after[e]},i.Method.prototype.exec=function(){var t=e.Array(arguments,0,!0),n,r,s,o=this.before,u=this.after,a=!1;for(n in o)if(o.hasOwnProperty(n)){r=o[n].apply(this.obj,t);if(r)switch(r.constructor){case i.Halt:return r.retVal;case i.AlterArgs:t=r.newArgs;break;case i.Prevent:a=!0;break;default:}}a||(r=this.method.apply(this.obj,t)),i.originalRetVal=r,i.currentRetVal=r;for(n in u)if(u.hasOwnProperty(n)){s=u[n].apply(this.obj,t);if(s&&s.constructor===i.Halt)return s.retVal;s&&s.constructor===i.AlterReturn&&(r=s.newRetVal,i.currentRetVal=r)}return r},i.AlterArgs=function(e,t){this.msg=e,this.newArgs=t},i.AlterReturn=function(e,t){this.msg=e,this.newRetVal=t},i.Halt=function(e,t){this.msg=e,this.retVal=t},i.Prevent=function(e){this.msg=e},i.Error=i.Halt;var s=e.Array,o="after",u=["broadcast","monitored","bubbles","context","contextFn","currentTarget","defaultFn","defaultTargetOnly","details","emitFacade","fireOnce","async","host","preventable","preventedFn","queuable","silent","stoppedFn","target","type"],a=s.hash(u),f=Array.prototype.slice,l=9,c="yui:log",h=function(e,t,n){var r;for(r in t)a[r]&&(n||!(r in e))&&(e[r]=t[r]);return e};e.CustomEvent=function(t,n){this._kds=e.CustomEvent.keepDeprecatedSubs,this.id=e.guid(),this.type=t,this.silent=this.logSystem=t===c,this._kds&&(this.subscribers={},this.afters={}),n&&h(this,n,!0)},e.CustomEvent.keepDeprecatedSubs=!1,e.CustomEvent.mixConfigs=h,e.CustomEvent.prototype={constructor:e.CustomEvent,signature:l,context:e,preventable:!0,bubbles:!0,hasSubs:function(e){var t=0,n=0,r=this._subscribers,i=this._afters,s=this.sibling;return r&&(t=r.length),i&&(n=i.length),s&&(r=s._subscribers,i=s._afters,r&&(t+=r.length),i&&(n+=i.length)),e?e==="after"?n:t:t+n},monitor:function(e){this.monitored=!0;var t=this.id+"|"+this.type+"_"+e,n=f.call(arguments,0);return n[0]=t,this.host.on.apply(this.host,n)},getSubs:function(){var e=this.sibling,t=this._subscribers,n=this._afters,r,i;return e&&(r=e._subscribers,i=e._afters),r?t?t=t.concat(r):t=r.concat():t?t=t.concat():t=[],i?n?n=n.concat(i):n=i.concat():n?n=n.concat():n=[],[t,n]},applyConfig:function(e,t){h(this,e,t)},_on:function(t,n,r,i){var s=new e.Subscriber(t,n,r,i),u;return this.fireOnce&&this.fired&&(u=this.firedWith,this.emitFacade&&this._addFacadeToArgs&&this._addFacadeToArgs(u),this.async?setTimeout(e.bind(this._notify,this,s,u),0):this._notify(s,u)),i===o?(this._afters||(this._afters=[]),this._afters.push(s)):(this._subscribers||(this._subscribers=[]),this._subscribers.push(s)),this._kds&&(i===o?this.afters[s.id]=s:this.subscribers[s.id]=s),new e.EventHandle(this,s)},subscribe:function(e,t){var n=arguments.length>2?f.call(arguments,2):null;return this._on(e,t,n,!0)},on:function(e,t){var n=arguments.length>2?f.call(arguments,2):null;return this.monitored&&this.host&&this.host._monitor("attach",this,{args:arguments}),this._on(e,t,n,!0)},after:function(e,t){var n=arguments.length>2?f.call(arguments,2):null;return this._on(e,t,n,o)},detach:function(e,t){if(e&&e.detach)return e.detach();var n,r,i=0,s=this._subscribers,o=this._afters;if(s)for(n=s.length;n>=0;n--)r=s[n],r&&(!e||e===r.fn)&&(this._delete(r,s,n),i++);if(o)for(n=o.length;n>=0;n--)r=o[n],r&&(!e||e===r.fn)&&(this._delete(r,o,n),i++);return i},unsubscribe:function(){return this.detach.apply(this,arguments)},_notify:function(e,t,n){var r;return r=e.notify(t,this),!1===r||this.stopped>1?!1:!0},log:function(e,t){},fire:function(){var e=[];return e.push.apply(e,arguments),this._fire(e)},_fire:function(e){return this.fireOnce&&this.fired?!0:(this.fired=!0,this.fireOnce&&(this.firedWith=e),this.emitFacade?this.fireComplex(e):this.fireSimple(e))},fireSimple:function(e){this.stopped=0,this.prevented=0;if(this.hasSubs()){var t=this.getSubs();this._procSubs(t[0],e),this._procSubs(t[1],e)}return this.broadcast&&this._broadcast(e),this.stopped?!1:!0},fireComplex:function(e){return e[0]=e[0]||{},this.fireSimple(e)},_procSubs:function(e,t,n){var r,i,s;for(i=0,s=e.length;i<s;i++){r=e[i];if(r&&r.fn){!1===this._notify(r,t,n)&&(this.stopped=2);if(this.stopped===2)return!1}}return!0},_broadcast:function(t){if(!this.stopped&&this.broadcast){var n=t.concat();n.unshift(this.type),this.host!==e&&e.fire.apply(e,n),this.broadcast===2&&e.Global.fire.apply(e.Global,n)}},unsubscribeAll:function(){return this.detachAll.apply(this,arguments)},detachAll:function(){return this.detach()},_delete:function(e,t,n){var r=e._when;t||(t=r===o?this._afters:this._subscribers),t&&(n=s.indexOf(t,e,0),e&&t[n]===e&&t.splice(n,1)),this._kds&&(r===o?delete this.afters[e.id]:delete this.subscribers[e.id]),this.monitored&&this.host&&this.host._monitor("detach",this,{ce:this,sub:e}),e&&(e.deleted=!0)}},e.Subscriber=function(t,n,r,i){this.fn=t,this.context=n,this.id=e.guid(),this.args=r,this._when=i},e.Subscriber.prototype={constructor:e.Subscriber,_notify:function(e,t,n){if(this.deleted&&!this.postponed){if(!this.postponed)return delete this.postponed,null;delete this.fn,delete this.context}var r=this.args,i;switch(n.signature){case 0:i=this.fn.call(e,n.type,t,e);break;case 1:i=this.fn.call(e,t[0]||null,e);break;
default:r||t?(t=t||[],r=r?t.concat(r):t,i=this.fn.apply(e,r)):i=this.fn.call(e)}return this.once&&n._delete(this),i},notify:function(t,n){var r=this.context,i=!0;r||(r=n.contextFn?n.contextFn():n.context);if(e.config&&e.config.throwFail)i=this._notify(r,t,n);else try{i=this._notify(r,t,n)}catch(s){e.error(this+" failed: "+s.message,s)}return i},contains:function(e,t){return t?this.fn===e&&this.context===t:this.fn===e},valueOf:function(){return this.id}},e.EventHandle=function(e,t){this.evt=e,this.sub=t},e.EventHandle.prototype={batch:function(t,n){t.call(n||this,this),e.Lang.isArray(this.evt)&&e.Array.each(this.evt,function(e){e.batch.call(n||e,t)})},detach:function(){var t=this.evt,n=0,r;if(t)if(e.Lang.isArray(t))for(r=0;r<t.length;r++)n+=t[r].detach();else t._delete(this.sub),n=1;return n},monitor:function(e){return this.evt.monitor.apply(this.evt,arguments)}};var p=e.Lang,d=":",v="|",m="~AFTER~",g=/(.*?)(:)(.*?)/,y=e.cached(function(e){return e.replace(g,"*$2$3")}),b=function(e,t){return!t||typeof e!="string"||e.indexOf(d)>-1?e:t+d+e},w=e.cached(function(e,t){var n=e,r,i,s;return p.isString(n)?(s=n.indexOf(m),s>-1&&(i=!0,n=n.substr(m.length)),s=n.indexOf(v),s>-1&&(r=n.substr(0,s),n=n.substr(s+1),n==="*"&&(n=null)),[r,t?b(n,t):n,i,n]):n}),E=function(t){var n=this._yuievt,r;n||(n=this._yuievt={events:{},targets:null,config:{host:this,context:this},chain:e.config.chain}),r=n.config,t&&(h(r,t,!0),t.chain!==undefined&&(n.chain=t.chain),t.prefix&&(r.prefix=t.prefix))};E.prototype={constructor:E,once:function(){var e=this.on.apply(this,arguments);return e.batch(function(e){e.sub&&(e.sub.once=!0)}),e},onceAfter:function(){var e=this.after.apply(this,arguments);return e.batch(function(e){e.sub&&(e.sub.once=!0)}),e},parseType:function(e,t){return w(e,t||this._yuievt.config.prefix)},on:function(t,n,r){var i=this._yuievt,s=w(t,i.config.prefix),o,u,a,l,c,h,d,v=e.Env.evt.handles,g,y,b,E=e.Node,S,x,T;this._monitor("attach",s[1],{args:arguments,category:s[0],after:s[2]});if(p.isObject(t))return p.isFunction(t)?e.Do.before.apply(e.Do,arguments):(o=n,u=r,a=f.call(arguments,0),l=[],p.isArray(t)&&(T=!0),g=t._after,delete t._after,e.each(t,function(e,t){p.isObject(e)&&(o=e.fn||(p.isFunction(e)?e:o),u=e.context||u);var n=g?m:"";a[0]=n+(T?e:t),a[1]=o,a[2]=u,l.push(this.on.apply(this,a))},this),i.chain?this:new e.EventHandle(l));h=s[0],g=s[2],b=s[3];if(E&&e.instanceOf(this,E)&&b in E.DOM_EVENTS)return a=f.call(arguments,0),a.splice(2,0,E.getDOMNode(this)),e.on.apply(e,a);t=s[1];if(e.instanceOf(this,YUI)){y=e.Env.evt.plugins[t],a=f.call(arguments,0),a[0]=b,E&&(S=a[2],e.instanceOf(S,e.NodeList)?S=e.NodeList.getDOMNodes(S):e.instanceOf(S,E)&&(S=E.getDOMNode(S)),x=b in E.DOM_EVENTS,x&&(a[2]=S));if(y)d=y.on.apply(e,a);else if(!t||x)d=e.Event._attach(a)}return d||(c=i.events[t]||this.publish(t),d=c._on(n,r,arguments.length>3?f.call(arguments,3):null,g?"after":!0),t.indexOf("*:")!==-1&&(this._hasSiblings=!0)),h&&(v[h]=v[h]||{},v[h][t]=v[h][t]||[],v[h][t].push(d)),i.chain?this:d},subscribe:function(){return this.on.apply(this,arguments)},detach:function(t,n,r){var i=this._yuievt.events,s,o=e.Node,u=o&&e.instanceOf(this,o);if(!t&&this!==e){for(s in i)i.hasOwnProperty(s)&&i[s].detach(n,r);return u&&e.Event.purgeElement(o.getDOMNode(this)),this}var a=w(t,this._yuievt.config.prefix),l=p.isArray(a)?a[0]:null,c=a?a[3]:null,h,d=e.Env.evt.handles,v,m,g,y,b=function(e,t,n){var r=e[t],i,s;if(r)for(s=r.length-1;s>=0;--s)i=r[s].evt,(i.host===n||i.el===n)&&r[s].detach()};if(l){m=d[l],t=a[1],v=u?e.Node.getDOMNode(this):this;if(m){if(t)b(m,t,v);else for(s in m)m.hasOwnProperty(s)&&b(m,s,v);return this}}else{if(p.isObject(t)&&t.detach)return t.detach(),this;if(u&&(!c||c in o.DOM_EVENTS))return g=f.call(arguments,0),g[2]=o.getDOMNode(this),e.detach.apply(e,g),this}h=e.Env.evt.plugins[c];if(e.instanceOf(this,YUI)){g=f.call(arguments,0);if(h&&h.detach)return h.detach.apply(e,g),this;if(!t||!h&&o&&t in o.DOM_EVENTS)return g[0]=t,e.Event.detach.apply(e.Event,g),this}return y=i[a[1]],y&&y.detach(n,r),this},unsubscribe:function(){return this.detach.apply(this,arguments)},detachAll:function(e){return this.detach(e)},unsubscribeAll:function(){return this.detachAll.apply(this,arguments)},publish:function(t,n){var r,i=this._yuievt,s=i.config,o=s.prefix;return typeof t=="string"?(o&&(t=b(t,o)),r=this._publish(t,s,n)):(r={},e.each(t,function(e,t){o&&(t=b(t,o)),r[t]=this._publish(t,s,e||n)},this)),r},_getFullType:function(e){var t=this._yuievt.config.prefix;return t?t+d+e:e},_publish:function(t,n,r){var i,s=this._yuievt,o=s.config,u=o.host,a=o.context,f=s.events;return i=f[t],(o.monitored&&!i||i&&i.monitored)&&this._monitor("publish",t,{args:arguments}),i||(i=f[t]=new e.CustomEvent(t,n),n||(i.host=u,i.context=a)),r&&h(i,r,!0),i},_monitor:function(e,t,n){var r,i,s;if(t){typeof t=="string"?(s=t,i=this.getEvent(t,!0)):(i=t,s=t.type);if(this._yuievt.config.monitored&&(!i||i.monitored)||i&&i.monitored)r=s+"_"+e,n.monitored=e,this.fire.call(this,r,n)}},fire:function(e){var t=typeof e=="string",n=arguments.length,r=e,i=this._yuievt,s=i.config,o=s.prefix,u,a,l,c;t&&n<=3?n===2?c=[arguments[1]]:n===3?c=[arguments[1],arguments[2]]:c=[]:c=f.call(arguments,t?1:0),t||(r=e&&e.type),o&&(r=b(r,o)),a=i.events[r],this._hasSiblings&&(l=this.getSibling(r,a),l&&!a&&(a=this.publish(r))),(s.monitored&&(!a||a.monitored)||a&&a.monitored)&&this._monitor("fire",a||r,{args:c});if(!a){if(i.hasTargets)return this.bubble({type:r},c,this);u=!0}else l&&(a.sibling=l),u=a._fire(c);return i.chain?this:u},getSibling:function(e,t){var n;return e.indexOf(d)>-1&&(e=y(e),n=this.getEvent(e,!0),n&&(n.applyConfig(t),n.bubbles=!1,n.broadcast=0)),n},getEvent:function(e,t){var n,r;return t||(n=this._yuievt.config.prefix,e=n?b(e,n):e),r=this._yuievt.events,r[e]||null},after:function(t,n){var r=f.call(arguments,0);switch(p.type(t)){case"function":return e.Do.after.apply(e.Do,arguments);case"array":case"object":r[0]._after=!0;break;default:r[0]=m+t}return this.on.apply(this,r)},before:function(){
return this.on.apply(this,arguments)}},e.EventTarget=E,e.mix(e,E.prototype),E.call(e,{bubbles:!1}),YUI.Env.globalEvents=YUI.Env.globalEvents||new E,e.Global=YUI.Env.globalEvents},"patched-v3.20.6",{requires:["oop"]});

YUI.add("event-custom-complex",function(e,t){var n,r,i=e.Object,s,o={},u=e.CustomEvent.prototype,a=e.EventTarget.prototype,f=function(e,t){var n;for(n in t)r.hasOwnProperty(n)||(e[n]=t[n])};e.EventFacade=function(e,t){e||(e=o),this._event=e,this.details=e.details,this.type=e.type,this._type=e.type,this.target=e.target,this.currentTarget=t,this.relatedTarget=e.relatedTarget},e.mix(e.EventFacade.prototype,{stopPropagation:function(){this._event.stopPropagation(),this.stopped=1},stopImmediatePropagation:function(){this._event.stopImmediatePropagation(),this.stopped=2},preventDefault:function(){this._event.preventDefault(),this.prevented=1},halt:function(e){this._event.halt(e),this.prevented=1,this.stopped=e?2:1}}),u.fireComplex=function(t){var n,r,i,s,o,u=!0,a,f,l,c,h,p,d,v,m,g=this,y=g.host||g,b,w,E=g.stack,S=y._yuievt,x;if(E&&g.queuable&&g.type!==E.next.type)return E.queue||(E.queue=[]),E.queue.push([g,t]),!0;x=g.hasSubs()||S.hasTargets||g.broadcast,g.target=g.target||y,g.currentTarget=y,g.details=t.concat();if(x){n=E||{id:g.id,next:g,silent:g.silent,stopped:0,prevented:0,bubbling:null,type:g.type,defaultTargetOnly:g.defaultTargetOnly},f=g.getSubs(),l=f[0],c=f[1],g.stopped=g.type!==n.type?0:n.stopped,g.prevented=g.type!==n.type?0:n.prevented,g.stoppedFn&&(a=new e.EventTarget({fireOnce:!0,context:y}),g.events=a,a.on("stopped",g.stoppedFn)),g._facade=null,r=g._createFacade(t),l&&g._procSubs(l,t,r),g.bubbles&&y.bubble&&!g.stopped&&(w=n.bubbling,n.bubbling=g.type,n.type!==g.type&&(n.stopped=0,n.prevented=0),u=y.bubble(g,t,null,n),g.stopped=Math.max(g.stopped,n.stopped),g.prevented=Math.max(g.prevented,n.prevented),n.bubbling=w),d=g.prevented,d?(v=g.preventedFn,v&&v.apply(y,t)):(m=g.defaultFn,m&&(!g.defaultTargetOnly&&!n.defaultTargetOnly||y===r.target)&&m.apply(y,t)),g.broadcast&&g._broadcast(t);if(c&&!g.prevented&&g.stopped<2){h=n.afterQueue;if(n.id===g.id||g.type!==S.bubbling){g._procSubs(c,t,r);if(h)while(b=h.last())b()}else p=c,n.execDefaultCnt&&(p=e.merge(p),e.each(p,function(e){e.postponed=!0})),h||(n.afterQueue=new e.Queue),n.afterQueue.add(function(){g._procSubs(p,t,r)})}g.target=null;if(n.id===g.id){s=n.queue;if(s)while(s.length)i=s.pop(),o=i[0],n.next=o,o._fire(i[1]);g.stack=null}u=!g.stopped,g.type!==S.bubbling&&(n.stopped=0,n.prevented=0,g.stopped=0,g.prevented=0)}else m=g.defaultFn,m&&(r=g._createFacade(t),(!g.defaultTargetOnly||y===r.target)&&m.apply(y,t));return g._facade=null,u},u._hasPotentialSubscribers=function(){return this.hasSubs()||this.host._yuievt.hasTargets||this.broadcast},u._createFacade=u._getFacade=function(t){var n=this.details,r=n&&n[0],i=r&&typeof r=="object",s=this._facade;return s||(s=new e.EventFacade(this,this.currentTarget)),i?(f(s,r),r.type&&(s.type=r.type),t&&(t[0]=s)):t&&t.unshift(s),s.details=this.details,s.target=this.originalTarget||this.target,s.currentTarget=this.currentTarget,s.stopped=0,s.prevented=0,this._facade=s,this._facade},u._addFacadeToArgs=function(e){var t=e[0];t&&t.halt&&t.stopImmediatePropagation&&t.stopPropagation&&t._event||this._createFacade(e)},u.stopPropagation=function(){this.stopped=1,this.stack&&(this.stack.stopped=1),this.events&&this.events.fire("stopped",this)},u.stopImmediatePropagation=function(){this.stopped=2,this.stack&&(this.stack.stopped=2),this.events&&this.events.fire("stopped",this)},u.preventDefault=function(){this.preventable&&(this.prevented=1,this.stack&&(this.stack.prevented=1))},u.halt=function(e){e?this.stopImmediatePropagation():this.stopPropagation(),this.preventDefault()},a.addTarget=function(t){var n=this._yuievt;return n.targets||(n.targets={}),n.targets[e.stamp(t)]=t,n.hasTargets=!0,this},a.getTargets=function(){var e=this._yuievt.targets;return e?i.values(e):[]},a.removeTarget=function(t){var n=this._yuievt.targets;return n&&(delete n[e.stamp(t,!0)],i.size(n)===0&&(this._yuievt.hasTargets=!1)),this},a.bubble=function(e,t,n,r){var i=this._yuievt.targets,s=!0,o,u,a,f,l,c=e&&e.type,h=n||e&&e.target||this,p;if(!e||!e.stopped&&i)for(a in i)if(i.hasOwnProperty(a)){o=i[a],u=o._yuievt.events[c],o._hasSiblings&&(l=o.getSibling(c,u)),l&&!u&&(u=o.publish(c)),p=o._yuievt.bubbling,o._yuievt.bubbling=c;if(!u)o._yuievt.hasTargets&&o.bubble(e,t,h,r);else{l&&(u.sibling=l),u.target=h,u.originalTarget=h,u.currentTarget=o,f=u.broadcast,u.broadcast=!1,u.emitFacade=!0,u.stack=r,s=s&&u.fire.apply(u,t||e.details||[]),u.broadcast=f,u.originalTarget=null;if(u.stopped)break}o._yuievt.bubbling=p}return s},a._hasPotentialSubscribers=function(e){var t=this._yuievt,n=t.events[e];return n?n.hasSubs()||t.hasTargets||n.broadcast:!1},n=new e.EventFacade,r={};for(s in n)r[s]=!0},"patched-v3.20.6",{requires:["event-custom-base"]});

YUI.add("oop",function(e,t){function a(t,n,i,s,o){if(t&&t[o]&&t!==e)return t[o].call(t,n,i);switch(r.test(t)){case 1:return r[o](t,n,i);case 2:return r[o](e.Array(t,0,!0),n,i);default:return e.Object[o](t,n,i,s)}}var n=e.Lang,r=e.Array,i=Object.prototype,s="_~yuim~_",o=i.hasOwnProperty,u=i.toString;e.augment=function(t,n,r,i,s){var a=t.prototype,f=a&&n,l=n.prototype,c=a||t,h,p,d,v,m;return s=s?e.Array(s):[],f&&(p={},d={},v={},h=function(e,t){if(r||!(t in a))u.call(e)==="[object Function]"?(v[t]=e,p[t]=d[t]=function(){return m(this,e,arguments)}):p[t]=e},m=function(e,t,r){for(var i in v)o.call(v,i)&&e[i]===d[i]&&(e[i]=v[i]);return n.apply(e,s),t.apply(e,r)},i?e.Array.each(i,function(e){e in l&&h(l[e],e)}):e.Object.each(l,h,null,!0)),e.mix(c,p||l,r,i),f||n.apply(c,s),t},e.aggregate=function(t,n,r,i){return e.mix(t,n,r,i,0,!0)},e.extend=function(t,n,r,s){(!n||!t)&&e.error("extend failed, verify dependencies");var o=n.prototype,u=e.Object(o);return t.prototype=u,u.constructor=t,t.superclass=o,n!=Object&&o.constructor==i.constructor&&(o.constructor=n),r&&e.mix(u,r,!0),s&&e.mix(t,s,!0),t},e.each=function(e,t,n,r){return a(e,t,n,r,"each")},e.some=function(e,t,n,r){return a(e,t,n,r,"some")},e.clone=function(t,r,i,o,u,a){var f,l,c;if(!n.isObject(t)||e.instanceOf(t,YUI)||t.addEventListener||t.attachEvent)return t;l=a||{};switch(n.type(t)){case"date":return new Date(t);case"regexp":return t;case"function":return t;case"array":f=[];break;default:if(t[s])return l[t[s]];c=e.guid(),f=r?{}:e.Object(t),t[s]=c,l[c]=t}return e.each(t,function(n,a){(a||a===0)&&(!i||i.call(o||this,n,a,this,t)!==!1)&&a!==s&&a!="prototype"&&(this[a]=e.clone(n,r,i,o,u||t,l))},f),a||(e.Object.each(l,function(e,t){if(e[s])try{delete e[s]}catch(n){e[s]=null}},this),l=null),f},e.bind=function(t,r){var i=arguments.length>2?e.Array(arguments,2,!0):null;return function(){var s=n.isString(t)?r[t]:t,o=i?i.concat(e.Array(arguments,0,!0)):arguments;return s.apply(r||s,o)}},e.rbind=function(t,r){var i=arguments.length>2?e.Array(arguments,2,!0):null;return function(){var s=n.isString(t)?r[t]:t,o=i?e.Array(arguments,0,!0).concat(i):arguments;return s.apply(r||s,o)}}},"patched-v3.20.6",{requires:["yui-base"]});

/**
 * SPDX-FileCopyrightText: (c) 2000 Liferay, Inc. https://liferay.com
 * SPDX-License-Identifier: LGPL-2.1-or-later OR LicenseRef-Liferay-DXP-EULA-2.0.0-2023-06
 */

(function () {
	const A = AUI().use('oop');

	const usedModules = {};

	const Dependency = {
		_getAOP(object, methodName) {
			return object._yuiaop && object._yuiaop[methodName];
		},

		_proxy(object, methodName, methodFn, context, guid, modules, _A) {
			let args;

			const queue = Dependency._proxyLoaders[guid];

			Dependency._replaceMethod(object, methodName, methodFn, context);

			while ((args = queue.next())) {
				methodFn.apply(context, args);
			}

			for (let i = modules.length - 1; i >= 0; i--) {
				usedModules[modules[i]] = true;
			}
		},

		_proxyLoaders: {},

		_replaceMethod(object, methodName, methodFn) {
			const AOP = Dependency._getAOP(object, methodName);

			let proxy = object[methodName];

			if (AOP) {
				proxy = AOP.method;

				AOP.method = methodFn;
			}
			else {
				object[methodName] = methodFn;
			}

			A.mix(methodFn, proxy);
		},

		provide(object, methodName, methodFn, modules, proto) {
			if (!Array.isArray(modules)) {
				modules = [modules];
			}

			let before;

			const guid = A.guid();

			if (A.Lang.isObject(methodFn, true)) {
				const config = methodFn;

				methodFn = config.fn;
				before = config.before;

				if (!A.Lang.isFunction(before)) {
					before = null;
				}
			}

			if (proto && A.Lang.isFunction(object)) {
				object = object.prototype;
			}

			const AOP = Dependency._getAOP(object, methodName);

			if (AOP) {
				delete object._yuiaop[methodName];
			}

			const proxy = function () {
				const args = arguments;

				let context = object;

				if (proto) {
					context = this;
				}

				if (modules.length === 1) {
					if (modules[0] in usedModules) {
						Dependency._replaceMethod(
							object,
							methodName,
							methodFn,
							context
						);

						methodFn.apply(context, args);

						return;
					}
				}

				let firstLoad = false;

				let queue = Dependency._proxyLoaders[guid];

				if (!queue) {
					firstLoad = true;

					Dependency._proxyLoaders[guid] = new A.Queue();

					queue = Dependency._proxyLoaders[guid];
				}

				queue.add(args);

				if (firstLoad) {
					modules.push(
						A.bind(
							Dependency._proxy,
							Liferay,
							object,
							methodName,
							methodFn,
							context,
							guid,
							modules
						)
					);

					A.use.apply(A, modules);
				}
			};

			proxy.toString = function () {
				return methodFn.toString();
			};

			object[methodName] = proxy;
		},
	};

	Liferay.Dependency = Dependency;

	Liferay.provide = Dependency.provide;
})();

/* eslint-disable @liferay/aui/no-one */

/**
 * SPDX-FileCopyrightText: (c) 2000 Liferay, Inc. https://liferay.com
 * SPDX-License-Identifier: LGPL-2.1-or-later OR LicenseRef-Liferay-DXP-EULA-2.0.0-2023-06
 */

(function (A) {
	A.use('aui-base-lang');

	const Lang = A.Lang;

	const EVENT_CLICK = 'click';

	const SRC_HIDE_LINK = {
		src: 'hideLink',
	};

	const STR_RIGHT_SQUARE_BRACKET = ']';

	const Window = {
		_map: {},

		getById(id) {
			const instance = this;

			return instance._map[id];
		},
	};

	const Util = {
		_getEditableInstance(title) {
			let editable = Util._EDITABLE;

			if (!editable) {
				editable = new A.Editable({
					after: {
						contentTextChange(event) {
							const instance = this;

							if (!event.initial) {
								const title = instance.get('node');

								const portletTitleEditOptions = title.getData(
									'portletTitleEditOptions'
								);

								Util.savePortletTitle({
									doAsUserId:
										portletTitleEditOptions.doAsUserId,
									plid: portletTitleEditOptions.plid,
									portletId:
										portletTitleEditOptions.portletId,
									title: event.newVal,
								});
							}
						},
						startEditing() {
							const instance = this;

							const Layout = Liferay.Layout;

							if (Layout) {
								instance._dragListener =
									Layout.getLayoutHandler().on(
										'drag:start',
										() => {
											instance.fire('save');
										}
									);
							}

							const title = instance.get('node');

							instance._titleListener = title.on(
								'mouseupoutside',
								(event) => {
									const editable =
										Util._getEditableInstance(title);

									if (
										!editable
											.get('boundingBox')
											.contains(event.target)
									) {
										editable.save();
									}
								}
							);
						},
						stopEditing() {
							const instance = this;

							if (instance._dragListener) {
								instance._dragListener.detach();
							}

							if (instance._titleListener) {
								instance._titleListener.detach();
							}
						},
					},
					cssClass: 'lfr-portlet-title-editable',
					node: title,
				});

				editable.get('cancelButton').icon = 'times';
				editable.get('saveButton').icon = 'check';

				Util._EDITABLE = editable;
			}

			return editable;
		},

		/**
		 * @deprecated As of Cavanaugh (7.4.x), with no direct replacement
		 */
		addInputCancel() {
			A.use('aui-button-search-cancel', (A) => {
				new A.ButtonSearchCancel({
					trigger:
						'input[type=password], input[type=search], input.clearable, input.search-query',
				});
			});

			Util.addInputCancel = function () {};
		},

		checkAll(form, name, allBox, selectClassName) {
			if (form) {
				form = Util.getDOM(form);

				if (typeof form === 'string') {
					form = document.querySelector(form);
				}

				allBox = Util.getDOM(allBox);

				if (typeof allBox === 'string') {
					allBox = document.querySelector(allBox);
				}

				let selector;

				if (Array.isArray(name)) {
					selector =
						'input[name=' +
						name.join('], input[name=') +
						STR_RIGHT_SQUARE_BRACKET;
				}
				else {
					selector = 'input[name=' + name + STR_RIGHT_SQUARE_BRACKET;
				}

				const allBoxChecked = allBox.checked;

				const uploadedItems = Array.from(
					form.querySelectorAll(selector)
				);

				uploadedItems.forEach((item) => {
					if (!item.disabled) {
						item.checked = allBoxChecked;
					}
				});

				if (selectClassName) {
					const selectItem = form.querySelector(selectClassName);

					if (allBoxChecked) {
						selectItem.classList.add('info');
					}
					else {
						selectItem.classList.remove('info');
					}
				}
			}
		},

		checkAllBox(form, name, allBox) {
			let totalOn = 0;

			if (form) {
				form = Util.getDOM(form);

				if (typeof form === 'string') {
					form = document.querySelector(form);
				}

				allBox = Util.getDOM(allBox);

				if (typeof allBox === 'string') {
					allBox =
						document.querySelector(allBox) ||
						form.querySelector(`input[name="${allBox}"]`);
				}

				const inputs = Array.from(
					form.querySelectorAll('input[type=checkbox]')
				);

				if (!Array.isArray(name)) {
					name = [name];
				}

				let totalBoxes = 0;

				inputs.forEach((input) => {
					if (
						input.id !== allBox.id ||
						(input.id !== allBox.name &&
							name.indexOf(input.name) > -1)
					) {
						totalBoxes++;

						if (input.checked) {
							totalOn++;
						}
					}
				});

				allBox.checked = totalBoxes === totalOn;
			}

			return totalOn;
		},

		/**
		 * @deprecated As of Cavanaugh (7.4.x), with no direct replacement
		 */
		checkTab(box) {
			if (document.all && Number(window.event.keyCode) === 9) {
				box.selection = document.selection.createRange();

				setTimeout(() => {
					Util.processTab(box.id);
				}, 0);
			}
		},

		/**
		 * @deprecated As of Cavanaugh (7.4.x), with no direct replacement
		 */
		disableElements(element) {
			const currentElement = Util.getElement(element);

			if (currentElement) {
				const children = currentElement.getElementsByTagName('*');

				const emptyFnFalse = function () {
					return false;
				};

				for (let i = children.length - 1; i >= 0; i--) {
					const item = children[i];

					item.style.cursor = 'default';

					item.onclick = emptyFnFalse;
					item.onmouseover = emptyFnFalse;
					item.onmouseout = emptyFnFalse;
					item.onmouseenter = emptyFnFalse;
					item.onmouseleave = emptyFnFalse;

					item.action = '';
					item.disabled = true;
					item.href = 'javascript:void(0);';
					item.onsubmit = emptyFnFalse;
				}
			}
		},

		/**
		 * @deprecated As of Cavanaugh (7.4.x), with no direct replacement
		 */
		disableFormButtons(inputs, form) {
			inputs.attr('disabled', true);
			inputs.setStyle('opacity', 0.5);

			if (A.UA.gecko) {
				A.getWin().on('unload', () => {
					inputs.attr('disabled', false);
				});
			}
			else if (A.UA.safari) {
				A.use('node-event-html5', (A) => {
					A.getWin().on('pagehide', () => {
						Util.enableFormButtons(inputs, form);
					});
				});
			}
		},

		/**
		 * @deprecated As of Cavanaugh (7.4.x), replaced by `toggleDisabled`
		 */
		disableToggleBoxes(checkBoxId, toggleBoxId, checkDisabled) {
			const checkBox = document.getElementById(checkBoxId);
			const toggleBox = document.getElementById(toggleBoxId);

			if (checkBox && toggleBox) {
				toggleBox.disabled = checkDisabled && checkBox.checked;

				checkBox.addEventListener(EVENT_CLICK, () => {
					toggleBox.disabled = !toggleBox.disabled;
				});
			}
		},

		/**
		 * @deprecated As of Cavanaugh (7.4.x), with no direct replacement
		 */
		enableFormButtons(inputs) {
			Util._submitLocked = null;

			Util.toggleDisabled(inputs, false);
		},

		/**
		 * @deprecated As of Athanasius (7.3.x), with no direct replacement
		 */
		escapeCDATA(str) {
			return str.replace(/<!\[CDATA\[|\]\]>/gi, (match) => {
				let str = '';

				if (match === ']]>') {
					str = ']]&gt;';
				}
				else if (match === '<![CDATA[') {
					str = '&lt;![CDATA[';
				}

				return str;
			});
		},

		/**
		 * @deprecated As of Cavanaugh (7.4.x), with no direct replacement
		 */
		forcePost(link) {
			const currentElement = Util.getElement(link);

			if (currentElement) {
				const url = currentElement.getAttribute('href');

				// LPS-127302

				if (url === 'javascript:void(0);') {
					return;
				}

				const newWindow =
					currentElement.getAttribute('target') === '_blank';

				const hrefFm = document.hrefFm;

				if (newWindow) {
					hrefFm.setAttribute('target', '_blank');
				}

				submitForm(hrefFm, url, !newWindow);

				Util._submitLocked = null;
			}
		},

		/**
		 * @deprecated As of Cavanaugh (7.4.x), with no direct replacement
		 */
		getAttributes(element, attributeGetter) {
			let result = null;

			if (element) {
				element = Util.getDOM(element);

				if (element.jquery) {
					element = element[0];
				}

				result = {};

				const getterFn = typeof attributeGetter === 'function';
				const getterString = typeof attributeGetter === 'string';

				const attrs = element.attributes;
				let length = attrs.length;

				while (length--) {
					const attr = attrs[length];
					let name = attr.nodeName.toLowerCase();
					let value = attr.nodeValue;

					if (getterString) {
						if (name.indexOf(attributeGetter) === 0) {
							name = name.substr(attributeGetter.length);
						}
						else {
							continue;
						}
					}
					else if (getterFn) {
						value = attributeGetter(value, name, attrs);

						if (value === false) {
							continue;
						}
					}

					result[name] = value;
				}
			}

			return result;
		},

		/**
		 * @deprecated As of Cavanaugh (7.4.x), with no direct replacement
		 */
		getColumnId(str) {
			const columnId = str.replace(/layout-column_/, '');

			return columnId;
		},

		/**
		 * @deprecated As of Cavanaugh (7.4.x), replaced by `window.name`
		 */
		getWindowName() {
			return window.name || Window._name || '';
		},

		/**
		 * @deprecated As of Athanasius (7.3.x), replaced by `window.innerWidth`
		 */
		getWindowWidth() {
			return window.innerWidth;
		},

		/**
		 * @deprecated As of Athanasius (7.3.x), replaced by `typeof val === 'function'`
		 */
		isFunction(val) {
			return typeof val === 'function';
		},

		/**
		 * @deprecated As of Cavanaugh (7.4.x), replaced by `get_checkboxes.js`
		 */
		listCheckboxesExcept(form, except, name, checked) {
			form = Util.getDOM(form);

			if (typeof form === 'string') {
				form = document.querySelector(form);
			}

			let selector = 'input[type=checkbox]';

			if (name) {
				selector += '[name=' + name + ']';
			}

			const checkboxes = Array.from(form.querySelectorAll(selector));

			return checkboxes
				.reduce((prev, item) => {
					const value = item.value;

					if (
						value &&
						item.name !== except &&
						item.checked === checked &&
						!item.disabled
					) {
						prev.push(value);
					}

					return prev;
				}, [])
				.join();
		},

		/**
		 * @deprecated As of Cavanaugh (7.4.x), replaced by `import {getCheckedCheckboxes} from 'frontend-js-web';`
		 */
		listCheckedExcept(form, except, name) {
			return Util.listCheckboxesExcept(form, except, name, true);
		},

		/**
		 * @deprecated As of Cavanaugh (7.4.x), replaced by `import {getSelectedOptionValues} from 'frontend-js-web';`
		 */
		listSelect(select, delimiter) {
			select = Util.getElement(select);

			return Array.from(select.querySelectorAll('option'))
				.reduce((prev, item) => {
					const val = item.value;

					if (val) {
						prev.push(val);
					}

					return prev;
				}, [])
				.join(delimiter || ',');
		},

		/**
		 * @deprecated As of Cavanaugh (7.4.x), replaced by `import {getUncheckedCheckboxes} from 'frontend-js-web';`
		 */
		listUncheckedExcept(form, except, name) {
			return Util.listCheckboxesExcept(form, except, name, false);
		},

		/**
		 * @deprecated As of Cavanaugh (7.4.x), replaced by `Liferay.Util.openWindow()`
		 */
		openInDialog(event, config) {
			event.preventDefault();

			const currentTarget = Util.getElement(event.currentTarget);

			// eslint-disable-next-line prefer-object-spread
			config = Object.assign(
				{},

				// eslint-disable-next-line prefer-object-spread
				Object.assign({}, currentTarget.dataset),
				config
			);

			if (!config.uri) {
				config.uri =
					currentTarget.dataset.href ||
					currentTarget.getAttribute('href');
			}

			if (!config.title) {
				config.title = currentTarget.getAttribute('title');
			}

			Liferay.Util.openWindow(config);
		},

		/**
		 * @deprecated As of Cavanaugh (7.4.x), with no direct replacement
		 */
		processTab(id) {
			document.all[id].selection.text = String.fromCharCode(9);
			document.all[id].focus();
		},

		/**
		 * @deprecated As of Athanasius (7.3.x), with no direct replacement
		 */
		randomInt() {
			return Math.ceil(Math.random() * new Date().getTime());
		},

		/**
		 * @deprecated As of Cavanaugh (7.4.x), with no direct replacement
		 */
		reorder(box, down) {
			box = Util.getElement(box);

			if (box) {
				if (box.getAttribute('selectedIndex') === -1) {
					box.setAttribute('selectedIndex', 0);
				}
				else {
					const selectedItems = Array.from(
						box.querySelectorAll('option:checked')
					);

					const items = Array.from(box.querySelectorAll('option'));

					if (down) {
						selectedItems.reverse().forEach((item) => {
							const itemIndex = items.indexOf(item);

							const lastIndex = items.length - 1;

							if (itemIndex === lastIndex) {
								box.insertBefore(item, box.firstChild);
							}
							else {
								const nextItem =
									item.nextElementSibling.nextElementSibling;

								box.insertBefore(item, nextItem);
							}
						});
					}
					else {
						selectedItems.forEach((item) => {
							const itemIndex = items.indexOf(item);

							if (itemIndex === 0) {
								box.appendChild(item);
							}
							else {
								box.insertBefore(
									item,
									item.previousElementSibling
								);
							}
						});
					}
				}
			}
		},

		/**
		 * @deprecated As of Cavanaugh (7.4.x), with no direct replacement
		 */
		rowCheckerCheckAllBox(
			ancestorTable,
			ancestorRow,
			checkboxesIds,
			checkboxAllIds,
			cssClass
		) {
			Util.checkAllBox(ancestorTable, checkboxesIds, checkboxAllIds);

			if (ancestorRow) {
				ancestorRow.toggleClass(cssClass);
			}
		},

		/**
		 * @deprecated As of Cavanaugh (7.4.x), with no direct replacement
		 */
		savePortletTitle(params) {
			params = {
				doAsUserId: 0,
				plid: 0,
				portletId: 0,
				title: '',
				url:
					themeDisplay.getPathMain() + '/portal/update_portlet_title',
				...params,
			};

			const data = {
				doAsUserId: params.doAsUserId,
				p_auth: Liferay.authToken,
				p_l_id: params.plid,
				portletId: params.portletId,
				title: params.title,
			};

			Liferay.Util.fetch(params.url, {
				body: Liferay.Util.objectToFormData(data),
				method: 'POST',
			});
		},

		/**
		 * @deprecated As of Cavanaugh (7.4.x), replaced by {@link https://developer.mozilla.org/en-US/docs/Web/API/HTMLInputElement/setSelectionRange}
		 */
		setCursorPosition(element, position) {
			const instance = this;

			instance.setSelectionRange(element, position, position);
		},

		/**
		 * @deprecated As of Cavanaugh (7.4.x), replaced by {@link https://developer.mozilla.org/en-US/docs/Web/API/HTMLInputElement/setSelectionRange}
		 */
		setSelectionRange(element, selectionStart, selectionEnd) {
			element = Util.getDOM(element);

			if (element.jquery) {
				element = element[0];
			}

			if (element.setSelectionRange) {
				element.focus();

				element.setSelectionRange(selectionStart, selectionEnd);
			}
			else if (element.createTextRange) {
				const textRange = element.createTextRange();

				textRange.collapse(true);

				textRange.moveEnd('character', selectionEnd);
				textRange.moveEnd('character', selectionStart);

				textRange.select();
			}
		},

		/**
		 * @deprecated As of Athanasius (7.3.x), with no direct replacement
		 */
		sortByAscending(a, b) {
			a = a[1].toLowerCase();
			b = b[1].toLowerCase();

			if (a > b) {
				return 1;
			}

			if (a < b) {
				return -1;
			}

			return 0;
		},

		submitCountdown: 0,

		/**
		 * @deprecated As of Cavanaugh (7.4.x), replaced by `form.submit()`
		 */
		submitForm(form) {
			form.submit();
		},

		/**
		 * @deprecated As of Athanasius (7.3.x), replaced by `parseInt()`
		 */
		toNumber(value) {
			return parseInt(value, 10) || 0;
		},

		/**
		 * @deprecated As of Athanasius (7.3.x), with no direct replacement
		 */
		toggleSearchContainerButton(
			buttonId,
			searchContainerId,
			form,
			ignoreFieldName
		) {
			A.one(searchContainerId).delegate(
				EVENT_CLICK,
				() => {
					Util.toggleDisabled(
						buttonId,
						!Util.getCheckedCheckboxes(form, ignoreFieldName)
					);
				},
				'input[type=checkbox]'
			);
		},
	};

	Liferay.provide(
		Util,
		'afterIframeLoaded',
		(event) => {

			// eslint-disable-next-line @liferay/aui/no-node
			const nodeInstances = A.Node._instances;

			const docEl = event.doc;

			const docUID = docEl._yuid;

			if (docUID in nodeInstances) {
				delete nodeInstances[docUID];
			}

			const iframeDocument = A.one(docEl);

			const iframeBody = iframeDocument.one('body');

			const dialog = event.dialog;

			const lfrFormContent = iframeBody.one('.lfr-form-content');

			iframeBody.addClass('dialog-iframe-popup');

			if (
				lfrFormContent &&
				iframeBody.one('.button-holder.dialog-footer')
			) {
				iframeBody.addClass('dialog-with-footer');

				const stagingAlert = iframeBody.one(
					'.portlet-body > .lfr-portlet-message-staging-alert'
				);

				if (stagingAlert) {
					stagingAlert.remove();

					lfrFormContent.prepend(stagingAlert);
				}
			}

			iframeBody.addClass(dialog.iframeConfig.bodyCssClass);

			event.win.focus();

			const iframeWindow = event.win;

			if (iframeWindow.Liferay.SPA) {
				const beforeScreenFlipHandler = iframeWindow.Liferay.on(
					'beforeScreenFlip',
					() => {
						iframeWindow.document.body.classList.add(
							'dialog-iframe-popup'
						);
					}
				);

				iframeWindow.onunload = () => {
					if (beforeScreenFlipHandler) {
						iframeWindow.Liferay.detach(beforeScreenFlipHandler);
					}
				};
			}

			const cancelEventHandler = iframeBody.delegate(
				EVENT_CLICK,
				(event) => {
					dialog.set(
						'visible',
						false,
						event.currentTarget.hasClass('lfr-hide-dialog')
							? SRC_HIDE_LINK
							: null
					);

					cancelEventHandler.detach();

					iframeDocument.purge(true);
				},
				'.btn-cancel,.lfr-hide-dialog'
			);

			Liferay.fire('modalIframeLoaded', {
				src: event.dialog.iframe.node.getAttribute('src'),
			});
		},
		['aui-base']
	);

	/**
	 * @deprecated As of Cavanaugh (7.4.x), replaced by `openSelectionModal`
	 */
	Liferay.provide(
		Util,
		'openDDMPortlet',
		(config, callback) => {
			const defaultValues = {
				eventName: 'selectStructure',
			};

			// eslint-disable-next-line @liferay/aui/no-merge
			config = A.merge(defaultValues, config);

			const params = {
				classNameId: config.classNameId,
				classPK: config.classPK,
				doAsGroupId:
					config.doAsGroupId || themeDisplay.getScopeGroupId(),
				eventName: config.eventName,
				groupId: config.groupId,
				mvcPath: config.mvcPath || '/view.jsp',
				p_p_state: 'pop_up',
				portletResourceNamespace: config.portletResourceNamespace,
				resourceClassNameId: config.resourceClassNameId,
				scopeTitle: config.title,
				structureAvailableFields: config.structureAvailableFields,
				templateId: config.templateId,
			};

			if ('mode' in config) {
				params.mode = config.mode;
			}

			if ('navigationStartsOn' in config) {
				params.navigationStartsOn = config.navigationStartsOn;
			}

			if ('redirect' in config) {
				params.redirect = config.redirect;
			}

			if ('refererPortletName' in config) {
				params.refererPortletName = config.refererPortletName;
			}

			if ('refererWebDAVToken' in config) {
				params.refererWebDAVToken = config.refererWebDAVToken;
			}

			if ('searchRestriction' in config) {
				params.searchRestriction = config.searchRestriction;
				params.searchRestrictionClassNameId =
					config.searchRestrictionClassNameId;
				params.searchRestrictionClassPK =
					config.searchRestrictionClassPK;
			}

			if ('showAncestorScopes' in config) {
				params.showAncestorScopes = config.showAncestorScopes;
			}

			if ('showBackURL' in config) {
				params.showBackURL = config.showBackURL;
			}

			if ('showCacheableInput' in config) {
				params.showCacheableInput = config.showCacheableInput;
			}

			if ('showHeader' in config) {
				params.showHeader = config.showHeader;
			}

			if ('showManageTemplates' in config) {
				params.showManageTemplates = config.showManageTemplates;
			}

			const url = Liferay.Util.PortletURL.createRenderURL(
				config.basePortletURL,
				params
			);

			config.uri = url.toString();

			let dialogConfig = config.dialog;

			if (!dialogConfig) {
				dialogConfig = {};

				config.dialog = dialogConfig;
			}

			const eventHandles = [];

			if (callback) {
				eventHandles.push(Liferay.once(config.eventName, callback));
			}

			const detachSelectionOnHideFn = function (event) {
				Liferay.fire(config.eventName);

				if (!event.newVal) {
					new A.EventHandle(eventHandles).detach();
				}
			};

			Util.openWindow(config, (dialogWindow) => {
				eventHandles.push(
					dialogWindow.after(
						['destroy', 'visibleChange'],
						detachSelectionOnHideFn
					)
				);
			});
		},
		['aui-base']
	);

	Liferay.provide(
		Util,
		'openDocument',
		(webDavUrl, onSuccess, onError) => {
			if (A.UA.ie) {
				try {
					const executor = new A.config.win.ActiveXObject(
						'SharePoint.OpenDocuments'
					);

					executor.EditDocument(webDavUrl);

					if (Lang.isFunction(onSuccess)) {
						onSuccess();
					}
				}
				catch (error) {
					if (Lang.isFunction(onError)) {
						onError(error);
					}
				}
			}
		},
		['aui-base']
	);

	/**
	 * @deprecated As of Cavanaugh (7.4.x), with no direct replacement
	 */
	Liferay.provide(
		Util,
		'selectEntityHandler',
		(containerSelector, selectEventName, disableButton) => {
			const container = A.one(containerSelector);

			if (!container) {
				return;
			}

			const openingLiferay = Util.getOpener().Liferay;

			const selectorButtons = container
				.getDOM()
				.querySelectorAll('.selector-button');

			container.delegate(
				EVENT_CLICK,
				(event) => {
					const currentTarget = event.currentTarget.getDOM();

					if (
						currentTarget.disabled ||
						currentTarget.dataset['preventSelection']
					) {
						return;
					}

					const doSelect = () => {
						if (disableButton) {
							selectorButtons.forEach((selectorButton) => {
								selectorButton.disabled = false;
							});

							currentTarget.disabled = true;
						}

						const result = Util.getAttributes(
							currentTarget,
							'data-'
						);

						openingLiferay.fire(selectEventName, result);

						const window = Util.getWindow();

						if (window) {
							window.hide();
						}
					};

					const confirmSelection =
						currentTarget.dataset['confirmSelection'] === 'true';

					if (!confirmSelection) {
						doSelect();
					}
					else {
						Liferay.Util.openConfirmModal({
							message:
								currentTarget.dataset[
									'confirmSelectionMessage'
								],
							onConfirm: (isConfirmed) => {
								if (isConfirmed) {
									if (disableButton) {
										selectorButtons.forEach(
											(selectorButton) => {
												selectorButton.disabled = false;
											}
										);

										currentTarget.disabled = true;
									}

									const result = Util.getAttributes(
										currentTarget,
										'data-'
									);

									openingLiferay.fire(
										selectEventName,
										result
									);

									const window = Util.getWindow();

									if (window) {
										window.hide();
									}
								}
							},
						});
					}
				},
				'.selector-button'
			);

			openingLiferay.on('entitySelectionRemoved', () => {
				selectorButtons.forEach((selectorButton) => {
					selectorButton.disabled = false;
				});
			});
		},
		['aui-base']
	);

	Liferay.provide(
		Util,
		'portletTitleEdit',
		(options) => {
			const object = options.obj;

			A.Event.defineOutside('mouseup');

			if (object) {
				const title = object.one('.portlet-title-text');

				if (title && !title.hasClass('not-editable')) {
					title.addClass('portlet-title-editable');

					title.on(EVENT_CLICK, (event) => {
						const editable = Util._getEditableInstance(title);

						const rendered = editable.get('rendered');

						if (rendered) {
							editable.fire('stopEditing');
						}

						editable.set('node', event.currentTarget);

						if (rendered) {
							editable.syncUI();
						}

						editable._startEditing(event);

						if (!rendered) {
							const defaultIconsTpl =
								A.ToolbarRenderer.prototype.TEMPLATES.icon;

							A.ToolbarRenderer.prototype.TEMPLATES.icon =
								Liferay.Util.getLexiconIconTpl('{cssClass}');

							editable._comboBox.icons.destroy();
							editable._comboBox._renderIcons();

							A.ToolbarRenderer.prototype.TEMPLATES.icon =
								defaultIconsTpl;
						}
					});

					title.setData('portletTitleEditOptions', options);
				}
			}
		},
		['aui-editable-deprecated', 'event-outside']
	);

	Liferay.provide(
		Util,
		'editEntity',
		(config, callback) => {
			const dialog = Util.getWindow(config.id);

			const eventName = config.eventName || config.id;

			const eventHandles = [Liferay.on(eventName, callback)];

			const detachSelectionOnHideFn = function (event) {
				if (!event.newVal) {
					new A.EventHandle(eventHandles).detach();
				}
			};

			if (dialog) {
				eventHandles.push(
					dialog.after(
						['destroy', 'visibleChange'],
						detachSelectionOnHideFn
					)
				);

				dialog.show();
			}
			else {
				const destroyDialog = function (event) {
					const dialogId = config.id;

					const dialogWindow = Util.getWindow(dialogId);

					if (
						dialogWindow &&
						Util.getPortletId(dialogId) === event.portletId
					) {
						dialogWindow.destroy();

						Liferay.detach('destroyPortlet', destroyDialog);
					}
				};

				const editURL = new Liferay.Util.PortletURL.createPortletURL(
					config.uri,

					// eslint-disable-next-line @liferay/aui/no-merge
					A.merge(
						{
							eventName,
						},
						config.urlParams
					)
				);

				config.uri = editURL.toString();

				// eslint-disable-next-line @liferay/aui/no-merge
				config.dialogIframe = A.merge(
					{
						bodyCssClass: 'dialog-with-footer',
					},
					config.dialogIframe || {}
				);

				Util.openWindow(config, (dialogWindow) => {
					eventHandles.push(
						dialogWindow.after(
							['destroy', 'visibleChange'],
							detachSelectionOnHideFn
						)
					);

					Liferay.on('destroyPortlet', destroyDialog);
				});
			}
		},
		['aui-base', 'liferay-util-window']
	);

	/**
	 * Used in `modules/apps/frontend-js/frontend-js-web/src/main/resources/META-INF/resources/liferay/util/open_window.js`
	 * which will need to be migrated over to `openModal`.
	 */
	Liferay.provide(
		Util,
		'_openWindowProvider',
		(config, callback) => {
			const dialog = Window.getWindow(config);

			if (Lang.isFunction(callback)) {
				callback(dialog);
			}
		},
		['liferay-util-window']
	);

	Util.Window = Window;

	Liferay.Util = Util;

	// 0-200: Theme Developer
	// 200-400: Portlet Developer
	// 400+: Liferay

})(AUI());

/**
 * SPDX-FileCopyrightText: (c) 2000 Liferay, Inc. https://liferay.com
 * SPDX-License-Identifier: LGPL-2.1-or-later OR LicenseRef-Liferay-DXP-EULA-2.0.0-2023-06
 */

(function (A) {
	const CLICK_EVENTS = {};
	const Util = Liferay.Util;

	A.use('attribute', 'oop', (A) => {
		A.augment(Liferay, A.Attribute, true);
	});

	Liferay.provide(
		Liferay,
		'delegateClick',
		(id, fn) => {
			const element = A.config.doc.getElementById(id);

			if (!element || element.id !== id) {
				return;
			}

			// eslint-disable-next-line @liferay/aui/no-one
			const guid = A.one(element).addClass('lfr-delegate-click').guid();

			CLICK_EVENTS[guid] = fn;

			if (!Liferay._baseDelegateHandle) {

				// eslint-disable-next-line @liferay/aui/no-get-body
				Liferay._baseDelegateHandle = A.getBody().delegate(
					'click',
					Liferay._baseDelegate,
					'.lfr-delegate-click'
				);
			}
		},
		['aui-base']
	);

	Liferay._baseDelegate = function (event) {
		const id = event.currentTarget.attr('id');

		const fn = CLICK_EVENTS[id];

		if (fn) {
			fn.apply(this, arguments);
		}
	};

	Liferay._CLICK_EVENTS = CLICK_EVENTS;

	Liferay.provide(
		window,
		'submitForm',
		(form, action, singleSubmit, validate) => {
			if (!Util._submitLocked) {
				if (form.jquery) {
					form = form[0];
				}

				Liferay.fire('submitForm', {
					action,

					// eslint-disable-next-line @liferay/aui/no-one
					form: A.one(form),
					singleSubmit,
					validate: validate !== false,
				});
			}
		},
		['aui-base', 'aui-form-validator', 'aui-url', 'liferay-form']
	);

	Liferay.publish('submitForm', {
		defaultFn(event) {
			const form = event.form;

			let hasErrors = false;

			if (event.validate) {
				const liferayForm = Liferay.Form.get(form.attr('id'));

				if (liferayForm) {
					const validator = liferayForm.formValidator;

					if (A.instanceOf(validator, A.FormValidator)) {
						validator.validate();

						hasErrors = validator.hasErrors();

						if (hasErrors) {
							validator.focusInvalidField();
						}
					}
				}
			}

			function enableFormButtons(inputs) {
				Util._submitLocked = null;

				Util.toggleDisabled(inputs, false);
			}

			if (!hasErrors) {
				let action = event.action || form.getAttribute('action');

				const singleSubmit = event.singleSubmit;

				const inputs = form.all(
					'button[type=submit], input[type=button], input[type=image], input[type=reset], input[type=submit]'
				);

				const inputsArray = Array.from(inputs._nodes);

				if (inputsArray.length) {
					inputsArray.map((input) => {
						input.disabled = true;
						input.style.opacity = 0.5;
					});
				}

				if (singleSubmit === false) {
					Util._submitLocked = A.later(
						1000,
						Util,
						enableFormButtons,
						[inputs, form]
					);
				}
				else {
					Util._submitLocked = true;
				}

				let baseURL;
				let queryString;
				const searchParamsIndex = action.indexOf('?');

				if (searchParamsIndex === -1) {
					baseURL = action;
					queryString = '';
				}
				else {
					baseURL = action.slice(0, searchParamsIndex);
					queryString = action.slice(searchParamsIndex + 1);
				}

				const searchParams = new URLSearchParams(queryString);

				let authToken = searchParams.get('p_auth') || '';

				if (authToken.includes('#')) {
					authToken = authToken.substring(0, authToken.indexOf('#'));
				}

				if (authToken) {
					form.append(
						'<input name="p_auth" type="hidden" value="' +
							authToken +
							'" />'
					);

					searchParams.delete('p_auth');

					action = baseURL + '?' + searchParams.toString();
				}

				form.attr('action', action);

				Util.submitForm(form);

				form.attr('target', '');

				Util._submitLocked = null;
			}
		},
	});

	Liferay.after('closeWindow', (event) => {
		const id = event.id;

		const dialog = Util.getTop().Liferay.Util.Window.getById(id);

		if (dialog && dialog.iframe) {
			const dialogWindow = dialog.iframe.node
				.get('contentWindow')
				.getDOM();

			const openingWindow = dialogWindow.Liferay.Util.getOpener();
			const redirect = event.redirect;

			if (redirect) {
				openingWindow.Liferay.Util.navigate(redirect);
			}
			else {
				const refresh = event.refresh;

				if (refresh && openingWindow) {
					let data;

					if (!event.portletAjaxable) {
						data = {
							portletAjaxable: false,
						};
					}

					openingWindow.Liferay.Portlet.refresh(
						'#p_p_id_' + refresh + '_',
						data
					);
				}
			}

			dialog.hide();
		}
	});
})(AUI());

/**
 * SPDX-FileCopyrightText: (c) 2000 Liferay, Inc. https://liferay.com
 * SPDX-License-Identifier: LGPL-2.1-or-later OR LicenseRef-Liferay-DXP-EULA-2.0.0-2023-06
 */

(function () {
	Liferay.lazyLoad = function () {
		let failureCallback;

		const isFunction = function (val) {
			return typeof val === 'function';
		};

		let modules;
		let successCallback;

		if (Array.isArray(arguments[0])) {
			modules = arguments[0];

			successCallback = isFunction(arguments[1]) ? arguments[1] : null;
			failureCallback = isFunction(arguments[2]) ? arguments[2] : null;
		}
		else {
			modules = [];

			for (let i = 0; i < arguments.length; ++i) {
				if (typeof arguments[i] === 'string') {
					modules[i] = arguments[i];
				}
				else if (isFunction(arguments[i])) {
					successCallback = arguments[i];
					failureCallback = isFunction(arguments[++i])
						? arguments[i]
						: null;
					break;
				}
			}
		}

		return function () {
			const args = [];

			for (let i = 0; i < arguments.length; ++i) {
				args.push(arguments[i]);
			}

			Liferay.Loader.require(
				modules,
				function () {
					for (let i = 0; i < arguments.length; ++i) {
						args.splice(i, 0, arguments[i]);
					}

					successCallback.apply(successCallback, args);
				},
				failureCallback
			);
		};
	};
})();

/**
 * SPDX-FileCopyrightText: (c) 2000 Liferay, Inc. https://liferay.com
 * SPDX-License-Identifier: LGPL-2.1-or-later OR LicenseRef-Liferay-DXP-EULA-2.0.0-2023-06
 */

Liferay = window.Liferay || {};

(function () {
	const isFunction = function (val) {
		return typeof val === 'function';
	};

	const isNode = function (node) {
		return node && (node._node || node.jquery || node.nodeType);
	};

	const REGEX_METHOD_GET = /^get$/i;

	const STR_MULTIPART = 'multipart/form-data';

	Liferay.namespace = function namespace(object, path) {
		if (path === undefined) {
			path = object;

			object = this;
		}

		const parts = path.split('.');

		for (let part; parts.length && (part = parts.shift()); ) {
			if (object[part] && object[part] !== Object.prototype[part]) {
				object = object[part];
			}
			else {
				object = object[part] = {};
			}
		}

		return object;
	};

	/**
	 * OPTIONS
	 *
	 * Required
	 * service {string|object}: Either the service name, or an object with the keys as the service to call, and the value as the service configuration object.
	 *
	 * Optional
	 * data {object|node|string}: The data to send to the service. If the object passed is the ID of a form or a form element, the form fields will be serialized and used as the data.
	 * successCallback {function}: A function to execute when the server returns a response. It receives a JSON object as it's first parameter.
	 * exceptionCallback {function}: A function to execute when the response from the server contains a service exception. It receives a the exception message as it's first parameter.
	 */

	const Service = function () {
		const args = Service.parseInvokeArgs(
			Array.prototype.slice.call(arguments, 0)
		);

		return Service.invoke.apply(Service, args);
	};

	Service.URL_INVOKE = themeDisplay.getPathContext() + '/api/jsonws/invoke';

	Service.bind = function () {
		const args = Array.prototype.slice.call(arguments, 0);

		return function () {
			const newArgs = Array.prototype.slice.call(arguments, 0);

			return Service.apply(Service, args.concat(newArgs));
		};
	};

	Service.parseInvokeArgs = function (args) {
		const instance = this;

		let payload = args[0];

		const ioConfig = instance.parseIOConfig(args);

		if (typeof payload === 'string') {
			payload = instance.parseStringPayload(args);

			instance.parseIOFormConfig(ioConfig, args);

			const lastArg = args[args.length - 1];

			if (typeof lastArg === 'object' && lastArg.method) {
				ioConfig.method = lastArg.method;
			}
		}

		return [payload, ioConfig];
	};

	Service.parseIOConfig = function (args) {
		const payload = args[0];

		const ioConfig = payload.io || {};

		delete payload.io;

		if (!ioConfig.success) {
			const callbacks = args.filter(isFunction);

			let callbackException = callbacks[1];
			const callbackSuccess = callbacks[0];

			if (!callbackException) {
				callbackException = callbackSuccess;
			}

			ioConfig.error = callbackException;

			ioConfig.complete = function (response) {
				if (
					!Object.prototype.hasOwnProperty.call(response, 'exception')
				) {
					if (callbackSuccess) {
						callbackSuccess.call(this, response);
					}
				}
				else if (callbackException) {
					const exception = response
						? response.exception
						: 'The server returned an empty response';

					callbackException.call(this, exception, response);
				}
			};
		}

		if (
			!Object.prototype.hasOwnProperty.call(ioConfig, 'cache') &&
			REGEX_METHOD_GET.test(ioConfig.type)
		) {
			ioConfig.cache = false;
		}

		return ioConfig;
	};

	Service.parseIOFormConfig = function (ioConfig, args) {
		const form = args[1];

		if (isNode(form)) {
			if (form.enctype === STR_MULTIPART) {
				ioConfig.contentType = 'multipart/form-data';
			}

			ioConfig.formData = new FormData(form);
		}
	};

	Service.parseStringPayload = function (args) {
		let params = {};
		const payload = {};

		const config = args[1];

		if (!isFunction(config) && !isNode(config)) {
			params = config;
		}

		payload[args[0]] = params;

		return payload;
	};

	Service.invoke = function (payload, ioConfig) {
		const instance = this;

		const cmd = JSON.stringify(payload);

		let data = cmd;

		if (ioConfig.formData) {
			ioConfig.formData.append('cmd', cmd);
			data = ioConfig.formData;
		}

		return Liferay.Util.fetch(instance.URL_INVOKE, {
			body: data,
			headers: {
				contentType: ioConfig.contentType,
			},
			method: 'POST',
		})
			.then((response) =>
				Promise.all([Promise.resolve(response), response.json()])
			)
			.then(([response, content]) => {
				if (response.ok) {
					ioConfig.complete(content);
				}
				else {
					ioConfig.error();
				}
			})
			.catch(ioConfig.error);
	};

	function getHttpMethodFunction(httpMethodName) {
		return function () {
			const args = Array.prototype.slice.call(arguments, 0);

			const method = {method: httpMethodName};

			args.push(method);

			return Service.apply(Service, args);
		};
	}

	Service.get = getHttpMethodFunction('get');
	Service.del = getHttpMethodFunction('delete');
	Service.post = getHttpMethodFunction('post');
	Service.put = getHttpMethodFunction('put');
	Service.update = getHttpMethodFunction('update');

	Liferay.Service = Service;

	Liferay.Template = {
		PORTLET:
			'<div class="portlet"><div class="portlet-topper"><div class="portlet-title"></div></div><div class="portlet-content"></div><div class="forbidden-action"></div></div>',
	};
})();

/**
 * SPDX-FileCopyrightText: (c) 2000 Liferay, Inc. https://liferay.com
 * SPDX-License-Identifier: LGPL-2.1-or-later OR LicenseRef-Liferay-DXP-EULA-2.0.0-2023-06
 */

/* eslint-disable @liferay/aui/no-node */

/* eslint-disable @liferay/aui/no-one */

(function (A) {
	const Lang = A.Lang;

	const Util = Liferay.Util;

	const STR_HEAD = 'head';

	const TPL_NOT_AJAXABLE = '<div class="alert alert-info">{0}</div>';

	const Portlet = {
		...Liferay.Portlet,

		_defCloseFn(event) {
			event.portlet.remove(true);

			if (!event.nestedPortlet) {
				const formData = Liferay.Util.objectToFormData({
					cmd: 'delete',
					doAsUserId: event.doAsUserId,
					p_auth: Liferay.authToken,
					p_l_id: event.plid,
					p_p_id: event.portletId,
					p_v_l_s_g_id: themeDisplay.getSiteGroupId(),
				});

				Liferay.Util.fetch(
					themeDisplay.getPathMain() + '/portal/update_layout',
					{
						body: formData,
						method: 'POST',
					}
				).then((response) => {
					if (response.ok) {
						Liferay.fire('updatedLayout');
					}
				});
			}
		},

		_loadMarkupHeadElements(response) {
			const markupHeadElements = response.markupHeadElements;

			if (markupHeadElements && markupHeadElements.length) {
				const head = A.one(STR_HEAD);

				head.append(markupHeadElements);

				const container = A.Node.create('<div />');

				container.plug(A.Plugin.ParseContent);

				container.setContent(markupHeadElements);
			}
		},

		_loadModules(moduleJavascriptPaths) {
			return Promise.all(
				moduleJavascriptPaths.map(
					(path) =>
						new Promise((resolve) => {
							const script = document.createElement('script');

							script.src = path;
							script.type = 'module';

							script.onload = script.onreadystatechange = () => {
								if (
									this.readyState &&
									this.readyState !== 'complete' &&
									this.readyState !== 'load'
								) {
									return;
								}

								script.onload = script.onreadystatechange =
									null;
								script.onerror = null;

								resolve();
							};

							script.onerror = () => {
								script.onload = script.onreadystatechange =
									null;
								script.onerror = null;

								console.error('Unable to load', path);

								resolve();
							};

							document.head.appendChild(script);
						})
				)
			);
		},

		_loadPortletFiles(response, loadHTML) {
			const footerCssPaths = response.footerCssPaths || [];
			const headerCssPaths = response.headerCssPaths || [];

			const head = A.one(STR_HEAD);

			if (headerCssPaths.length) {
				A.Get.css(headerCssPaths, {
					insertBefore: head.get('firstChild').getDOM(),
				});
			}

			const lastChild = document.body.lastChild;

			if (footerCssPaths.length) {
				A.Get.css(footerCssPaths, {
					insertBefore: lastChild,
				});
			}

			const responseHTML = response.portletHTML;

			let javascriptPaths = response.headerJavaScriptPaths || [];

			javascriptPaths = javascriptPaths.concat(
				response.footerJavaScriptPaths || []
			);

			if (javascriptPaths.length) {
				const moduleJavascriptPaths = javascriptPaths
					.filter((path) => path.startsWith('module:'))
					.map((path) => path.substring(7));

				javascriptPaths = javascriptPaths.filter(
					(path) => !path.startsWith('module:')
				);

				Portlet._loadModules(moduleJavascriptPaths).then(() => {
					A.Get.script(javascriptPaths, {
						onEnd() {
							loadHTML(responseHTML);
						},
					});
				});
			}
			else {
				loadHTML(responseHTML);
			}
		},

		_mergeOptions(portlet, options) {
			options = options || {};

			options.doAsUserId =
				options.doAsUserId || themeDisplay.getDoAsUserIdEncoded();
			options.plid = options.plid || themeDisplay.getPlid();
			options.portlet = portlet;
			options.portletId = portlet.portletId;

			return options;
		},

		_staticPortlets: {},

		destroyComponents(portletId) {
			Liferay.destroyComponents((_component, componentConfig) => {
				return portletId === componentConfig.portletId;
			});
		},

		isStatic(portletId) {
			const instance = this;

			const id = Util.getPortletId(portletId.id || portletId);

			return id in instance._staticPortlets;
		},

		list: [],

		readyCounter: 0,

		refreshLayout(_portletBoundary) {},

		register(portletId) {
			const instance = this;

			if (instance.list.indexOf(portletId) < 0) {
				instance.list.push(portletId);
			}
		},
	};

	Liferay.provide(
		Portlet,
		'add',
		function (options) {
			const instance = this;

			Liferay.fire('initLayout');

			const doAsUserId =
				options.doAsUserId || themeDisplay.getDoAsUserIdEncoded();
			const plid = options.plid || themeDisplay.getPlid();
			const portletData = options.portletData;
			const portletId = options.portletId;
			const portletItemId = options.portletItemId;

			let placeHolder = options.placeHolder;

			if (!placeHolder) {
				placeHolder = A.Node.create(
					'<div class="loading-animation" />'
				);
			}
			else {
				placeHolder = A.one(placeHolder);
			}

			const beforePortletLoaded = options.beforePortletLoaded;
			const onCompleteFn = options.onComplete;

			const onComplete = function (portlet, portletId) {
				if (onCompleteFn) {
					onCompleteFn(portlet, portletId);
				}

				instance.list.push(portlet.portletId);

				if (portlet) {
					portlet.attr('data-qa-id', 'app-loaded');
				}

				Liferay.fire('addPortlet', {
					portlet,
				});
			};

			let container = null;

			if (Liferay.Layout && Liferay.Layout.INITIALIZED) {
				container = Liferay.Layout.getActiveDropContainer();
			}

			if (!container) {
				return;
			}

			const containerId = container.attr('id');

			let currentColumnId = containerId.replace(/layout-column_/, '');

			let portletPosition = 0;

			if (options.placeHolder) {
				const column = placeHolder.get('parentNode');

				if (!column) {
					return;
				}

				placeHolder.addClass('portlet-boundary');

				const columnPortlets = column.all('.portlet-boundary');
				const nestedPortlets = column.all('.portlet-nested-portlets');

				portletPosition = columnPortlets.indexOf(placeHolder);

				let nestedPortletOffset = 0;

				nestedPortlets.some((nestedPortlet) => {
					const nestedPortletIndex =
						columnPortlets.indexOf(nestedPortlet);

					if (
						nestedPortletIndex !== -1 &&
						nestedPortletIndex < portletPosition
					) {
						nestedPortletOffset += nestedPortlet
							.all('.portlet-boundary')
							.size();
					}
					else if (nestedPortletIndex >= portletPosition) {
						return true;
					}
				});

				portletPosition -= nestedPortletOffset;

				currentColumnId = Util.getColumnId(column.attr('id'));
			}

			const url = themeDisplay.getPathMain() + '/portal/update_layout';

			const data = {
				cmd: 'add',
				dataType: 'JSON',
				doAsUserId,
				p_auth: Liferay.authToken,
				p_l_id: plid,
				p_p_col_id: currentColumnId,
				p_p_col_pos: portletPosition,
				p_p_i_id: portletItemId,
				p_p_id: portletId,
				p_p_isolated: true,
				p_v_l_s_g_id: themeDisplay.getSiteGroupId(),
				portletData,
			};

			const firstPortlet = container.one('.portlet-boundary');
			const hasStaticPortlet = firstPortlet && firstPortlet.isStatic;

			if (!options.placeHolder && !options.plid) {
				if (!hasStaticPortlet) {
					container.prepend(placeHolder);
				}
				else {
					firstPortlet.placeAfter(placeHolder);
				}
			}

			data.currentURL = Liferay.currentURL;

			instance.addHTML({
				beforePortletLoaded,
				data,
				onComplete,
				placeHolder,
				url,
			});
		},
		['aui-base']
	);

	Liferay.provide(
		Portlet,
		'addHTML',
		function (options) {
			const instance = this;

			let portletBoundary = null;

			const beforePortletLoaded = options.beforePortletLoaded;
			const data = options.data;
			let dataType = 'HTML';
			const onComplete = options.onComplete;
			const placeHolder = options.placeHolder;
			const url = options.url;

			if (data && Lang.isString(data.dataType)) {
				dataType = data.dataType;
			}

			dataType = dataType.toUpperCase();

			const addPortletReturn = function (html) {
				const container = placeHolder.get('parentNode');

				let portletBound = A.Node.create('<div></div>');

				portletBound.plug(A.Plugin.ParseContent);

				portletBound.setContent(html);

				portletBound = portletBound.one('> *');

				let portletId;

				if (portletBound) {
					const id = portletBound.attr('id');

					portletId = Util.getPortletId(id);

					portletBound.portletId = portletId;

					placeHolder.hide();
					placeHolder.placeAfter(portletBound);

					placeHolder.remove();

					instance.refreshLayout(portletBound);

					if (window.location.hash) {
						window.location.href = encodeURI(window.location.hash);
					}

					portletBoundary = portletBound;

					const Layout = Liferay.Layout;

					if (Layout && Layout.INITIALIZED) {
						Layout.updateCurrentPortletInfo(portletBoundary);

						if (container) {
							Layout.syncEmptyColumnClassUI(container);
						}

						Layout.syncDraggableClassUI();
						Layout.updatePortletDropZones(portletBoundary);
					}

					if (onComplete) {
						onComplete(portletBoundary, portletId);
					}
				}
				else {
					placeHolder.remove();
				}

				return portletId;
			};

			if (beforePortletLoaded) {
				beforePortletLoaded(placeHolder);
			}

			Liferay.Util.fetch(url, {
				body: Liferay.Util.objectToURLSearchParams(data),
				method: 'POST',
			})
				.then((response) => {
					if (dataType === 'JSON') {
						return response.json();
					}
					else {
						return response.text();
					}
				})
				.then((response) => {
					if (dataType === 'HTML') {
						addPortletReturn(response);
					}
					else if (response.refresh) {
						addPortletReturn(response.portletHTML);
					}
					else {
						Portlet._loadMarkupHeadElements(response);
						Portlet._loadPortletFiles(response, addPortletReturn);
					}

					if (!data || !data.preventNotification) {
						Liferay.fire('updatedLayout');
					}
				})
				.catch((error) => {
					const message =
						typeof error === 'string'
							? error
							: 'There\x20was\x20an\x20unexpected\x20error\x2e\x20Please\x20refresh\x20the\x20current\x20page\x2e';

					Liferay.Util.openToast({
						message,
						type: 'danger',
					});
				});
		},
		['aui-parse-content']
	);

	Liferay.provide(
		Portlet,
		'close',
		function (portlet, skipConfirm, options) {
			const instance = this;

			const _removeComponent = () => {
				const portletId = portlet.portletId;

				const portletIndex = instance.list.indexOf(portletId);

				if (portletIndex >= 0) {
					instance.list.splice(portletIndex, 1);
				}

				options = Portlet._mergeOptions(portlet, options);

				Portlet.destroyComponents(portletId);

				Liferay.fire('destroyPortlet', options);

				Liferay.fire('closePortlet', options);
			};

			portlet = A.one(portlet);

			if (portlet) {
				if (!skipConfirm) {
					Liferay.Util.openConfirmModal({
						message: 'Are\x20you\x20sure\x20you\x20want\x20to\x20remove\x20this\x20component\x3f',
						onConfirm: (isConfirmed) => {
							if (isConfirmed) {
								_removeComponent();
							}
						},
					});
				}
				else {
					_removeComponent();
				}
			}
			else {
				A.config.win.focus();
			}
		},
		[]
	);

	Liferay.provide(
		Portlet,
		'destroy',
		(portlet, options) => {
			portlet = A.one(portlet);

			if (portlet) {
				const portletId =
					portlet.portletId || Util.getPortletId(portlet.attr('id'));

				Portlet.destroyComponents(portletId);

				Liferay.fire(
					'destroyPortlet',
					Portlet._mergeOptions(portlet, options)
				);
			}
		},
		['aui-node-base']
	);

	Liferay.provide(
		Portlet,
		'onLoad',
		function (options) {
			const instance = this;

			const canEditTitle = options.canEditTitle;
			const columnPos = options.columnPos;
			const isStatic =
				options.isStatic === 'no' ? null : options.isStatic;
			const namespacedId = options.namespacedId;
			const portletId = options.portletId;
			const refreshURL = options.refreshURL;
			const refreshURLData = options.refreshURLData;

			if (isStatic) {
				instance.registerStatic(portletId);
			}

			const portlet = A.one('#' + namespacedId);

			if (portlet && !portlet.portletProcessed) {
				portlet.portletProcessed = true;
				portlet.portletId = portletId;
				portlet.columnPos = columnPos;
				portlet.isStatic = isStatic;
				portlet.refreshURL = refreshURL;
				portlet.refreshURLData = refreshURLData;

				// Functions to run on portlet load

				if (canEditTitle) {

					// https://github.com/yui/yui3/issues/1808

					let events = 'focus';

					if (!A.UA.touchEnabled) {
						events = ['focus', 'mousemove'];
					}

					const handle = portlet.on(events, () => {
						Util.portletTitleEdit({
							doAsUserId: themeDisplay.getDoAsUserIdEncoded(),

							// eslint-disable-next-line @liferay/no-abbreviations
							obj: portlet,
							plid: themeDisplay.getPlid(),
							portletId,
						});

						handle.detach();
					});
				}
			}

			Liferay.fire('portletReady', {
				portlet,
				portletId,
			});

			instance.readyCounter++;

			if (instance.readyCounter === instance.list.length) {
				Liferay.fire('allPortletsReady', {
					portletId,
				});
			}
		},
		['aui-base', 'aui-timer', 'event-move']
	);

	Liferay.provide(
		Portlet,
		'refresh',
		function (portlet, data, mergeWithRefreshURLData) {
			const instance = this;

			portlet = A.one(portlet);

			if (portlet) {
				if (mergeWithRefreshURLData) {
					data = {
						...(portlet.refreshURLData || {}),
						...(data || {}),
					};
				}
				else {
					data = data || portlet.refreshURLData || {};
				}

				if (
					!Object.prototype.hasOwnProperty.call(
						data,
						'portletAjaxable'
					)
				) {
					data.portletAjaxable = true;
				}

				const id = portlet.attr('portlet');

				let url = portlet.refreshURL;

				const placeHolder = A.Node.create(
					'<div class="loading-animation" id="p_p_id' + id + '" />'
				);

				if (data.portletAjaxable && url) {
					portlet.placeBefore(placeHolder);

					portlet.remove(true);

					Portlet.destroyComponents(portlet.portletId);

					let params = {};

					const urlPieces = url.split('?');

					if (urlPieces.length > 1) {
						params = A.QueryString.parse(urlPieces[1]);

						delete params.dataType;

						url = urlPieces[0];
					}

					instance.addHTML({
						data: A.mix(params, data, true),
						onComplete(newPortlet, portletId) {
							newPortlet.refreshURL = portlet.refreshURL;

							if (newPortlet) {
								newPortlet.attr('data-qa-id', 'app-refreshed');
							}

							Liferay.fire(
								newPortlet.portletId + ':portletRefreshed',
								{
									portlet: newPortlet,
									portletId,
								}
							);
						},
						placeHolder,
						url,
					});
				}
				else if (!portlet.getData('pendingRefresh')) {
					portlet.setData('pendingRefresh', true);

					const nonAjaxableContentMessage = Lang.sub(
						TPL_NOT_AJAXABLE,
						[
							'This\x20change\x20will\x20only\x20be\x20shown\x20after\x20you\x20refresh\x20the\x20current\x20page\x2e',
						]
					);

					const portletBody = portlet.one('.portlet-body');

					portletBody.placeBefore(nonAjaxableContentMessage);

					portletBody.hide();
				}

				Liferay.fire('refreshPortlet', {portletId: portlet.portletId});
			}
		},
		['aui-base', 'querystring-parse']
	);

	Liferay.provide(
		Portlet,
		'registerStatic',
		function (portletId) {
			const instance = this;

			const Node = A.Node;

			if (Node && portletId instanceof Node) {
				portletId = portletId.attr('id');
			}
			else if (portletId.id) {
				portletId = portletId.id;
			}

			const id = Util.getPortletId(portletId);

			instance._staticPortlets[id] = true;
		},
		['aui-base']
	);

	Liferay.publish('closePortlet', {
		defaultFn: Portlet._defCloseFn,
	});

	Liferay.publish('allPortletsReady', {
		fireOnce: true,
	});

	// Backwards compatability

	Portlet.ready = function (fn) {
		Liferay.on('portletReady', (event) => {
			fn(event.portletId, event.portlet);
		});
	};

	Liferay.Portlet = Portlet;
})(AUI());

"use strict";(()=>{var ts=Object.create;var jt=Object.defineProperty;var ns=Object.getOwnPropertyDescriptor;var rs=Object.getOwnPropertyNames;var is=Object.getPrototypeOf,os=Object.prototype.hasOwnProperty;var ss=(e,t,n)=>t in e?jt(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n;var hr=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports);var as=(e,t,n,r)=>{if(t&&typeof t=="object"||typeof t=="function")for(let i of rs(t))!os.call(e,i)&&i!==n&&jt(e,i,{get:()=>t[i],enumerable:!(r=ns(t,i))||r.enumerable});return e};var mr=(e,t,n)=>(n=e!=null?ts(is(e)):{},as(t||!e||!e.__esModule?jt(n,"default",{value:e,enumerable:!0}):n,e));var rt=(e,t,n)=>(ss(e,typeof t!="symbol"?t+"":t,n),n);var Vr=hr((Ue,Ee)=>{var cs=200,ls="Expected a function",Kt="__lodash_hash_undefined__",dt=1,Se=2,Cr=1/0,br=9007199254740991,it="[object Arguments]",qt="[object Array]",Ar="[object Boolean]",xr="[object Date]",Ir="[object Error]",Pr="[object Function]",fs="[object GeneratorFunction]",ot="[object Map]",Or="[object Number]",_e="[object Object]",gr="[object Promise]",Ur="[object RegExp]",st="[object Set]",Rr="[object String]",Nr="[object Symbol]",Wt="[object WeakMap]",Dr="[object ArrayBuffer]",at="[object DataView]",ds="[object Float32Array]",us="[object Float64Array]",ps="[object Int8Array]",hs="[object Int16Array]",ms="[object Int32Array]",gs="[object Uint8Array]",ys="[object Uint8ClampedArray]",_s="[object Uint16Array]",Es="[object Uint32Array]",Ss=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,ws=/^\w*$/,Ts=/^\./,Ls=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,vs=/[\\^$.*+?()[\]{}|]/g,Cs=/\\(\\)?/g,bs=/^\[object .+?Constructor\]$/,As=/^(?:0|[1-9]\d*)$/,g={};g[ds]=g[us]=g[ps]=g[hs]=g[ms]=g[gs]=g[ys]=g[_s]=g[Es]=!0;g[it]=g[qt]=g[Dr]=g[Ar]=g[at]=g[xr]=g[Ir]=g[Pr]=g[ot]=g[Or]=g[_e]=g[Ur]=g[st]=g[Rr]=g[Wt]=!1;var Mr=typeof global=="object"&&global&&global.Object===Object&&global,xs=typeof self=="object"&&self&&self.Object===Object&&self,Z=Mr||xs||Function("return this")(),$r=typeof Ue=="object"&&Ue&&!Ue.nodeType&&Ue,yr=$r&&typeof Ee=="object"&&Ee&&!Ee.nodeType&&Ee,Is=yr&&yr.exports===$r,_r=Is&&Mr.process,Er=function(){try{return _r&&_r.binding("util")}catch{}}(),Sr=Er&&Er.isTypedArray;function Ps(e,t,n,r){for(var i=-1,o=e?e.length:0;++i<o;){var s=e[i];t(r,s,n(s),e)}return r}function Os(e,t){for(var n=-1,r=e?e.length:0;++n<r;)if(t(e[n],n,e))return!0;return!1}function Us(e){return function(t){return t?.[e]}}function Rs(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}function Ns(e){return function(t){return e(t)}}function Ds(e,t){return e?.[t]}function Gt(e){var t=!1;if(e!=null&&typeof e.toString!="function")try{t=!!(e+"")}catch{}return t}function Ms(e){var t=-1,n=Array(e.size);return e.forEach(function(r,i){n[++t]=[i,r]}),n}function $s(e,t){return function(n){return e(t(n))}}function Hs(e){var t=-1,n=Array(e.size);return e.forEach(function(r){n[++t]=r}),n}var js=Array.prototype,Fs=Function.prototype,ut=Object.prototype,Ft=Z["__core-js_shared__"],wr=function(){var e=/[^.]+$/.exec(Ft&&Ft.keys&&Ft.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}(),Hr=Fs.toString,R=ut.hasOwnProperty,we=ut.toString,Bs=RegExp("^"+Hr.call(R).replace(vs,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),Tr=Z.Symbol,Lr=Z.Uint8Array,qs=ut.propertyIsEnumerable,Ws=js.splice,Gs=$s(Object.keys,Object),kt=Te(Z,"DataView"),Re=Te(Z,"Map"),zt=Te(Z,"Promise"),Xt=Te(Z,"Set"),Vt=Te(Z,"WeakMap"),Ne=Te(Object,"create"),ks=ce(kt),zs=ce(Re),Xs=ce(zt),Vs=ce(Xt),Ks=ce(Vt),ct=Tr?Tr.prototype:void 0,Bt=ct?ct.valueOf:void 0,vr=ct?ct.toString:void 0;function ae(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function Ys(){this.__data__=Ne?Ne(null):{}}function Js(e){return this.has(e)&&delete this.__data__[e]}function Zs(e){var t=this.__data__;if(Ne){var n=t[e];return n===Kt?void 0:n}return R.call(t,e)?t[e]:void 0}function Qs(e){var t=this.__data__;return Ne?t[e]!==void 0:R.call(t,e)}function ea(e,t){var n=this.__data__;return n[e]=Ne&&t===void 0?Kt:t,this}ae.prototype.clear=Ys;ae.prototype.delete=Js;ae.prototype.get=Zs;ae.prototype.has=Qs;ae.prototype.set=ea;function F(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function ta(){this.__data__=[]}function na(e){var t=this.__data__,n=pt(t,e);if(n<0)return!1;var r=t.length-1;return n==r?t.pop():Ws.call(t,n,1),!0}function ra(e){var t=this.__data__,n=pt(t,e);return n<0?void 0:t[n][1]}function ia(e){return pt(this.__data__,e)>-1}function oa(e,t){var n=this.__data__,r=pt(n,e);return r<0?n.push([e,t]):n[r][1]=t,this}F.prototype.clear=ta;F.prototype.delete=na;F.prototype.get=ra;F.prototype.has=ia;F.prototype.set=oa;function B(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function sa(){this.__data__={hash:new ae,map:new(Re||F),string:new ae}}function aa(e){return ht(this,e).delete(e)}function ca(e){return ht(this,e).get(e)}function la(e){return ht(this,e).has(e)}function fa(e,t){return ht(this,e).set(e,t),this}B.prototype.clear=sa;B.prototype.delete=aa;B.prototype.get=ca;B.prototype.has=la;B.prototype.set=fa;function lt(e){var t=-1,n=e?e.length:0;for(this.__data__=new B;++t<n;)this.add(e[t])}function da(e){return this.__data__.set(e,Kt),this}function ua(e){return this.__data__.has(e)}lt.prototype.add=lt.prototype.push=da;lt.prototype.has=ua;function j(e){this.__data__=new F(e)}function pa(){this.__data__=new F}function ha(e){return this.__data__.delete(e)}function ma(e){return this.__data__.get(e)}function ga(e){return this.__data__.has(e)}function ya(e,t){var n=this.__data__;if(n instanceof F){var r=n.__data__;if(!Re||r.length<cs-1)return r.push([e,t]),this;n=this.__data__=new B(r)}return n.set(e,t),this}j.prototype.clear=pa;j.prototype.delete=ha;j.prototype.get=ma;j.prototype.has=ga;j.prototype.set=ya;function _a(e,t){var n=J(e)||zr(e)?Rs(e.length,String):[],r=n.length,i=!!r;for(var o in e)(t||R.call(e,o))&&!(i&&(o=="length"||qr(o,r)))&&n.push(o);return n}function pt(e,t){for(var n=e.length;n--;)if(kr(e[n][0],t))return n;return-1}function Ea(e,t,n,r){return Sa(e,function(i,o,s){t(r,i,n(i),s)}),r}var Sa=Ma(Ta),wa=$a();function Ta(e,t){return e&&wa(e,t,ft)}function jr(e,t){t=mt(t,e)?[t]:Fr(t);for(var n=0,r=t.length;e!=null&&n<r;)e=e[gt(t[n++])];return n&&n==r?e:void 0}function La(e){return we.call(e)}function va(e,t){return e!=null&&t in Object(e)}function Yt(e,t,n,r,i){return e===t?!0:e==null||t==null||!yt(e)&&!_t(t)?e!==e&&t!==t:Ca(e,t,Yt,n,r,i)}function Ca(e,t,n,r,i,o){var s=J(e),a=J(t),c=qt,l=qt;s||(c=Y(e),c=c==it?_e:c),a||(l=Y(t),l=l==it?_e:l);var f=c==_e&&!Gt(e),u=l==_e&&!Gt(t),d=c==l;if(d&&!f)return o||(o=new j),s||Va(e)?Br(e,t,n,r,i,o):Ha(e,t,c,n,r,i,o);if(!(i&Se)){var p=f&&R.call(e,"__wrapped__"),h=u&&R.call(t,"__wrapped__");if(p||h){var E=p?e.value():e,m=h?t.value():t;return o||(o=new j),n(E,m,r,i,o)}}return d?(o||(o=new j),ja(e,t,n,r,i,o)):!1}function ba(e,t,n,r){var i=n.length,o=i,s=!r;if(e==null)return!o;for(e=Object(e);i--;){var a=n[i];if(s&&a[2]?a[1]!==e[a[0]]:!(a[0]in e))return!1}for(;++i<o;){a=n[i];var c=a[0],l=e[c],f=a[1];if(s&&a[2]){if(l===void 0&&!(c in e))return!1}else{var u=new j;if(r)var d=r(l,f,c,e,t,u);if(!(d===void 0?Yt(f,l,r,dt|Se,u):d))return!1}}return!0}function Aa(e){if(!yt(e)||Wa(e))return!1;var t=Xr(e)||Gt(e)?Bs:bs;return t.test(ce(e))}function xa(e){return _t(e)&&Qt(e.length)&&!!g[we.call(e)]}function Ia(e){return typeof e=="function"?e:e==null?Za:typeof e=="object"?J(e)?Ua(e[0],e[1]):Oa(e):Qa(e)}function Pa(e){if(!Ga(e))return Gs(e);var t=[];for(var n in Object(e))R.call(e,n)&&n!="constructor"&&t.push(n);return t}function Oa(e){var t=Fa(e);return t.length==1&&t[0][2]?Gr(t[0][0],t[0][1]):function(n){return n===e||ba(n,e,t)}}function Ua(e,t){return mt(e)&&Wr(t)?Gr(gt(e),t):function(n){var r=Ya(n,e);return r===void 0&&r===t?Ja(n,e):Yt(t,r,void 0,dt|Se)}}function Ra(e){return function(t){return jr(t,e)}}function Na(e){if(typeof e=="string")return e;if(en(e))return vr?vr.call(e):"";var t=e+"";return t=="0"&&1/e==-Cr?"-0":t}function Fr(e){return J(e)?e:ka(e)}function Da(e,t){return function(n,r){var i=J(n)?Ps:Ea,o=t?t():{};return i(n,e,Ia(r,2),o)}}function Ma(e,t){return function(n,r){if(n==null)return n;if(!Zt(n))return e(n,r);for(var i=n.length,o=t?i:-1,s=Object(n);(t?o--:++o<i)&&r(s[o],o,s)!==!1;);return n}}function $a(e){return function(t,n,r){for(var i=-1,o=Object(t),s=r(t),a=s.length;a--;){var c=s[e?a:++i];if(n(o[c],c,o)===!1)break}return t}}function Br(e,t,n,r,i,o){var s=i&Se,a=e.length,c=t.length;if(a!=c&&!(s&&c>a))return!1;var l=o.get(e);if(l&&o.get(t))return l==t;var f=-1,u=!0,d=i&dt?new lt:void 0;for(o.set(e,t),o.set(t,e);++f<a;){var p=e[f],h=t[f];if(r)var E=s?r(h,p,f,t,e,o):r(p,h,f,e,t,o);if(E!==void 0){if(E)continue;u=!1;break}if(d){if(!Os(t,function(m,L){if(!d.has(L)&&(p===m||n(p,m,r,i,o)))return d.add(L)})){u=!1;break}}else if(!(p===h||n(p,h,r,i,o))){u=!1;break}}return o.delete(e),o.delete(t),u}function Ha(e,t,n,r,i,o,s){switch(n){case at:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case Dr:return!(e.byteLength!=t.byteLength||!r(new Lr(e),new Lr(t)));case Ar:case xr:case Or:return kr(+e,+t);case Ir:return e.name==t.name&&e.message==t.message;case Ur:case Rr:return e==t+"";case ot:var a=Ms;case st:var c=o&Se;if(a||(a=Hs),e.size!=t.size&&!c)return!1;var l=s.get(e);if(l)return l==t;o|=dt,s.set(e,t);var f=Br(a(e),a(t),r,i,o,s);return s.delete(e),f;case Nr:if(Bt)return Bt.call(e)==Bt.call(t)}return!1}function ja(e,t,n,r,i,o){var s=i&Se,a=ft(e),c=a.length,l=ft(t),f=l.length;if(c!=f&&!s)return!1;for(var u=c;u--;){var d=a[u];if(!(s?d in t:R.call(t,d)))return!1}var p=o.get(e);if(p&&o.get(t))return p==t;var h=!0;o.set(e,t),o.set(t,e);for(var E=s;++u<c;){d=a[u];var m=e[d],L=t[d];if(r)var Oe=s?r(L,m,d,t,e,o):r(m,L,d,e,t,o);if(!(Oe===void 0?m===L||n(m,L,r,i,o):Oe)){h=!1;break}E||(E=d=="constructor")}if(h&&!E){var $=e.constructor,H=t.constructor;$!=H&&"constructor"in e&&"constructor"in t&&!(typeof $=="function"&&$ instanceof $&&typeof H=="function"&&H instanceof H)&&(h=!1)}return o.delete(e),o.delete(t),h}function ht(e,t){var n=e.__data__;return qa(t)?n[typeof t=="string"?"string":"hash"]:n.map}function Fa(e){for(var t=ft(e),n=t.length;n--;){var r=t[n],i=e[r];t[n]=[r,i,Wr(i)]}return t}function Te(e,t){var n=Ds(e,t);return Aa(n)?n:void 0}var Y=La;(kt&&Y(new kt(new ArrayBuffer(1)))!=at||Re&&Y(new Re)!=ot||zt&&Y(zt.resolve())!=gr||Xt&&Y(new Xt)!=st||Vt&&Y(new Vt)!=Wt)&&(Y=function(e){var t=we.call(e),n=t==_e?e.constructor:void 0,r=n?ce(n):void 0;if(r)switch(r){case ks:return at;case zs:return ot;case Xs:return gr;case Vs:return st;case Ks:return Wt}return t});function Ba(e,t,n){t=mt(t,e)?[t]:Fr(t);for(var r,i=-1,s=t.length;++i<s;){var o=gt(t[i]);if(!(r=e!=null&&n(e,o)))break;e=e[o]}if(r)return r;var s=e?e.length:0;return!!s&&Qt(s)&&qr(o,s)&&(J(e)||zr(e))}function qr(e,t){return t=t??br,!!t&&(typeof e=="number"||As.test(e))&&e>-1&&e%1==0&&e<t}function mt(e,t){if(J(e))return!1;var n=typeof e;return n=="number"||n=="symbol"||n=="boolean"||e==null||en(e)?!0:ws.test(e)||!Ss.test(e)||t!=null&&e in Object(t)}function qa(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}function Wa(e){return!!wr&&wr in e}function Ga(e){var t=e&&e.constructor,n=typeof t=="function"&&t.prototype||ut;return e===n}function Wr(e){return e===e&&!yt(e)}function Gr(e,t){return function(n){return n==null?!1:n[e]===t&&(t!==void 0||e in Object(n))}}var ka=Jt(function(e){e=Ka(e);var t=[];return Ts.test(e)&&t.push(""),e.replace(Ls,function(n,r,i,o){t.push(i?o.replace(Cs,"$1"):r||n)}),t});function gt(e){if(typeof e=="string"||en(e))return e;var t=e+"";return t=="0"&&1/e==-Cr?"-0":t}function ce(e){if(e!=null){try{return Hr.call(e)}catch{}try{return e+""}catch{}}return""}var za=Da(function(e,t,n){R.call(e,n)?e[n].push(t):e[n]=[t]});function Jt(e,t){if(typeof e!="function"||t&&typeof t!="function")throw new TypeError(ls);var n=function(){var r=arguments,i=t?t.apply(this,r):r[0],o=n.cache;if(o.has(i))return o.get(i);var s=e.apply(this,r);return n.cache=o.set(i,s),s};return n.cache=new(Jt.Cache||B),n}Jt.Cache=B;function kr(e,t){return e===t||e!==e&&t!==t}function zr(e){return Xa(e)&&R.call(e,"callee")&&(!qs.call(e,"callee")||we.call(e)==it)}var J=Array.isArray;function Zt(e){return e!=null&&Qt(e.length)&&!Xr(e)}function Xa(e){return _t(e)&&Zt(e)}function Xr(e){var t=yt(e)?we.call(e):"";return t==Pr||t==fs}function Qt(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=br}function yt(e){var t=typeof e;return!!e&&(t=="object"||t=="function")}function _t(e){return!!e&&typeof e=="object"}function en(e){return typeof e=="symbol"||_t(e)&&we.call(e)==Nr}var Va=Sr?Ns(Sr):xa;function Ka(e){return e==null?"":Na(e)}function Ya(e,t,n){var r=e==null?void 0:jr(e,t);return r===void 0?n:r}function Ja(e,t){return e!=null&&Ba(e,t,va)}function ft(e){return Zt(e)?_a(e):Pa(e)}function Za(e){return e}function Qa(e){return mt(e)?Us(gt(e)):Ra(e)}Ee.exports=za});var Ii=hr((De,ve)=>{var ec=200,un="__lodash_hash_undefined__",bt=1,si=2,ai=9007199254740991,Et="[object Arguments]",on="[object Array]",tc="[object AsyncFunction]",ci="[object Boolean]",li="[object Date]",fi="[object Error]",di="[object Function]",nc="[object GeneratorFunction]",St="[object Map]",ui="[object Number]",rc="[object Null]",Le="[object Object]",Kr="[object Promise]",ic="[object Proxy]",pi="[object RegExp]",wt="[object Set]",hi="[object String]",oc="[object Symbol]",sc="[object Undefined]",sn="[object WeakMap]",mi="[object ArrayBuffer]",Tt="[object DataView]",ac="[object Float32Array]",cc="[object Float64Array]",lc="[object Int8Array]",fc="[object Int16Array]",dc="[object Int32Array]",uc="[object Uint8Array]",pc="[object Uint8ClampedArray]",hc="[object Uint16Array]",mc="[object Uint32Array]",gc=/[\\^$.*+?()[\]{}|]/g,yc=/^\[object .+?Constructor\]$/,_c=/^(?:0|[1-9]\d*)$/,y={};y[ac]=y[cc]=y[lc]=y[fc]=y[dc]=y[uc]=y[pc]=y[hc]=y[mc]=!0;y[Et]=y[on]=y[mi]=y[ci]=y[Tt]=y[li]=y[fi]=y[di]=y[St]=y[ui]=y[Le]=y[pi]=y[wt]=y[hi]=y[sn]=!1;var gi=typeof global=="object"&&global&&global.Object===Object&&global,Ec=typeof self=="object"&&self&&self.Object===Object&&self,q=gi||Ec||Function("return this")(),yi=typeof De=="object"&&De&&!De.nodeType&&De,Yr=yi&&typeof ve=="object"&&ve&&!ve.nodeType&&ve,_i=Yr&&Yr.exports===yi,tn=_i&&gi.process,Jr=function(){try{return tn&&tn.binding&&tn.binding("util")}catch{}}(),Zr=Jr&&Jr.isTypedArray;function Sc(e,t){for(var n=-1,r=e==null?0:e.length,i=0,o=[];++n<r;){var s=e[n];t(s,n,e)&&(o[i++]=s)}return o}function wc(e,t){for(var n=-1,r=t.length,i=e.length;++n<r;)e[i+n]=t[n];return e}function Tc(e,t){for(var n=-1,r=e==null?0:e.length;++n<r;)if(t(e[n],n,e))return!0;return!1}function Lc(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}function vc(e){return function(t){return e(t)}}function Cc(e,t){return e.has(t)}function bc(e,t){return e?.[t]}function Ac(e){var t=-1,n=Array(e.size);return e.forEach(function(r,i){n[++t]=[i,r]}),n}function xc(e,t){return function(n){return e(t(n))}}function Ic(e){var t=-1,n=Array(e.size);return e.forEach(function(r){n[++t]=r}),n}var Pc=Array.prototype,Oc=Function.prototype,At=Object.prototype,nn=q["__core-js_shared__"],Ei=Oc.toString,N=At.hasOwnProperty,Qr=function(){var e=/[^.]+$/.exec(nn&&nn.keys&&nn.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}(),Si=At.toString,Uc=RegExp("^"+Ei.call(N).replace(gc,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),ei=_i?q.Buffer:void 0,Lt=q.Symbol,ti=q.Uint8Array,wi=At.propertyIsEnumerable,Rc=Pc.splice,le=Lt?Lt.toStringTag:void 0,ni=Object.getOwnPropertySymbols,Nc=ei?ei.isBuffer:void 0,Dc=xc(Object.keys,Object),an=Ce(q,"DataView"),Me=Ce(q,"Map"),cn=Ce(q,"Promise"),ln=Ce(q,"Set"),fn=Ce(q,"WeakMap"),$e=Ce(Object,"create"),Mc=ue(an),$c=ue(Me),Hc=ue(cn),jc=ue(ln),Fc=ue(fn),ri=Lt?Lt.prototype:void 0,rn=ri?ri.valueOf:void 0;function fe(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function Bc(){this.__data__=$e?$e(null):{},this.size=0}function qc(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}function Wc(e){var t=this.__data__;if($e){var n=t[e];return n===un?void 0:n}return N.call(t,e)?t[e]:void 0}function Gc(e){var t=this.__data__;return $e?t[e]!==void 0:N.call(t,e)}function kc(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=$e&&t===void 0?un:t,this}fe.prototype.clear=Bc;fe.prototype.delete=qc;fe.prototype.get=Wc;fe.prototype.has=Gc;fe.prototype.set=kc;function W(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function zc(){this.__data__=[],this.size=0}function Xc(e){var t=this.__data__,n=xt(t,e);if(n<0)return!1;var r=t.length-1;return n==r?t.pop():Rc.call(t,n,1),--this.size,!0}function Vc(e){var t=this.__data__,n=xt(t,e);return n<0?void 0:t[n][1]}function Kc(e){return xt(this.__data__,e)>-1}function Yc(e,t){var n=this.__data__,r=xt(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this}W.prototype.clear=zc;W.prototype.delete=Xc;W.prototype.get=Vc;W.prototype.has=Kc;W.prototype.set=Yc;function de(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function Jc(){this.size=0,this.__data__={hash:new fe,map:new(Me||W),string:new fe}}function Zc(e){var t=It(this,e).delete(e);return this.size-=t?1:0,t}function Qc(e){return It(this,e).get(e)}function el(e){return It(this,e).has(e)}function tl(e,t){var n=It(this,e),r=n.size;return n.set(e,t),this.size+=n.size==r?0:1,this}de.prototype.clear=Jc;de.prototype.delete=Zc;de.prototype.get=Qc;de.prototype.has=el;de.prototype.set=tl;function vt(e){var t=-1,n=e==null?0:e.length;for(this.__data__=new de;++t<n;)this.add(e[t])}function nl(e){return this.__data__.set(e,un),this}function rl(e){return this.__data__.has(e)}vt.prototype.add=vt.prototype.push=nl;vt.prototype.has=rl;function ee(e){var t=this.__data__=new W(e);this.size=t.size}function il(){this.__data__=new W,this.size=0}function ol(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n}function sl(e){return this.__data__.get(e)}function al(e){return this.__data__.has(e)}function cl(e,t){var n=this.__data__;if(n instanceof W){var r=n.__data__;if(!Me||r.length<ec-1)return r.push([e,t]),this.size=++n.size,this;n=this.__data__=new de(r)}return n.set(e,t),this.size=n.size,this}ee.prototype.clear=il;ee.prototype.delete=ol;ee.prototype.get=sl;ee.prototype.has=al;ee.prototype.set=cl;function ll(e,t){var n=Ct(e),r=!n&&vl(e),i=!n&&!r&&dn(e),o=!n&&!r&&!i&&xi(e),s=n||r||i||o,a=s?Lc(e.length,String):[],c=a.length;for(var l in e)(t||N.call(e,l))&&!(s&&(l=="length"||i&&(l=="offset"||l=="parent")||o&&(l=="buffer"||l=="byteLength"||l=="byteOffset")||El(l,c)))&&a.push(l);return a}function xt(e,t){for(var n=e.length;n--;)if(vi(e[n][0],t))return n;return-1}function fl(e,t,n){var r=t(e);return Ct(e)?r:wc(r,n(e))}function je(e){return e==null?e===void 0?sc:rc:le&&le in Object(e)?yl(e):Ll(e)}function ii(e){return He(e)&&je(e)==Et}function Ti(e,t,n,r,i){return e===t?!0:e==null||t==null||!He(e)&&!He(t)?e!==e&&t!==t:dl(e,t,n,r,Ti,i)}function dl(e,t,n,r,i,o){var s=Ct(e),a=Ct(t),c=s?on:Q(e),l=a?on:Q(t);c=c==Et?Le:c,l=l==Et?Le:l;var f=c==Le,u=l==Le,d=c==l;if(d&&dn(e)){if(!dn(t))return!1;s=!0,f=!1}if(d&&!f)return o||(o=new ee),s||xi(e)?Li(e,t,n,r,i,o):ml(e,t,c,n,r,i,o);if(!(n&bt)){var p=f&&N.call(e,"__wrapped__"),h=u&&N.call(t,"__wrapped__");if(p||h){var E=p?e.value():e,m=h?t.value():t;return o||(o=new ee),i(E,m,n,r,o)}}return d?(o||(o=new ee),gl(e,t,n,r,i,o)):!1}function ul(e){if(!Ai(e)||wl(e))return!1;var t=Ci(e)?Uc:yc;return t.test(ue(e))}function pl(e){return He(e)&&bi(e.length)&&!!y[je(e)]}function hl(e){if(!Tl(e))return Dc(e);var t=[];for(var n in Object(e))N.call(e,n)&&n!="constructor"&&t.push(n);return t}function Li(e,t,n,r,i,o){var s=n&bt,a=e.length,c=t.length;if(a!=c&&!(s&&c>a))return!1;var l=o.get(e);if(l&&o.get(t))return l==t;var f=-1,u=!0,d=n&si?new vt:void 0;for(o.set(e,t),o.set(t,e);++f<a;){var p=e[f],h=t[f];if(r)var E=s?r(h,p,f,t,e,o):r(p,h,f,e,t,o);if(E!==void 0){if(E)continue;u=!1;break}if(d){if(!Tc(t,function(m,L){if(!Cc(d,L)&&(p===m||i(p,m,n,r,o)))return d.push(L)})){u=!1;break}}else if(!(p===h||i(p,h,n,r,o))){u=!1;break}}return o.delete(e),o.delete(t),u}function ml(e,t,n,r,i,o,s){switch(n){case Tt:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case mi:return!(e.byteLength!=t.byteLength||!o(new ti(e),new ti(t)));case ci:case li:case ui:return vi(+e,+t);case fi:return e.name==t.name&&e.message==t.message;case pi:case hi:return e==t+"";case St:var a=Ac;case wt:var c=r&bt;if(a||(a=Ic),e.size!=t.size&&!c)return!1;var l=s.get(e);if(l)return l==t;r|=si,s.set(e,t);var f=Li(a(e),a(t),r,i,o,s);return s.delete(e),f;case oc:if(rn)return rn.call(e)==rn.call(t)}return!1}function gl(e,t,n,r,i,o){var s=n&bt,a=oi(e),c=a.length,l=oi(t),f=l.length;if(c!=f&&!s)return!1;for(var u=c;u--;){var d=a[u];if(!(s?d in t:N.call(t,d)))return!1}var p=o.get(e);if(p&&o.get(t))return p==t;var h=!0;o.set(e,t),o.set(t,e);for(var E=s;++u<c;){d=a[u];var m=e[d],L=t[d];if(r)var Oe=s?r(L,m,d,t,e,o):r(m,L,d,e,t,o);if(!(Oe===void 0?m===L||i(m,L,n,r,o):Oe)){h=!1;break}E||(E=d=="constructor")}if(h&&!E){var $=e.constructor,H=t.constructor;$!=H&&"constructor"in e&&"constructor"in t&&!(typeof $=="function"&&$ instanceof $&&typeof H=="function"&&H instanceof H)&&(h=!1)}return o.delete(e),o.delete(t),h}function oi(e){return fl(e,Al,_l)}function It(e,t){var n=e.__data__;return Sl(t)?n[typeof t=="string"?"string":"hash"]:n.map}function Ce(e,t){var n=bc(e,t);return ul(n)?n:void 0}function yl(e){var t=N.call(e,le),n=e[le];try{e[le]=void 0;var r=!0}catch{}var i=Si.call(e);return r&&(t?e[le]=n:delete e[le]),i}var _l=ni?function(e){return e==null?[]:(e=Object(e),Sc(ni(e),function(t){return wi.call(e,t)}))}:xl,Q=je;(an&&Q(new an(new ArrayBuffer(1)))!=Tt||Me&&Q(new Me)!=St||cn&&Q(cn.resolve())!=Kr||ln&&Q(new ln)!=wt||fn&&Q(new fn)!=sn)&&(Q=function(e){var t=je(e),n=t==Le?e.constructor:void 0,r=n?ue(n):"";if(r)switch(r){case Mc:return Tt;case $c:return St;case Hc:return Kr;case jc:return wt;case Fc:return sn}return t});function El(e,t){return t=t??ai,!!t&&(typeof e=="number"||_c.test(e))&&e>-1&&e%1==0&&e<t}function Sl(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}function wl(e){return!!Qr&&Qr in e}function Tl(e){var t=e&&e.constructor,n=typeof t=="function"&&t.prototype||At;return e===n}function Ll(e){return Si.call(e)}function ue(e){if(e!=null){try{return Ei.call(e)}catch{}try{return e+""}catch{}}return""}function vi(e,t){return e===t||e!==e&&t!==t}var vl=ii(function(){return arguments}())?ii:function(e){return He(e)&&N.call(e,"callee")&&!wi.call(e,"callee")},Ct=Array.isArray;function Cl(e){return e!=null&&bi(e.length)&&!Ci(e)}var dn=Nc||Il;function bl(e,t){return Ti(e,t)}function Ci(e){if(!Ai(e))return!1;var t=je(e);return t==di||t==nc||t==tc||t==ic}function bi(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=ai}function Ai(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}function He(e){return e!=null&&typeof e=="object"}var xi=Zr?vc(Zr):pl;function Al(e){return Cl(e)?ll(e):hl(e)}function xl(){return[]}function Il(){return!1}ve.exports=bl});var Jo=mr(Vr()),Zo=mr(Ii());async function Pi(e){if(e.includes(" from ")){let[t,n]=Pl(e);return(await import(t))[n]}else return new Promise((t,n)=>{Liferay.Loader.require(e,r=>t(r.default||r),r=>n(r))})}function Pl(e){let t=e.split(" from "),n=t[1].trim(),r=t[0].trim();return r.startsWith("{")&&r.endsWith("}")&&(r=r.substring(1,r.length-1).trim()),[n,r]}function Fe(e){for(let{clientExtensionDefinitions:t,onLoad:n}of e){if(!t.length)continue;let r=t.map(({context:i,importDeclaration:o})=>Pi(o).then(s=>({binding:s,context:i})).catch(s=>({context:i,error:s})));Promise.all(r).then(n)}}function pn({config:e,onLoad:t}){Fe([{clientExtensionDefinitions:e.editorTransformerURLs.map(n=>({importDeclaration:`default from ${n}`})),onLoad:n=>{let r=JSON.parse(JSON.stringify(e));n.forEach(({binding:i,error:o})=>{let s=i?.editorConfigTransformer;s&&(r=s(r))}),t({transformedConfig:r})}}])}function S(e){let t=typeof e;return t==="object"&&e!==null||t==="function"}function G(e={},t=new FormData,n){return Object.entries(e).forEach(([r,i])=>{let o=n?`${n}[${r}]`:r;Array.isArray(i)?i.forEach(s=>{G({[o]:s},t)}):S(i)&&!(i instanceof File)?G(i,t,o):t.append(o,i)}),t}function Oi(e){return typeof e=="string"&&(e=document.querySelector(e)),e}var hn=class{get namespace(){return this._STATE_.namespace}get portletNamespace(){return this._STATE_.portletNamespace}get rootNode(){return this._STATE_.rootNode}set portletNamespace(t){this.rootNode=`#p_p_id${t}`,this._STATE_.portletNamespace=t}set namespace(t){this.rootNode=`#p_p_id${t}`,this._STATE_.namespace=t}set rootNode(t){typeof t=="string"&&(t=document.getElementById(t[0]==="#"?t.slice(1):t)),this._STATE_.rootNode=t}constructor(t){this._EVENTS_={},this._STATE_={namespace:null,portletNamespace:null,rootNode:null};let{namespace:n,portletNamespace:r,rootNode:i}=t;n&&(this.namespace=n),r&&(this.portletNamespace=r),i&&(this.rootNode=i),this.created(t),this.attached(t)}dispose(){this.disposeInternal(),this.detached(),this.disposed()}attached(){}created(){}detached(){}disposed(){}disposeInternal(){}emit(t,n){let r=this._EVENTS_[t];if(r&&r.length)for(let i=0;i<r.length;i++)r[i](n)}on(t,n){this._EVENTS_[t]||(this._EVENTS_[t]=[]),this._EVENTS_[t].push(n)}},mn=class extends hn{all(t,n){return n=Oi(n)||this.rootNode||document,n.querySelectorAll(this.namespaceSelectors_(this.portletNamespace||this.namespace,t))}fetch(t,n){let r=this.getRequestBody_(n);return fetch(t,{body:r,credentials:"include",method:"POST"})}getRequestBody_(t){let n;return t instanceof FormData?n=t:t instanceof HTMLFormElement?n=new FormData(t):typeof t=="object"?n=G(this.ns(t)):n=t,n}namespaceSelectors_(t,n){return n.replace(new RegExp(`(#|\\[id=(\\"|\\'))(?!`+t+")","g"),"$1"+t)}ns(t){return Liferay.Util.ns(this.portletNamespace||this.namespace,t)}one(t,n){return n=Oi(n)||this.rootNode||document,n.querySelector(this.namespaceSelectors_(this.portletNamespace||this.namespace,t))}},Ui=mn;var Ol={blur:!0,error:!0,focus:!0,invalid:!0,load:!0,scroll:!0};function Ul(e){return!!(e.disabled||e.closest("[disabled]"))}function Rl(e,t,n,r){let i=o=>{let{defaultPrevented:s,target:a}=o;if(s||t==="click"&&Ul(a))return;let c=a.closest(n);c&&(o.delegateTarget=c,r(o))};return e.addEventListener(t,i,!!Ol[t]),{dispose(){e.removeEventListener(t,i)}}}var Pt=Rl;var gn=class extends Ui{attached(){let{rootNode:t}=this;t=t||document.body,this.inlineScrollEventHandler_=Pt(t,"scroll","ul.pagination ul.inline-scroller",this.onScroll_.bind(this))}created(t){this.cur=Number(t.cur),this.curParam=t.curParam,this.forcePost=t.forcePost,this.formName=t.formName,this.initialPages=Number(t.initialPages),this.jsCall=t.jsCall,this.namespace=t.namespace,this.pages=Number(t.pages),this.randomNamespace=t.randomNamespace,this.url=t.url,this.urlAnchor=t.urlAnchor,this.handleListItemClick_=this.handleListItemClick_.bind(this)}detached(){super.detached(),this.inlineScrollEventHandler_.dispose(),document.createElement("li").removeEventListener("click",this.handleListItemClick_)}addListItem_(t,n){let r=document.createElement("li");r.innerHTML=`<a class="dropdown-item" href="${this.getHREF_(n)}"><span class="sr-only">${'Page'}&nbsp;</span>${n}</a>`,n++,t.appendChild(r),t.setAttribute("data-page-index",n),r.addEventListener("click",this.handleListItemClick_)}getHREF_(t){let{curParam:n,formName:r,jsCall:i,namespace:o,url:s,urlAnchor:a}=this,c=`javascript:document.${r}.${o}${n}.value = "${t}; ${i}`;return this.url!==null&&(c=`${s}&${o}${n}=${t}${a}`),c}getNumber_(t){return Number(t??0)}handleListItemClick_(t){if(this.forcePost){t.preventDefault();let{curParam:n,namespace:r,randomNamespace:i}=this,o=document.getElementById(i+r+"pageIteratorFm");o.elements[r+n].value=t.currentTarget.textContent,o.submit()}}onScroll_(t){let{cur:n,initialPages:r,pages:i}=this,{target:o}=t;if(o.nodeName!=="UL")return;let s=this.getNumber_(o.dataset.pageIndex),a=this.getNumber_(o.dataset.maxIndex);if(s===0){let c=this.getNumber_(o.dataset.currentIndex);c===0?s=r:s=c+r}a===0&&(a=i),n<=i&&s<a&&o.scrollTop>=o.scrollHeight-300&&this.addListItem_(o,s)}},Ri=gn;var Be={'"':"&#034;","&":"&amp;","'":"&#039;","/":"&#047;","<":"&lt;",">":"&gt;","`":"&#096;"};var Nl={};Object.entries(Be).forEach(([e,t])=>{Nl[t]=e});var Dl=Object.keys(Be),Ml=new RegExp(`[${Dl.join("")}]`,"g"),$l=/&([^\s;]+);/g;function pe(e){return e.replace(Ml,t=>Be[t])}function Ni(e){return e.replace($l,t=>new DOMParser().parseFromString(t,"text/html").documentElement.textContent)}function k(e,t){typeof e=="string"?e=document.querySelectorAll(e):e._node?e=[e._node]:e._nodes?e=e._nodes:e.nodeType===Node.ELEMENT_NODE&&(e=[e]),e.forEach(n=>{n.disabled=t,t?n.classList.add("disabled"):n.classList.remove("disabled")})}function Hl(e,t){let n=e.indexOf('">'),r=e.substring(n);n=t.indexOf('">');let i=t.substring(n);return r<i?-1:r>i?1:0}function jl(e){return Array.isArray(e)?!0:!!(e&&typeof e=="object"&&typeof e.length=="number"&&!e.tagName&&!e.scrollTo&&!e.document)}function Fl(e){return jl(e)?Array.from(e):[e]}function Di(e,t,n){let r=e[t],i=document.getElementById(r.select);if(!i)return;let o=Fl(r.selectVal),s=[];for(r.selectNullable!==!1&&s.push('<option selected value="0"></option>'),n.forEach(a=>{let c=pe(a[r.selectId]),l=pe(a[r.selectDesc]),f="";o.indexOf(c)>-1&&(f='selected="selected"'),s.push(`<option ${f} value="${c}">${l}</option>`)}),r.selectSort&&s.sort(Hl);i.lastChild;)i.removeChild(i.lastChild);i.innerHTML=s.join(""),r.selectDisableOnEmpty&&k(i,!n.length)}function Bl(e,t){if(t+1<e.length){let n=document.getElementById(e[t].select),r=e[t+1].selectData;r(i=>{Di(e,t+1,i)},n&&n.value)}}function ql(e){e.forEach((t,n)=>{let r=t.select,i=document.getElementById(r),o=t.selectData;if(i){i.setAttribute("data-componentType","dynamic_select");let s;n>0&&(s=e[n-1].selectVal),o(a=>{Di(e,n,a)},s),i.getAttribute("name")||i.setAttribute("name",r),i.addEventListener("change",()=>{Bl(e,n)})}})}var qe=class{constructor(t){ql(t)}};var Mi="&nbsp;&nbsp;",yn=class{constructor(t){rt(this,"handleInput",t=>{requestAnimationFrame(()=>{this._resizeInput(t.target)})});this.inputElement=t,this.computedStyle=getComputedStyle(this.inputElement),this.minHeight=parseInt(this.computedStyle.height.replace("px",""),10),this.paddingHeight=parseInt(this.computedStyle.paddingTop.replace("px",""),10)+parseInt(this.computedStyle.paddingBottom.replace("px",""),10),this.template=this.createTemplate(this.computedStyle),document.body.appendChild(this.template),this.inputElement.addEventListener("input",this.handleInput),this._resizeInput(this.inputElement)}createTemplate(t){let n=document.createElement("pre");return n.style.clip="rect(0, 0, 0, 0) !important",n.style.left="0",n.style.overflowWrap="break-word",n.style.position="absolute",n.style.top="0",n.style.transform="scale(0)",n.style.whiteSpace="pre-wrap",n.style.wordBreak="break-word",n.style.fontFamily=t.fontFamily,n.style.fontSize=t.fontSize,n.style.fontStyle=t.fontStyle,n.style.fontWeight=t.fontWeight,n.style.lineHeight=t.lineHeight,n.style.letterSpacing=t.letterSpacing,n.style.textTransform=t.textTransform,n.style.width=t.width,n.textContent=Mi,n}_resizeInput(t){this.template.style.width!==this.computedStyle.width&&(this.template.style.width=this.computedStyle.width),this.template.innerHTML=pe(t.value)+Mi,t.style.height=`${this.template.scrollHeight+this.paddingHeight<this.minHeight?this.minHeight:this.template.scrollHeight+this.paddingHeight}px`}},$i=yn;var be={PHONE:768,TABLET:980};var he={},te={},x={},Ot={},ji={},Wl=["p_p_id","p_p_lifecycle"],Gl=["ddmStructureKey","fileEntryTypeId","folderId","navigation","status"],Hi="liferay.component",Fi=function(e){let t;if(e)t={promise:Promise.resolve(e),resolve(){}};else{let n;t={promise:new Promise(i=>{n=i}),resolve:n}}return t},kl=function(e,t,n){let r=e.data;Object.keys(r).forEach(o=>{let s=n.querySelector(`#${o}`);s&&(s.innerHTML=r[o].html)})},zl=function(e){let t=new URL(window.location.href),n=new URL(e.path,window.location.href);if(Wl.every(i=>n.searchParams.get(i)===t.searchParams.get(i))){let i=Object.keys(x);i=i.filter(o=>{let s=x[o];if(!s)return!1;let a=he[o],c=Gl.every(f=>{let u=!1;if(a){let d=`_${a.portletId}_${f}`;u=n.searchParams.get(d)===t.searchParams.get(d)}return u});return(typeof s.isCacheable=="function"?s.isCacheable(n):!1)&&c&&a&&a.cacheState&&s.element&&s.getState}),Ot=i.reduce((o,s)=>{let a=x[s],c=he[s],l=a.getState(),f=c.cacheState.reduce((u,d)=>(u[d]=l[d],u),{});return o[s]={html:a.element.innerHTML,state:f},o},[]),Liferay.DOMTaskRunner.addTask({action:kl,condition:o=>o.owner===Hi}),Liferay.DOMTaskRunner.addTaskState({data:Ot,owner:Hi})}else Ot={}},Bi=function(e,t,n){let r;if(arguments.length===1){let i=x[e];i&&typeof i=="function"&&(ji[e]=i,i=i(),x[e]=i),r=i}else if(x[e]&&t!==null&&(delete he[e],delete te[e],console.warn('Component with id "'+e+'" is being registered twice. This can lead to unexpected behaviour in the "Liferay.component" and "Liferay.componentReady" APIs, as well as in the "*:registered" events.')),r=x[e]=t,t===null)delete he[e],delete te[e];else{he[e]=n,Liferay.fire(e+":registered");let i=te[e];i?i.resolve(t):te[e]=Fi(t)}return r},_n=function(){let e,t;if(arguments.length===1)e=arguments[0];else{e=[];for(let n=0;n<arguments.length;n++)e[n]=arguments[n]}if(Array.isArray(e))t=Promise.all(e.map(n=>_n(n)));else{let n=te[e];n||(te[e]=n=Fi()),t=n.promise}return t},En=function(e){let t=x[e];if(t){let n=t.destroy||t.dispose;n&&n.call(t),delete he[e],delete te[e],delete ji[e],delete x[e]}},qi=function(e){let t=Object.keys(x);e&&(t=t.filter(n=>e(x[n],he[n]||{}))),t.forEach(En)},Wi=function(){te={}},Gi=function(e){let t=Ot[e];return t?t.state:{}},ki=function(){Liferay.on("startNavigate",zl)};function Xl(e,t){return function n(){let r=arguments;Vl(n),n.id=setTimeout(()=>{e(...r)},t)}}function Vl(e){clearTimeout(e.id)}var zi=Xl;var Kl="simulationDeviceIframe",Xi;function z(){let e=Xi;if(!e){let t=window.parent,n;for(;t!==window;){try{if(typeof t.location.href>"u")break;n=t.themeDisplay}catch{break}if(!n||window.name===Kl)break;if(!n.isStatePopUp()||t===t.parent){e=t;break}t=t.parent}e||(e=window),Xi=e}return e}function Ae(e,t){let n=z();e.openingWindow=window,n.Liferay.Util._openWindowProvider(e,t)}function Vi(e){e=e||{};let t=e.obj,n=e.pane;t&&t.checked&&(n=document.querySelector(n),n&&n.classList.add("hide"))}function Ki(){return{minus:themeDisplay.getPathThemeImages()+"/arrows/01_minus.png",plus:themeDisplay.getPathThemeImages()+"/arrows/01_plus.png"}}function Yi(e){e=e||{};let t=e.namespace,n=e.reviewers,r='<div><form action="'+e.url+'" method="post">';if(n.length){r+='<textarea name="'+t+'description"></textarea><br /><br />'+'Reviewer'+' <select name="'+t+'reviewUserId">';for(let i=0;i<n.length;i++)r+='<option value="'+n[i].userId+'">'+n[i].fullName+"</option>";r+='</select><br /><br /><input type="submit" value="'+'Proceed'+'" />'}else r+='No\x20reviewers\x20were\x20found\x2e'+"<br />"+'Please\x20contact\x20the\x20administrator\x20to\x20assign\x20reviewers\x2e'+"<br /><br />";r+="</form></div>",Ae({dialog:{destroyOnHide:!0},title:r})}function Ji(e){e=e||{},Ae({dialog:{constrain:!0,modal:!0,on:{visibleChange(t){let n=this;t.newVal||n.destroy()}}},title:e.title,uri:e.url})}function Zi(e){e=e||{};let t=e.obj,n=e.pane;t&&t.checked&&(n=document.querySelector(n),n&&n.classList.remove("hide"))}function Qi(e){e=e||{};let t=document.querySelector(e.detail),n=document.querySelector(e.toggle);if(t&&n){let r=themeDisplay.getPathThemeImages()+"/arrows/01_plus.png";t.classList.contains("hide")?(t.classList.remove("hide"),r=themeDisplay.getPathThemeImages()+"/arrows/01_minus.png"):t.classList.add("hide"),n.setAttribute("src",r)}}function We(e){if(typeof e!="function")throw new TypeError("Parameter fn must be a function");let t=new Map,n=(...r)=>{let i;if(r.find(o=>typeof o=="object")){let o=r.filter(s=>typeof s=="object");i=o.map(s=>JSON.stringify(s)),r.length>1&&o.length<r.length&&r.forEach(s=>typeof s!="object"&&i.push(s)),i=i.join(",")}else i=r.length>1?r.join(","):r[0];if(t.has(i))return t.get(i);{let o=e.apply(null,r);return t.set(i,o),o}};return n.getCache=()=>t,n}var Yl=We(e=>e.split("").map(t=>t.charCodeAt()).join("")),Ge=Yl;var Sn="showTab";function to(e,t,n,r){let i=e+Ge(n),o=document.getElementById(i+"TabsId"),s=document.getElementById(i+"TabsSection");if(o&&s){let a={id:n,names:t,namespace:e,selectedTab:o,selectedTabSection:s};r&&typeof r=="function"&&r.call(this,e,t,n,a);try{Liferay.on(Sn,eo),Liferay.fire(Sn,a)}finally{Liferay.detach(Sn,eo)}}}function eo({id:e,names:t,namespace:n,selectedTab:r,selectedTabSection:i}){let o=r.querySelector("a");if(r&&o){let c=r.parentElement.querySelector(".active");c&&c.classList.remove("active"),o.classList.add("active")}i&&i.classList.remove("hide");let s=document.getElementById(n+"dropdownTitle");s&&o&&(s.innerHTML=o.textContent),t.splice(t.indexOf(e),1);let a;for(let c=0;c<t.length;c++)a=document.getElementById(n+Ge(t[c])+"TabsSection"),a&&a.classList.add("hide")}function no(e,t){e.setAttribute("title",t),e.classList.add("lfr-portal-tooltip")}function ro(e,t){return typeof e=="string"?e=t:e instanceof URL?e=new URL(t):e instanceof Request?e=new Request(t,e):console.warn("Resource passed to `fetch()` must either be a string, Request, or URL."),e}function b(e,t={}){e||(e="/o/");let n=e.url?e.url:e.toString();if(n.startsWith("/")){let s=Liferay.ThemeDisplay.getPathContext();s&&!n.startsWith(s)&&(n=s+n,e=ro(e,n)),n=window.location.origin+n}let r=new URL(n),i=new Headers({}),o={};if(r.origin===window.location.origin){i.set("x-csrf-token",Liferay.authToken),o.credentials="include";let s=Liferay.ThemeDisplay.getDoAsUserIdEncoded();s&&(r.searchParams.set("doAsUserId",s),n=r.toString(),e=ro(e,n))}return new Headers(t.headers||{}).forEach((s,a)=>{i.set(a,s)}),fetch(e,{...o,...t,headers:i})}var Jl=/^(?:p_p_id)?_(.*)_.*$/;function ke(e){return e.replace(Jl,"$1")}function ze(e){if(typeof e!="string")throw new TypeError("portletId must be a string");return`_${e}_`}var Zl=/^[a-z][a-z0-9+.-]*:/i;function Ql(e){return Zl.test(e)}function I(e,t={}){if(typeof e!="string")throw new TypeError("basePortletURL parameter must be a string");if(!t||typeof t!="object")throw new TypeError("parameters argument must be an object");let n=new Set(["doAsGroupId","doAsUserId","doAsUserLanguageId","p_auth","p_auth_secret","p_f_id","p_j_a_id","p_l_id","p_l_reset","p_p_auth","p_p_cacheability","p_p_i_id","p_p_id","p_p_isolated","p_p_lifecycle","p_p_mode","p_p_resource_id","p_p_state","p_p_state_rcv","p_p_static","p_p_url_type","p_p_width","p_t_lifecycle","p_v_l_s_g_id","refererGroupId","refererPlid","saveLastPath","scroll"]);e.indexOf(Liferay.ThemeDisplay.getPortalURL())!==0&&!Ql(e)&&(e.indexOf("/")!==0?e=`${Liferay.ThemeDisplay.getPortalURL()}/${e}`:e=Liferay.ThemeDisplay.getPortalURL()+e);let r=new URL(e),i=new URLSearchParams(r.search),o=t.p_p_id||i.get("p_p_id");if(Object.entries(t).length&&!o)throw new TypeError("Portlet ID must not be null if parameters are provided");let s="";return Object.entries(t).length&&(s=ze(o)),Object.keys(t).forEach(a=>{let c;n.has(a)?c=a:c=`${s}${a}`,i.set(c,t[a])}),r.search=i.toString(),r}var Ut,ef=new Uint8Array(16);function wn(){if(!Ut&&(Ut=typeof crypto<"u"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!Ut))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return Ut(ef)}var w=[];for(let e=0;e<256;++e)w.push((e+256).toString(16).slice(1));function io(e,t=0){return(w[e[t+0]]+w[e[t+1]]+w[e[t+2]]+w[e[t+3]]+"-"+w[e[t+4]]+w[e[t+5]]+"-"+w[e[t+6]]+w[e[t+7]]+"-"+w[e[t+8]]+w[e[t+9]]+"-"+w[e[t+10]]+w[e[t+11]]+w[e[t+12]]+w[e[t+13]]+w[e[t+14]]+w[e[t+15]]).toLowerCase()}var tf=typeof crypto<"u"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto),Tn={randomUUID:tf};function nf(e,t,n){if(Tn.randomUUID&&!t&&!e)return Tn.randomUUID();e=e||{};let r=e.random||(e.rng||wn)();if(r[6]=r[6]&15|64,r[8]=r[8]&63|128,t){n=n||0;for(let i=0;i<16;++i)t[n+i]=r[i];return t}return io(r)}var Ln=nf;var rf={EDIT:"edit",HELP:"help",VIEW:"view",MAXIMIZED:"maximized",MINIMIZED:"minimized",NORMAL:"normal",FULL:"cacheLevelFull",PAGE:"cacheLevelPage",PORTLET:"cacheLevelPortlet"};var P=rf;var vn=class e{constructor(t){S(t)?this.from(t):(this.parameters={},this.portletMode=P.VIEW,this.windowState=P.NORMAL)}clone(){return new e(this)}from(t){this.parameters={},Object.keys(t.parameters).forEach(n=>{Array.isArray(t.parameters[n])&&(this.parameters[n]=t.parameters[n].slice(0))}),this.setPortletMode(t.portletMode),this.setWindowState(t.windowState)}getPortletMode(){return this.portletMode}getValue(t,n){if(typeof t!="string")throw new TypeError("Parameter name must be a string");let r=this.parameters[t];return Array.isArray(r)&&(r=r[0]),r===void 0&&n!==void 0&&(r=n),r}getValues(t,n){if(typeof t!="string")throw new TypeError("Parameter name must be a string");let r=this.parameters[t];return r||n}getWindowState(){return this.windowState}remove(t){if(typeof t!="string")throw new TypeError("Parameter name must be a string");this.parameters[t]!==void 0&&delete this.parameters[t]}setPortletMode(t){if(typeof t!="string")throw new TypeError("Portlet Mode must be a string");(t===P.EDIT||t===P.HELP||t===P.VIEW)&&(this.portletMode=t)}setValue(t,n){if(typeof t!="string")throw new TypeError("Parameter name must be a string");if(typeof n!="string"&&n!==null&&!Array.isArray(n))throw new TypeError("Parameter value must be a string, an array or null");Array.isArray(n)||(n=[n]),this.parameters[t]=n}setValues(t,n){this.setValue(t,n)}setWindowState(t){if(typeof t!="string")throw new TypeError("Window State must be a string");(t===P.MAXIMIZED||t===P.MINIMIZED||t===P.NORMAL)&&(this.windowState=t)}};var Cn=vn;var of="0",sf="p_p_cacheability",oo="p_p_hub",af="1",cf="p_p_mode",ao="p_r_p_",bn="priv_r_p_",lf="p_p_resource_id",ne="&",ff="",X="=",df="",uf="p_p_state",co=function(e,t){let n=!1;e===void 0&&t===void 0&&(n=!0),(e===void 0||t===void 0)&&(n=!1),e.length!==t.length&&(n=!1);for(let r=e.length-1;r>=0;r--)e[r]!==t[r]&&(n=!1);return n},pf=function(e,t,n){let r=!1;if(e&&e.portlets&&e.portlets[n]){let o=e.portlets[n].state;if(!t.portletMode||!t.windowState||!t.parameters)throw new Error(`Error decoding state: ${t}`);t.porletMode!==o.portletMode||t.windowState!==o.windowState?r=!0:(Object.keys(t.parameters).forEach(c=>{let l=t.parameters[c],f=o.parameters[c];co(l,f)||(r=!0)}),Object.keys(o.parameters).forEach(c=>{t.parameters[c]||(r=!0)}))}return r},lo=function(e,t){let n=e&&e.portlets?e.portlets:{};try{let r=JSON.parse(t);r.portlets&&Object.keys(n).forEach(o=>{let s=r.portlets[o].state,a=n[o].state;if(!s||!a)throw new Error(`Invalid update string.
old state=${a}
new state=${s}`);pf(e,s,o)&&(n[o]=r.portlets[o])})}catch{}return n},hf=function(e,t){let n=[];for(let r=0;r<t.elements.length;r++){let i=t.elements[r],o=i.name,s=i.nodeName.toUpperCase(),a=s==="INPUT"?i.type.toUpperCase():"",c=i.value;if(o&&!i.disabled&&a!=="FILE"){if(s==="SELECT"&&i.multiple)[...i.options].forEach(f=>{if(f.checked){let u=f.value,d=encodeURIComponent(e+o)+"="+encodeURIComponent(u);n.push(d)}});else if(a!=="CHECKBOX"&&a!=="RADIO"||i.checked){let l=encodeURIComponent(e+o)+"="+encodeURIComponent(c);n.push(l)}}}return n.join("&")},Rt=function(e,t){let n="";return Array.isArray(t)&&(t.length?t.forEach(r=>{n+=ne+encodeURIComponent(e),r===null?n+=X+df:n+=X+encodeURIComponent(r)}):n+=ne+encodeURIComponent(e)+X+ff),n},fo=function(e,t,n){let r={credentials:"same-origin",method:"POST",url:t};if(n)if(n.enctype==="multipart/form-data"){let o=new FormData(n);r.body=o}else{let o=hf(e,n);(n.method?n.method.toUpperCase():"GET")==="GET"?(t.indexOf("?")>=0?t+=`&${o}`:t+=`?${o}`,r.url=t):(r.body=o,r.headers={"Content-Type":"application/x-www-form-urlencoded"})}return r},so=function(e,t,n,r,i){let o="";if(e.portlets&&e.portlets[t]){let s=e.portlets[t];if(s&&s.state&&s.state.parameters){let a=s.state.parameters[n];a!==void 0&&(r===ao?o+=Rt(i,a):r===bn?o+=Rt(t+bn+n,a):o+=Rt(t+n,a))}}return o},mf=function(e,t){let n="";if(e.portlets){let r=e.portlets[t];if(r.state){let i=r.state;n+=ne+cf+X+encodeURIComponent(i.portletMode),n+=ne+uf+X+encodeURIComponent(i.windowState)}}return n},gf=function(e,t,n,r){let i=!1;if(e&&e.portlets){let o=e.portlets[t];if(n.parameters[r]&&o.state.parameters[r]){let s=n.parameters[r],a=o.state.parameters[r];i=co(s,a)}}return i},uo=function(e,t,n){let r={};if(e&&e.portlets){let i=e.portlets[t];if(i&&i.pubParms){let o=i.pubParms;Object.keys(o).forEach(a=>{if(!gf(e,t,n,a)){let c=o[a];r[c]=n.parameters[a]}})}}return r},yf=function(e,t,n){let r=!1;if(e&&e.portlets){let i=e.portlets[t];i&&i.pubParms&&(r=Object.keys(i.pubParms).includes(n))}return r},Xe=function(e,t,n,r,i,o){let s="cacheLevelPage",a="",c="";if(e&&e.portlets){t==="RENDER"&&n===void 0&&(n=null);let l=e.portlets[n];if(l&&(t==="RESOURCE"?(c=decodeURIComponent(l.encodedResourceURL),i&&(s=i),c+=ne+sf+X+encodeURIComponent(s),o&&(c+=ne+lf+X+encodeURIComponent(o))):t==="RENDER"&&n!==null?c=decodeURIComponent(l.encodedRenderURL):t==="RENDER"?c=decodeURIComponent(e.encodedCurrentURL):t==="ACTION"?(c=decodeURIComponent(l.encodedActionURL),c+=ne+oo+X+encodeURIComponent(of)):t==="PARTIAL_ACTION"&&(c=decodeURIComponent(l.encodedActionURL),c+=ne+oo+X+encodeURIComponent(af)),t!=="RESOURCE"||s!=="cacheLevelFull")){if(n&&(c+=mf(e,n)),n&&(a="",l.state&&l.state.parameters)){let f=l.state.parameters;Object.keys(f).forEach(d=>{yf(e,n,d)||(a+=so(e,n,d,bn))}),c+=a}if(e.prpMap){a="";let f={};Object.keys(e.prpMap).forEach(d=>{Object.keys(e.prpMap[d]).forEach(h=>{let m=e.prpMap[d][h].split("|");Object.hasOwnProperty.call(f,d)||(f[d]=so(e,m[0],m[1],ao,d),a+=f[d])})}),c+=a}}}return r&&(a="",Object.keys(r).forEach(f=>{a+=Rt(n+f,r[f])}),c+=a),Promise.resolve(c)},Ve=function(e=[],t=0,n=1,r=[]){if(e.length<t)throw new TypeError(`Too few arguments provided: Number of arguments: ${e.length}`);if(e.length>n)throw new TypeError(`Too many arguments provided: ${[].join.call(e,", ")}`);if(Array.isArray(r)){let i=Math.min(e.length,r.length)-1;for(i;i>=0;i--){if(typeof e[i]!==r[i])throw new TypeError(`Parameter ${i} is of type ${typeof e[i]} rather than the expected type ${r[i]}`);if(e[i]===null||e[i]===void 0)throw new TypeError(`Argument is ${typeof e[i]}`)}}},po=function(e){if(!(e instanceof HTMLFormElement))throw new TypeError("Element must be an HTMLFormElement");let t=e.method?e.method.toUpperCase():void 0;if(t&&t!=="GET"&&t!=="POST")throw new TypeError(`Invalid form method ${t}. Allowed methods are GET & POST`);let n=e.enctype;if(n&&n!=="application/x-www-form-urlencoded"&&n!=="multipart/form-data")throw new TypeError(`Invalid form enctype ${n}. Allowed: 'application/x-www-form-urlencoded' & 'multipart/form-data'`);if(n&&n==="multipart/form-data"&&t!=="POST")throw new TypeError("Invalid method with multipart/form-data. Must be POST");if(!n||n==="application/x-www-form-urlencoded"){let r=e.elements.length;for(let i=0;i<r;i++)if(e.elements[i].nodeName.toUpperCase()==="INPUT"&&e.elements[i].type.toUpperCase()==="FILE")throw new TypeError("Must use enctype = 'multipart/form-data' with input type FILE.")}},Ke=function(e){if(e==null)throw new TypeError(`The parameter object is: ${typeof e}`);Object.keys(e).forEach(n=>{if(!Array.isArray(e[n]))throw new TypeError(`${n} parameter is not an array`);if(!e[n].length)throw new TypeError(`${n} parameter is an empty array`)})},ho=function(e={},t=""){return e.portlets&&Object.keys(e.portlets).includes(t)},mo=function(e={},t={}){Ke(e.parameters);let n=e.portletMode;if(typeof n!="string")throw new TypeError(`Invalid parameters. portletMode is ${typeof n}`);{let i=t.allowedPM;if(!i.includes(n.toLowerCase()))throw new TypeError(`Invalid portletMode=${n} is not in ${i}`)}let r=e.windowState;if(typeof r!="string")throw new TypeError(`Invalid parameters. windowState is ${typeof r}`);{let i=t.allowedWS;if(!i.includes(r.toLowerCase()))throw new TypeError(`Invalid windowState=${r} is not in ${i}`)}};var _f=window.history&&window.history.pushState,Ef="^portlet[.].*",A=!1,O={},re=[],_,An=class{constructor(t){this._portletId=t,this.constants={...P},_||(_=global.portlet.data.pageRenderState,this._updateHistory(!0)),this.portletModes=_.portlets[this._portletId].allowedPM.slice(0),this.windowStates=_.portlets[this._portletId].allowedWS.slice(0)}_executeAction(t,n){return new Promise((r,i)=>{Xe(_,"ACTION",this._portletId,t).then(o=>{let s=fo(this._portletId,o,n);b(s.url,s).then(a=>a.text()).then(a=>{let c=this._updatePageStateFromString(a,this._portletId);r(c)}).catch(a=>{i(a)})})})}_hasListener(t){return Object.keys(O).map(r=>O[r].id).includes(t)}_reportError(t,n){Object.keys(O).map(r=>{let i=O[r];return i.id===t&&i.type==="portlet.onError"&&setTimeout(()=>{i.handler("portlet.onError",n)}),!1})}_setPageState(t,n){if(typeof n!="string")throw new TypeError(`Invalid update string: ${n}`);this._updatePageState(n,t).then(r=>{this._updatePortletStates(r)},r=>{A=!1,this._reportError(t,r)})}_setState(t){let n=uo(_,this._portletId,t),r=[];Object.keys(n).forEach(s=>{let a=n[s],c=_.prpMap[s];Object.keys(c).forEach(f=>{if(f!==this._portletId){let u=c[f].split("|"),d=u[0],p=u[1];a===void 0?delete _.portlets[d].state.parameters[p]:_.portlets[d].state.parameters[p]=[...a],r.push(d)}})});let o=this._portletId;return _.portlets[o].state=t,r.push(o),r.forEach(s=>{_.portlets[s].renderData.content=null}),this._updateHistory(),Promise.resolve(r)}_setupAction(t,n){if(this.isInProgress())throw{message:"Operation is already in progress",name:"AccessDeniedException"};if(!this._hasListener(this._portletId))throw{message:`No onStateChange listener registered for portlet: ${this._portletId}`,name:"NotInitializedException"};return A=!0,this._executeAction(t,n).then(r=>this._updatePortletStates(r).then(i=>(A=!1,i)),r=>{A=!1,this._reportError(this._portletId,r)})}_updateHistory(t){_f&&Xe(_,"RENDER",null,{}).then(n=>{let r=JSON.stringify(_);if(t)history.replaceState(r,"");else try{history.pushState(r,"",n)}catch{}})}_updatePageState(t){return new Promise((n,r)=>{try{let i=this._updatePageStateFromString(t,this._portletId);n(i)}catch(i){r(new Error(`Partial Action decode status: ${i.message}`))}})}_updatePageStateFromString(t,n){let r=lo(_,t),i=[],o=!1;return Object.entries(r).forEach(([a,c])=>{_.portlets[a]=c,i.push(a),o=!0}),o&&n&&this._updateHistory(),i}_updatePortletStates(t){return new Promise(n=>{t.length?t.forEach(r=>{this._updateStateForPortlet(r)}):A=!1,n(t)})}_updateState(t){if(A)throw{message:"Operation in progress",name:"AccessDeniedException"};if(!this._hasListener(this._portletId))throw{message:`No onStateChange listener registered for portlet: ${this._portletId}`,name:"NotInitializedException"};A=!0,this._setState(t).then(n=>{this._updatePortletStates(n)}).catch(n=>{A=!1,this._reportError(this._portletId,n)})}_updateStateForPortlet(t){let n=re.map(i=>i.handle);Object.entries(O).forEach(([i,o])=>{o.type==="portlet.onStateChange"&&o.id===t&&!n.includes(i)&&re.push(o)}),re.length&&setTimeout(()=>{for(A=!0;re.length;){let i=re.shift(),o=i.handler,s=i.id;if(!_.portlets[s])continue;let a=_.portlets[s].renderData,c=new Cn(_.portlets[s].state);a&&a.content?o("portlet.onStateChange",c,a):o("portlet.onStateChange",c)}A=!1})}action(...t){let n=null,r=0,i=null;return t.forEach(o=>{if(o instanceof HTMLFormElement){if(i!==null)throw new TypeError(`Too many [object HTMLFormElement] arguments: ${o}, ${i}`);i=o}else if(S(o)){if(Ke(o),n!==null)throw new TypeError("Too many parameters arguments");n=o}else if(o!==void 0){let s=Object.prototype.toString.call(o);throw new TypeError(`Invalid argument type. Argument ${r+1} is of type ${s}`)}r++}),i&&po(i),this._setupAction(n,i).then(o=>{Promise.resolve(o)}).catch(o=>{Promise.reject(o)})}addEventListener(t,n){if(arguments.length>2)throw new TypeError("Too many arguments passed to addEventListener");if(typeof t!="string"||typeof n!="function")throw new TypeError("Invalid arguments passed to addEventListener");let r=this._portletId;if(t.startsWith("portlet.")&&t!=="portlet.onStateChange"&&t!=="portlet.onError")throw new TypeError(`The system event type is invalid: ${t}`);let i=Ln(),o={handle:i,handler:n,id:r,type:t};return O[i]=o,t==="portlet.onStateChange"&&this._updateStateForPortlet(this._portletId),i}createResourceUrl(t,n,r){if(arguments.length>3)throw new TypeError("Too many arguments. 3 arguments are allowed.");if(t)if(S(t))Ke(t);else throw new TypeError("Invalid argument type. Resource parameters must be a parameters object.");let i=null;if(n)if(typeof n=="string")if(n==="cacheLevelPage"||n==="cacheLevelPortlet"||n==="cacheLevelFull")i=n;else throw new TypeError(`Invalid cacheability argument: ${n}`);else throw new TypeError("Invalid argument type. Cacheability argument must be a string.");if(i||(i="cacheLevelPage"),r&&typeof r!="string")throw new TypeError("Invalid argument type. Resource ID argument must be a string.");return Xe(_,"RESOURCE",this._portletId,t,i,r)}dispatchClientEvent(t,n){if(Ve(arguments,2,2,["string"]),t.match(new RegExp(Ef)))throw new TypeError("The event type is invalid: "+t);return Object.keys(O).reduce((r,i)=>{let o=O[i];return t.match(o.type)&&(o.handler(t,n),r++),r},0)}isInProgress(){return A}newParameters(t={}){let n={};return Object.keys(t).forEach(r=>{Array.isArray(t[r])&&(n[r]=[...t[r]])}),n}newState(t){return new Cn(t)}removeEventListener(t){if(arguments.length>1)throw new TypeError("Too many arguments passed to removeEventListener");if(t==null)throw new TypeError(`The event handle provided is ${typeof t}`);let n=!1;if(S(O[t])&&O[t].id===this._portletId){delete O[t];let r=re.length;for(let i=0;i<r;i++){let o=re[i];o&&o.handle===t&&re.splice(i,1)}n=!0}if(!n)throw new TypeError("The event listener handle doesn't match any listeners.")}setRenderState(t){if(Ve(arguments,1,1,["object"]),_.portlets&&_.portlets[this._portletId]){let n=_.portlets[this._portletId];mo(t,n),this._updateState(t)}}startPartialAction(t){let n=this,r=null;if(arguments.length>1)throw new TypeError("Too many arguments. 1 arguments are allowed");if(t!==void 0)if(S(t))Ke(t),r=t;else throw new TypeError(`Invalid argument type. Argument is of type ${typeof t}`);if(A===!0)throw{message:"Operation in progress",name:"AccessDeniedException"};if(!this._hasListener(this._portletId))throw{message:`No onStateChange listener registered for portlet: ${this._portletId}`,name:"NotInitializedException"};A=!0;let i={setPageState(o){n._setPageState(n._portletId,o)},url:""};return Xe(_,"PARTIAL_ACTION",this._portletId,r).then(o=>(i.url=o,i))}};var go=An;var Sf=function(e){Ve(arguments,1,1,["string"]);let t=global.portlet.data.pageRenderState;return new Promise((n,r)=>{ho(t,e)?n(new go(e)):r(new Error("Invalid portlet ID"))})};var yo=Sf;function _o(e,t,n){n={doAsUserId:themeDisplay.getDoAsUserIdEncoded(),plid:themeDisplay.getPlid(),...n};let r=document.querySelector(e);if(r){let i=r.querySelector(".portlet-content-container");if(i){let o=i.classList.contains("d-none");if(o?(i.classList.remove("d-none"),r.classList.remove("portlet-minimized")):(i.classList.add("d-none"),r.classList.add("portlet-minimized")),t){let c=o?'Minimize':'Restore';t.setAttribute("alt",c),t.setAttribute("title",c),t.innerHTML=c;let l=t.querySelector("i");l&&(l.classList.remove("icon-minus","icon-resize-vertical"),o?(l.classList.add("icon-minus"),l.classList.remove("icon-resize-vertical")):(l.classList.add("icon-resize-vertical"),l.classList.remove("icon-minus")))}let s=ke(r.id),a=G({cmd:"minimize",doAsUserId:n.doAsUserId,p_auth:Liferay.authToken,p_l_id:n.plid,p_p_id:s,p_p_restore:o,p_v_l_s_g_id:themeDisplay.getSiteGroupId()});b(themeDisplay.getPathMain()+"/portal/update_layout",{body:a,method:"POST"}).then(c=>{if(c.ok&&o){let l={doAsUserId:n.doAsUserId,p_l_id:n.plid,p_p_boundary:!1,p_p_id:s,p_p_isolated:!0};b(I(themeDisplay.getPathMain()+"/portal/render_portlet",l)).then(f=>f.text()).then(f=>{let u=document.createRange();u.selectNode(r),r.innerHTML="";let d=u.createContextualFragment(f);r.appendChild(d)}).catch(f=>{})}}).catch(c=>{})}}}var Eo={register:yo};var xn=class{constructor(){this._disposed=!1}dispose(){this._disposed||(this.disposeInternal(),this._disposed=!0)}disposeInternal(){}isDisposed(){return this._disposed}},Nt=xn;var In=class extends Nt{constructor(t,n,r){super(),this._emitter=t,this._event=n,this._listener=r}disposeInternal(){this.removeListener(),this._emitter=null,this._listener=null}removeListener(){this._emitter.isDisposed()||this._emitter.removeListener(this._event,this._listener)}},Pn=In;var So=[0],On=class extends Nt{constructor(){super(),this._events=null,this._listenerHandlers=null,this._shouldUseFacade=!1}_addHandler(t,n){return t?(Array.isArray(t)||(t=[t]),t.push(n)):t=n,t}addListener(t,n,r){this._validateListener(n);let i=this._toEventsArray(t);for(let o=0;o<i.length;o++)this._addSingleListener(i[o],n,r);return new Pn(this,t,n)}_addSingleListener(t,n,r,i){this._runListenerHandlers(t),(r||i)&&(n={default:r,fn:n,origin:i}),this._events=this._events||{},this._events[t]=this._addHandler(this._events[t],n)}_buildFacade(t){if(this.getShouldUseFacade()){let n={preventDefault(){n.preventedDefault=!0},target:this,type:t};return n}}disposeInternal(){this._events=null}emit(t){let n=this._getRawListeners(t);if(!n.length)return!1;let r=Array.prototype.slice.call(arguments,1);return this._runListeners(n,r,this._buildFacade(t)),!0}_getRawListeners(t){return Dt(this._events&&this._events[t]).concat(Dt(this._events&&this._events["*"]))}getShouldUseFacade(){return this._shouldUseFacade}listeners(t){return this._getRawListeners(t).map(n=>n.fn?n.fn:n)}many(t,n,r){let i=this._toEventsArray(t);for(let o=0;o<i.length;o++)this._many(i[o],n,r);return new Pn(this,t,r)}_many(t,n,r){let i=this;if(n<=0)return;function o(){--n===0&&i.removeListener(t,o),r.apply(i,arguments)}i._addSingleListener(t,o,!1,r)}_matchesListener(t,n){return(t.fn||t)===n||t.origin&&t.origin===n}off(t,n){if(this._validateListener(n),!this._events)return this;let r=this._toEventsArray(t);for(let i=0;i<r.length;i++)this._events[r[i]]=this._removeMatchingListenerObjs(Dt(this._events[r[i]]),n);return this}on(){return this.addListener.apply(this,arguments)}onListener(t){this._listenerHandlers=this._addHandler(this._listenerHandlers,t)}once(t,n){return this.many(t,1,n)}removeAllListeners(t){if(this._events)if(t){let n=this._toEventsArray(t);for(let r=0;r<n.length;r++)this._events[n[r]]=null}else this._events=null;return this}_removeMatchingListenerObjs(t,n){let r=[];for(let i=0;i<t.length;i++)this._matchesListener(t[i],n)||r.push(t[i]);return r.length?r:null}removeListener(){return this.off.apply(this,arguments)}_runListenerHandlers(t){let n=this._listenerHandlers;if(n){n=Dt(n);for(let r=0;r<n.length;r++)n[r](t)}}_runListeners(t,n,r){r&&n.push(r);let i=[];for(let o=0;o<t.length;o++){let s=t[o].fn||t[o];t[o].default?i.push(s):s.apply(this,n)}if(!r||!r.preventedDefault)for(let o=0;o<i.length;o++)i[o].apply(this,n)}setShouldUseFacade(t){return this._shouldUseFacade=t,this}_toEventsArray(t){return typeof t=="string"&&(So[0]=t,t=So),t}_validateListener(t){if(typeof t!="function")throw new TypeError("Listener must be a function")}};function Dt(e){return e=e||[],Array.isArray(e)?e:[e]}var Un=On;function Rn(e,t){let n=null,r;return function(...i){let o=this,s=Date.now(),a=()=>{n=setTimeout(()=>{n=null},t),r=s,e.apply(o,i)};if(n===null)a();else{let c=Math.max(r+t-s,0);clearTimeout(n),n=setTimeout(a,c)}}}var wf={breakpoint:576,content:".sidenav-content",gutter:"12px",loadingIndicatorTPL:'<div class="loading-animation loading-animation-md"></div>',navigation:".sidenav-menu-slider",position:"left",type:"relative",typeMobile:"relative",url:null,width:"225px"},$t=new WeakMap;function me(e){if(e&&e.jquery){if(e.length>1)throw new Error(`getElement(): Expected at most one element, got ${e.length}`);e=e.get(0)}return e&&!(e instanceof HTMLElement)&&(e=e.element),e}function Nn(e){return e=me(e),$t.get(e)}var Tf=[/^aria-/,/^data-/,/^type$/];function Lf(e){if(e=me(e),e.id)return`#${e.id}`;let t=e.parentNode;for(;t&&!t.id;)t=t.parentNode;let n=Array.from(e.attributes).map(({name:r,value:i})=>Tf.some(s=>s.test(r))?`[${r}=${JSON.stringify(i)}]`:null).filter(Boolean).sort();return[t?`#${t.id} `:"",e.tagName.toLowerCase(),...n].join("")}function K(e,t,n=null){let r=new CustomEvent(t,{detail:n});e.dispatchEvent(r)}function U(e,t){C(e,{[t]:!0})}function V(e,t){C(e,{[t]:!1})}function C(e,t){e=me(e),e&&Object.entries(t).forEach(([n,r])=>{n.split(/\s+/).forEach(i=>{r?e.classList.add(i):e.classList.remove(i)})})}function v(e,t){return e=me(e),t.split(/\s+/).every(n=>e.classList.contains(n))}function T(e,t){e=me(e),e&&Object.entries(t).forEach(([n,r])=>{e.style[n]=r})}function D(e){return typeof e=="number"?e+"px":typeof e=="string"&&e.match(/^\s*\d+\s*$/)?e.trim()+"px":e}function Mt(e){let t=e.getBoundingClientRect().left,n=e.ownerDocument.defaultView.pageOffsetX||0;return t+n}var Je={};function vf(e,t){Object.keys(Je[e]).forEach(n=>{let r=!1,i=t.target;for(;i&&(r=i.matches&&i.matches(n),!r);)i=i.parentNode;r&&Je[e][n].emit("click",t)})}var xe;function Cf(){xe||(xe=Rn(()=>{K(document,"screenChange.lexicon.sidenav")},150),window.addEventListener("resize",xe))}function wo(e,t,n){if(e){Je[t]||(Je[t]={},document.addEventListener(t,a=>vf(t,a)));let r=Je[t],i=typeof e=="string"?e:Lf(e);r[i]||(r[i]=new Un);let s=r[i].on(t,a=>{a.defaultPrevented||n(a)});return{dispose(){s.dispose()}}}return null}function Ye(e){return parseInt(e,10)||0}function M(e,t){e=me(e),this.init(e,t)}M.TRANSITION_DURATION=500;M.prototype={_bindUI(){this._subscribeClickTrigger(),this._subscribeReducedMotion(),this._subscribeClickSidenavClose()},_emit(e){this._emitter.emit(e,this)},_focusNavigation(){let e=document.querySelector(this.options.container);if(!e)return;let t=e.querySelector(this.options.navigation);if(!t){e.focus();return}t.focus()},_focusTrigger(){let e=this.toggler;!e||!document.activeElement.classList.contains("sidenav-close")||e.focus()},_getSidenavWidth(){let t=this.options.widthOriginal,n=t,r=window.innerWidth;return r<t+40&&(n=r-40),n},_getSimpleSidenavType(){let e=this._getType();return this._isDesktop()&&e==="fixed-push"?"desktop-fixed-push":!this._isDesktop()&&e==="fixed-push"?"mobile-fixed-push":"fixed"},_getType(){return this._isDesktop()?this.options.type:this.options.typeMobile},_isDesktop(){return window.innerWidth>=this.options.breakpoint},_isSidenavRight(){let e=this.options,t=document.querySelector(e.container);return t?v(t,"sidenav-right"):void 0},_isSimpleSidenavClosed(){let e=this.options,t=e.openClass,n=document.querySelector(e.container);if(n)return!v(n,t)},_loadUrl(e,t){let n=this,r=e.querySelector(".sidebar-body");if(!n._fetchPromise&&r){for(;r.firstChild;)r.removeChild(r.firstChild);let i=document.createElement("div");U(i,"sidenav-loading"),i.innerHTML=n.options.loadingIndicatorTPL,r.appendChild(i),n._fetchPromise=b(t),n._fetchPromise.then(o=>{if(!o.ok)throw new Error(`Failed to fetch ${t}`);return o.text()}).then(o=>{let s=document.createRange();s.selectNode(r);let a=s.createContextualFragment(o);r.removeChild(i),r.appendChild(a),n.setHeight()}).catch(o=>{console.error(o)})}},_onClosed(){let e=this.options,t=document.querySelector(e.container);t&&(this._handleClosed||(this._handleClosed=()=>{this._getType()==="relative"&&v(t,"open")&&V(t,"sidenav-transition")},document.addEventListener("closed.lexicon.sidenav",this._handleClosed)))},_onClosedStart(){let e=this.options,t=document.querySelector(e.container),n=document.querySelector(e.content);!t||!n||this._handleClosedStart||(this._handleClosedStart=()=>{if(this._getType()==="relative"&&v(t,"open")&&n.closest(".page-maximized")){let i=document.body.scrollWidth-n.getBoundingClientRect().right,o=e.gutter+e.width,s=getComputedStyle(n).maxWidth||getComputedStyle(n).width;/px$/.test(s)&&(i=(document.body.scrollWidth-Ye(s))/2,i>e.width?o="":i>0&&i<e.width&&(o=e.gutter+e.width-i)),this.isReducedMotion()||U(t,"sidenav-transition"),T(n,{"padding-right":D(o)})}},document.addEventListener("closedStart.lexicon.sidenav",this._handleClosedStart))},_onOpen(){let e=this.options,t=document.querySelector(e.container);t&&(this._handleOpen||(this._handleOpen=()=>{this._getType()==="relative"&&v(t,"open")&&V(t,"sidenav-transition")},document.addEventListener("open.lexicon.sidenav",this._handleOpen)))},_onOpenStart(){let e=this.options,t=document.querySelector(e.container),n=document.querySelector(e.content);!t||!n||this._handleOpenStart||(this._handleOpenStart=r=>{if(this._getType()==="relative"&&v(t,"open")&&n.closest(".page-maximized")){let o=document.querySelector(r.detail.options.container+" .sidenav-menu");if(!o)return;let s=o.getBoundingClientRect().width,a=document.body.scrollWidth-n.getBoundingClientRect().right-s/2,c=a>0?e.width+e.gutter-a:e.width+e.gutter;this.isReducedMotion()||U(t,"sidenav-transition"),T(n,{"padding-right":D(c)})}},document.addEventListener("openStart.lexicon.sidenav",this._handleOpenStart))},_onScreenChange(){let e=this.options,t=document.querySelector(e.container),n=document.querySelector(e.content);if(!t||!n)return;let r=this._isDesktop();this._handleOnScreenChange||(this._handleOnScreenChange=()=>{let i=this._getType();i==="relative"&&v(t,"open")&&(this.setHeight(),this.setWidth()),this._isDesktop()!==r&&(i!=="relative"?(U(t,"sidenav-fixed"),n.style.paddingRight="",n.style.minHeight=""):V(t,"sidenav-fixed"),r=this._isDesktop())},document.addEventListener("screenChange.lexicon.sidenav",this._handleOnScreenChange))},_renderNav(){let e=this.options,t=document.querySelector(e.container),n=t.querySelector(e.navigation);if(!t||!n)return;let r=n.querySelector(".sidenav-menu"),i=v(t,"closed"),o=this._isSidenavRight(),s=this._getSidenavWidth();if(i){if(T(r,{width:D(s)}),o){let a=e.rtl?"left":"right";T(r,{[a]:D(s)})}}else this.showSidenav(),this.setHeight()},_renderUI(){let e=this.options,t=document.querySelector(e.container);if(!t)return;let n=this.toggler,r=this._getType();this.useDataAttribute||(Cf(),this._onClosedStart(),this._onClosed(),this._onOpenStart(),this._onOpen(),this._onScreenChange(),this._isDesktop()||(C(t,{closed:!0,open:!1}),C(n,{active:!1,open:!1})),e.position==="right"&&U(t,"sidenav-right"),r!=="relative"&&U(t,"sidenav-fixed"),this._renderNav()),T(t,{display:""})},_subscribeClickSidenavClose(){let e=this,n=e.options.container;if(!e._sidenavCloseSubscription){let r=`${n} .sidenav-close`;e._sidenavCloseSubscription=wo(r,"click",function(o){o.preventDefault(),e.toggle()})}},_subscribeClickTrigger(){let e=this;if(!e._togglerSubscription){let t=e.toggler;e._togglerSubscription=wo(t,"click",function(r){e.toggle(),r.preventDefault()})}},_subscribeReducedMotion(){let e=this;import(themeDisplay.getPathContext()+"/o/frontend-js-web/__liferay__/index.js").then(({isReducedMotion:t})=>{e.isReducedMotion=t})},_subscribeSidenavTransitionEnd(e,t){this.isReducedMotion()?(V(e,"sidenav-transition"),t()):setTimeout(()=>{V(e,"sidenav-transition"),t()},M.TRANSITION_DURATION)},clearHeight(){let e=this.options,t=document.querySelector(e.container);if(t){let n=t.querySelector(e.content),r=t.querySelector(e.navigation),i=t.querySelector(".sidenav-menu");[n,r,i].forEach(o=>{T(o,{height:"","min-height":""})})}},destroy(){let e=this;e._sidenavCloseSubscription&&(e._sidenavCloseSubscription.dispose(),e._sidenavCloseSubscription=null),e._togglerSubscription&&(e._togglerSubscription.dispose(),e._togglerSubscription=null),$t.delete(e.toggler),document.removeEventListener("closedStart.lexicon.sidenav",e._handleClosedStart),document.removeEventListener("closed.lexicon.sidenav",e._handleClosed),document.removeEventListener("openStart.lexicon.sidenav",e._handleOpenStart),document.removeEventListener("open.lexicon.sidenav",e._handleOpen),document.removeEventListener("screenChange.lexicon.sidenav",e._handleOnScreenChange),xe&&(window.removeEventListener("resize",xe),xe=null)},hide(){this.useDataAttribute?this.hideSimpleSidenav():this.toggleNavigation(!1)},hideSidenav(){let e=this,t=e.options,n=document.querySelector(t.container);if(n){let r=n.querySelector(t.content),i=n.querySelector(t.navigation),o=i.querySelector(".sidenav-menu"),s=e._isSidenavRight(),a=t.rtl?"right":"left";s&&(a=t.rtl?"left":"right");let c="padding-"+a;T(r,{[c]:"",[a]:""}),T(i,{width:""}),s&&T(o,{[a]:D(e._getSidenavWidth())}),e._subscribeSidenavTransitionEnd(o,()=>{e._focusTrigger()})}},hideSimpleSidenav(){let e=this,t=e.options;if(!e._isSimpleSidenavClosed()){let r=document.querySelector(t.container),i=document.querySelector(t.content);if(!r||!i)return;let o=t.closedClass,s=t.openClass,a=e.toggler,c=a.dataset.target||a.getAttribute("href");e._emit("closedStart.lexicon.sidenav"),K(document,"closedStart.lexicon.sidenav",e),e._subscribeSidenavTransitionEnd(i,()=>{V(r,"sidenav-transition"),V(a,"sidenav-transition"),e._emit("closed.lexicon.sidenav"),K(document,"closed.lexicon.sidenav",e),e._focusTrigger()});let l=e.isReducedMotion();v(i,s)&&C(i,{[o]:!0,[s]:!1,"sidenav-transition":!l}),l||(U(r,"sidenav-transition"),U(a,"sidenav-transition")),C(r,{[o]:!0,[s]:!1});let f=document.querySelectorAll(`[data-target="${c}"], [href="${c}"]`);Array.from(f).forEach(u=>{C(u,{active:!1,[s]:!1}),C(u,{active:!1,[s]:!1})})}},init(e,t){let n=e.dataset.toggle==="liferay-sidenav";t={...wf,...t},t.breakpoint=Ye(t.breakpoint),t.container=t.container||e.dataset.target||e.getAttribute("href"),t.gutter=Ye(t.gutter),t.rtl=document.dir==="rtl",t.width=Ye(t.width),t.widthOriginal=t.width,n&&(t.closedClass=e.dataset.closedClass||"closed",t.content=e.dataset.content,t.loadingIndicatorTPL=e.dataset.loadingIndicatorTpl||t.loadingIndicatorTPL,t.openClass=e.dataset.openClass||"open",t.type=e.dataset.type,t.typeMobile=e.dataset.typeMobile,t.url=e.dataset.url,t.width=""),this.toggler=e,this.options=t,this.useDataAttribute=n,this._emitter=new Un,this._bindUI(),this._renderUI()},on(e,t){return this._emitter.on(e,t)},setHeight(){let e=this.options,t=document.querySelector(e.container);if(!t)return;let n=this._getType();if(n!=="fixed"&&n!=="fixed-push"){let r=t.querySelector(e.content),i=t.querySelector(e.navigation),o=t.querySelector(".sidenav-menu"),s=r.closest(".page-maximized")?window.innerHeight-o.getBoundingClientRect().top:r.getBoundingClientRect().height,a=i.getBoundingClientRect().height,c=D(Math.max(s,a));T(r,{"min-height":c}),T(i,{height:"100%","min-height":c}),T(o,{height:"100%","min-height":c})}},setWidth(){let e=this.options,t=document.querySelector(e.container),n=t.querySelector(e.content),r=t.querySelector(e.navigation);if(!t||!n||!r)return;let i=r.querySelector(".sidenav-menu"),o=this._isSidenavRight(),s=this._getSidenavWidth(),a=s+e.gutter,c=e.url;c&&this._loadUrl(i,c),T(r,{width:D(s)}),T(i,{width:D(s)});let l=e.rtl?"right":"left";o&&(l=e.rtl?"left":"right");let f="padding-"+l,u=this._isDesktop()?f:l,d=this._getType();if(d!=="relative"&&U(t,"sidenav-fixed"),d!=="fixed"){let p=v(t,"open")?Mt(r)-e.gutter:Mt(r)-a,h=Mt(n),E=Ye(getComputedStyle(n).width),m="";e.rtl&&o||!e.rtl&&e.position==="left"?(p=Mt(r)+a,p>h&&(m=p-h)):(e.rtl&&e.position==="left"||!e.rtl&&o)&&p<h+E&&(m=h+E-p,m>=a&&(m=a)),T(n,{[u]:D(m)})}},show(){this.useDataAttribute?this.showSimpleSidenav():this.toggleNavigation(!0)},showSidenav(){let e=this,t=e.options,n=document.querySelector(t.container),r=n.querySelector(t.navigation);if(!n||!r)return;let i=r.querySelector(".sidenav-menu"),o=t.url;o&&e._loadUrl(i,o),e.setWidth(),e._subscribeSidenavTransitionEnd(i,()=>{e._focusNavigation()})},showSimpleSidenav(){let e=this,t=e.options;if(e._isSimpleSidenavClosed()){let r=document.querySelector(t.container),i=document.querySelector(t.content);if(!r||!i)return;let o=t.closedClass,s=t.openClass,a=e.toggler,c=a.dataset.url;c&&e._loadUrl(r,c),e._emit("openStart.lexicon.sidenav"),K(document,"openStart.lexicon.sidenav",e);let l=e.isReducedMotion();C(i,{[o]:!1,[s]:!0,"sidenav-transition":!l}),C(r,{[o]:!1,[s]:!0,"sidenav-transition":!l}),C(a,{active:!0,[s]:!0,"sidenav-transition":!l}),e._subscribeSidenavTransitionEnd(i,()=>{l||(V(r,"sidenav-transition"),V(a,"sidenav-transition")),e._emit("open.lexicon.sidenav"),K(document,"open.lexicon.sidenav",e),this._focusNavigation()})}},toggle(){this.useDataAttribute?this.toggleSimpleSidenav():this.toggleNavigation()},toggleNavigation(e){let t=this,n=t.options,r=t._getType(),i=document.querySelector(n.container),o=i.querySelector(".sidenav-menu");if(!i||!o)return;let s=t.toggler,a=n.width,c=typeof e=="boolean"?e:v(i,"closed"),l=t._isSidenavRight();if(c?(t._emit("openStart.lexicon.sidenav"),K(document,"openStart.lexicon.sidenav",t)):(t._emit("closedStart.lexicon.sidenav"),K(document,"closedStart.lexicon.sidenav",t)),t._subscribeSidenavTransitionEnd(i,()=>{let f=i.querySelector(".sidenav-menu");v(i,"closed")?(t.clearHeight(),C(s,{open:!1,"sidenav-transition":!1}),t._emit("closed.lexicon.sidenav"),K(document,"closed.lexicon.sidenav",t)):(C(s,{open:!0,"sidenav-transition":!1}),t._emit("open.lexicon.sidenav"),K(document,"open.lexicon.sidenav",t)),t._isDesktop()||f.focus()}),c){r==="relative"&&t.setHeight(),T(o,{width:D(a)});let f=n.rtl?"left":"right";l&&T(o,{[f]:""})}t.isReducedMotion()||(U(i,"sidenav-transition"),U(s,"sidenav-transition")),c?t.showSidenav():t.hideSidenav(),C(i,{closed:!c,open:c}),C(s,{active:c,open:c})},toggleSimpleSidenav(){this._isSimpleSidenavClosed()?this.showSimpleSidenav():this.hideSimpleSidenav()},visible(){let e;if(this.useDataAttribute)e=this._isSimpleSidenavClosed();else{let t=document.querySelector(this.options.container);if(!t)return;e=v(t,"sidenav-transition")?!v(t,"closed"):v(t,"closed")}return!e}};M.destroy=function(t){let n=Nn(t);n&&n.destroy()};M.hide=function(t){let n=Nn(t);n&&n.hide()};M.initialize=function(t,n={}){t=me(t);let r=$t.get(t);return r||(r=new M(t,n),$t.set(t,r)),r};M.instance=Nn;function To(){let e=document.querySelectorAll('[data-toggle="liferay-sidenav"]');Array.from(e).forEach(M.initialize)}document.readyState!=="loading"?To():document.addEventListener("DOMContentLoaded",()=>{To()});var Lo=M;var vo={BAD_REQUEST:400,INTERNAL_SERVER_ERROR:500,OK:200,SC_DUPLICATE_FILE_EXCEPTION:490,SC_FILE_ANTIVIRUS_EXCEPTION:494,SC_FILE_CUSTOM_EXCEPTION:499,SC_FILE_EXTENSION_EXCEPTION:491,SC_FILE_NAME_EXCEPTION:492,SC_FILE_SIZE_EXCEPTION:493,SC_UPLOAD_REQUEST_SIZE_EXCEPTION:495};function Dn(e,t){if(!e||typeof e!="object"&&typeof e!="string")throw new TypeError("Parameter params must be an object or string");if(typeof t!="string")throw new TypeError("Parameter baseUrl must be a string");let n=t.startsWith("/")?new URL(t,location.href):new URL(t);return typeof e=="object"?Object.entries(e).forEach(([r,i])=>{n.searchParams.append(r,i)}):new URLSearchParams(e.trim()).forEach((i,o)=>{i?n.searchParams.append(o,i):n.searchParams.append(o,"")}),n.toString()}function Mn(e){if(typeof e!="function")throw new TypeError("Parameter callback must be a function");Liferay.Service("/country/get-company-countries",{active:!0,companyId:Liferay.ThemeDisplay.getCompanyId()},e)}function $n(e,t){if(typeof e!="function")throw new TypeError("Parameter callback must be a function");if(typeof t!="string")throw new TypeError("Parameter selectKey must be a string");Liferay.Service("/region/get-regions",{active:!0,countryId:parseInt(t,10)},e)}var Ie={FUNCTIONAL:"CONSENT_TYPE_FUNCTIONAL",NECESSARY:"CONSENT_TYPE_NECESSARY",PERFORMANCE:"CONSENT_TYPE_PERFORMANCE",PERSONALIZATION:"CONSENT_TYPE_PERSONALIZATION"};function ge(e){return e===Ie.NECESSARY||Hn(e,Ie.NECESSARY)!=="false"}var Co=(e,t,n={})=>{let r=`${e}=${t}`;n.path||(r+="; path=/"),!n.expires&&!("max-age"in n)&&(r+=`; max-age=${365*24*60*60}`);for(let[i,o]of Object.entries(n))o!==!1&&(o===!0?r+=`; ${i}`:r+=`; ${i}=${o}`);return r};function Hn(e,t){if(ge(t))return document.cookie.split("; ").find(n=>n.startsWith(`${e}=`))?.split("=")[1]}function bf(e){document.cookie=Co(e,"",{"max-age":0})}function Af(e,t,n,r){return ge(n)?(document.cookie=Co(e,t,r),!0):!1}var bo={TYPES:Ie,get:Hn,remove:bf,set:Af};function Ze(e){return e._node||e._nodes?e.nodeType?e:e._node||null:e}function ie(e){let t=Ze(e);return typeof t=="string"?document.querySelector(t):t.jquery?t[0]:t}function Pe(e,t,n){let r=!1;if(e=ie(e),e){n||(n=e.getBoundingClientRect(),n={left:n.left+window.scrollX,top:n.top+window.scrollY},n.bottom=n.top+e.offsetHeight,n.right=n.left+e.offsetWidth),t||(t=window),t=ie(t);let i={};if(i.left=t.scrollX,i.right=i.left+t.innerWidth,i.top=t.scrollY,i.bottom=i.top+t.innerHeight,r=n.bottom<=i.bottom&&n.left>=i.left&&n.right<=i.right&&n.top>=i.top,r){let o=t.frameElement;if(o){let s=o.getBoundingClientRect();s={left:s.left+window.scrollX,top:s.top+window.scrollY};let a=s.left-i.left;n.left+=a,n.right+=a;let c=s.top-i.top;n.top+=c,n.bottom+=c,r=Pe(e,t.parent,n)}}}return r}function xf(e){let t=[];for(;e.parentElement;)e.parentElement.getAttribute("disabled")&&t.push(e.parentElement),e=e.parentElement;return t}function jn(e){if(e=ie(e),Pe(e)){let t=xf(e),n=!e.getAttribute("disabled")&&e.offsetWidth>0&&e.offsetHeight>0&&!t.length,r=e.closest("form");if(!r||n)e.focus();else if(r){let o=r.dataset.fmNamespace+"formReady",s=a=>{let c=r.getAttribute("name"),l=a.formName;c===l&&(e.focus(),Liferay.detach(o,s))};Liferay.on(o,s)}}}function Qe(e,t){let n=null;if(e!==void 0&&e.nodeName==="FORM"&&typeof t=="string"){let r=e.dataset.fmNamespace||"";n=e.elements[r+t]||null}return n}function et(e,t){if(e===void 0||e.nodeName!=="FORM"||!S(t))return;Object.entries(t).forEach(([r,i])=>{let o=Qe(e,r);o&&(o.value=i)})}function Fn(e,t){if(typeof e=="string"&&(e=document.querySelector(e)),e&&e.nodeName==="FORM")if(e.setAttribute("method","post"),S(t)){let{data:n,url:r}=t;if(S(n))et(e,n);else return;r===void 0?submitForm(e):typeof r=="string"&&submitForm(e,r)}else submitForm(e)}var If={addSpaceBeforeSuffix:!1,decimalSeparator:".",denominator:1024,suffixGB:"GB",suffixKB:"KB",suffixMB:"MB"};function Bn(e,t={}){let{addSpaceBeforeSuffix:n,decimalSeparator:r,denominator:i,suffixGB:o,suffixKB:s,suffixMB:a}={...If,...t};if(typeof e!="number")throw new TypeError("Parameter size must be a number");let c=0,l=s;e/=i,e>=i&&(l=a,e/=i,c=1),e>=i&&(l=o,e/=i,c=1);let f=e.toFixed(c);return r!=="."&&(f=f.replace(/\./,r)),f+(n?" ":"")+l}var Pf=`\r
`,Ao=/<!\[CDATA\[.*?\]\]>/gs,xo=/-->|\]>/,Of=/<!/,Uf=/<\?/,Rf=/!DOCTYPE/,Nf=/^<\w/,Df=/^<\/\w/,Mf=/^<[\w:\-.,]+/,$f=/^<\/[\w:\-.,]+/,Io=/<\w/,Hf=/xmlns(?::|=)/g,jf=/\s*(xmlns)(:|=)/g,qn=/<\//,Ff=/</g,Po=/\/>/,Bf=/>\s+</g,qf="",tt="~::~",Oo="<"+tt+"CDATA"+tt+">",Wf=new RegExp(Oo,"g"),Gf="	",kf={newLine:Pf,tagIndent:Gf};function Wn(e,t={}){let{newLine:n,tagIndent:r}={...kf,...t};if(typeof e!="string")throw new TypeError("Parameter content must be a string");let i=[];e=e.trim(),e=e.replace(Ao,f=>(i.push(f),Oo)),e=e.replace(Bf,"><"),e=e.replace(Ff,tt+"<"),e=e.replace(jf,tt+"$1$2"),e=e.replace(Wf,()=>i.shift());let o=0,s=!1,a=e.split(tt),c=0,l="";return a.forEach((f,u)=>{Ao.test(f)?l+=oe(c,n,r)+f:Of.test(f)?(l+=oe(c,n,r)+f,o++,s=!0,(xo.test(f)||Rf.test(f))&&(o--,s=o!==0)):xo.test(f)?(l+=f,o--,s=o!==0):Nf.exec(a[u-1])&&Df.exec(f)&&Mf.exec(a[u-1]).toString()===$f.exec(f)[0].replace("/",qf).toString()?(l+=f,s||--c):Io.test(f)&&!qn.test(f)&&!Po.test(f)?s?l+=f:l+=oe(c++,n,r)+f:Io.test(f)&&qn.test(f)?s?l+=f:l+=oe(c,n,r)+f:qn.test(f)?s?l+=f:l+=oe(--c,n,r)+f:Po.test(f)?s?l+=f:l+=oe(c,n,r)+f:Uf.test(f)||Hf?l+=oe(c,n,r)+f:l+=f,new RegExp("^"+n).test(l)&&(l=l.slice(n.length))}),l}function oe(e,t,n){return t+new Array(e+1).join(n)}function Uo(e,t,n,r){typeof e=="string"?e=document.querySelector(e):e=e._node||e;let i="input[type=checkbox]";n&&(i+=`[name=${n}]`);let o=Array.from(e.querySelectorAll(i));return o.length?o.reduce((s,a)=>{let{checked:c,disabled:l,name:f,value:u}=a;return u&&f!==t&&c===r&&!l&&s.push(u),s},[]).join():""}function Ro(e,t,n){return Uo(e,t,n,!0)}function No(e,t,n){return Uo(e,t,n,!1)}function Gn(e,t){if(!S(e)||S(e)&&e.tagName!=="IMG")throw new TypeError("Parameter imagePreview must be an image");if(!S(t))throw new TypeError("Parameter region must be an object");let n=e.naturalWidth/e.offsetWidth,r=e.naturalHeight/e.offsetHeight,i=t.height?t.height*r:e.naturalHeight,o=t.width?t.width*n:e.naturalWidth,s=t.x?Math.max(t.x*n,0):0,a=t.y?Math.max(t.y*r,0):0;return{height:i,width:o,x:s,y:a}}function kn(e,t,n){e&&navigator.geolocation?navigator.geolocation.getCurrentPosition(r=>{e(r.coords.latitude,r.coords.longitude,r)},t,n):t&&t()}function nt(e,t=""){if(!e)throw new TypeError("Parameter icon must be provided");function n(o,s){return`<svg
				aria-hidden="true"
				class="lexicon-icon lexicon-icon-${o} ${s}"
				focusable="false"
				role="presentation"
			>
				<use href="${Liferay.Icons.spritemap}#${o}" />
			</svg>`}let r=n(e,t),i=document.createElement("div");return i.innerHTML=r,i.firstChild}function zn(e,t=""){return`<svg aria-hidden="true" class="lexicon-icon lexicon-icon-${e} ${t}" focusable="false" role="presentation"><use href="${Liferay.Icons.spritemap}#${e}" /></svg>`}var Do;function Xn(){let e=Do;if(!e){let t=z().Liferay.Util,n=window.name,r=t.Window.getById(n);r&&(e=r._opener,Do=e)}return e||window.opener||window.parent}function Vn(e,t=","){return Array.from(e.getElementsByTagName("option")).reduce((r,i)=>{let{value:o}=i;return o&&r.push(o),r},[]).join(t)}function Kn(e){if(!themeDisplay.isAddSessionIdToURL())return e;let t=e.indexOf(";");if(t>-1)return e;let n=`;jsessionid=${themeDisplay.getSessionId()}`;if(t=e.indexOf("?"),t>-1)return`${e.substring(0,t)}${n}${e.substring(t)}`;if(t=e.indexOf("//"),t>-1){let r=e.lastIndexOf("/");if(t+1===r)return`${e}/${n}`}return`${e}${n}`}function Yn(e=window.name){return z().Liferay.Util.Window.getById(e)}function Jn(){return window.innerWidth<be.PHONE}function Zn(){return window.innerWidth<be.TABLET}var ye=class{constructor(t){rt(this,"TYPES",Ie);this.storage=t}clear(){return this.storage.clear()}getItem(t,n){return ge(n)?this.storage.getItem(t):null}key(t,n){return ge(n)?this.storage.key(t):null}removeItem(t){return this.storage.removeItem(t)}setItem(t,n,r){return ge(r)?(this.storage.setItem(t,n),!0):!1}get length(){return this.storage.length}};var Mo=new ye(localStorage);function $o(e,t){let n=e;e?.constructor?.name==="URL"&&(n=String(e)),Liferay.SPA?.app?.canNavigate(n)?(Liferay.SPA.app.navigate(n),t&&Object.keys(t).forEach(r=>{Liferay.once(r,t[r])})):zf(n)&&(window.location.href=n)}function zf(e){let t;try{e.startsWith("/")?t=new URL(e,window.location.origin):t=new URL(e)}catch{return!1}return t.protocol==="http:"||t.protocol==="https:"}function Qn(e){if(typeof e!="string")throw new TypeError("parameter text must be a string");return e.replace(/[^a-z0-9_-]/gi,"-").replace(/^-+/,"").replace(/--+/,"-").toLowerCase()}var Ho=We((e,t)=>(typeof t<"u"&&t.lastIndexOf(e,0)!==0&&(t=`${e}${t}`),t));function er(e,t){let n;return typeof t!="object"?n=Ho(e,t):(n={},Object.keys(t).forEach(i=>{let o=i;i=Ho(e,i),n[i]=t[o]})),n}function tr(e){if(!S(e))throw new TypeError("Parameter obj must be an object");let t=new URLSearchParams;return Object.entries(e).forEach(([n,r])=>{if(Array.isArray(r))for(let i=0;i<r.length;i++)t.append(n,r[i]);else t.append(n,r)}),t}var jo=new Map;function Fo(e){return jo.get(e)}function Bo(e,t){jo.set(e,t)}function nr(e,t={}){return I(e,{...t,p_p_lifecycle:"1"})}function rr(e,t={}){return I(e,{...t,p_p_lifecycle:"0"})}function ir(e,t={}){return I(e,{...t,p_p_lifecycle:"2"})}function or(e,t,n,r){let i=document.getElementById(`${r}${e}`);i&&(i.value=0);let o=document.getElementById(`${r}${t}`);o&&(o.value=""),k(n,!0),Liferay.fire("entitySelectionRemoved")}function Xf(e,t,n){let{text:r,type:i}=e,o=document.createElement("script");Liferay.CSP.nonce&&o.setAttribute("nonce",Liferay.CSP.nonce),o.text=r,o.type=i,n?n(o):document.head.appendChild(o),o.remove(),t()}function Vf(e,t,n){let{src:r,type:i}=e,o=document.createElement("script");Liferay.CSP.nonce&&o.setAttribute("nonce",Liferay.CSP.nonce),o.src=r,o.type=i;let s=function(){o.remove(),t()};o.addEventListener("load",s,{once:!0}),o.addEventListener("error",s,{once:!0}),n?n(o):document.head.appendChild(o)}function qo(e,t,n,r){let i=e[t],o=()=>{t<e.length-1?qo(e,t+1,n,r):n&&setTimeout(n)};if(i)i.type&&i.type!=="text/javascript"&&i.type!=="module"&&i.type!=="module-shim"?o():(i.remove(),i.src?Vf(i,o,r):Xf(i,o,r));else return}function Wo(e,t,n){let r=e.querySelectorAll("script");if(!r.length&&t){setTimeout(t);return}qo(r,0,t,n)}function sr(e,t){let n=document.getElementById(`${t}${e.idString}`);n&&(n.value=e.idValue);let r=document.getElementById(`${t}${e.nameString}`);r&&(r.value=Liferay.Util.unescape(e.nameValue));let i=document.getElementById(`${t}removeFolderButton`);i&&k(i,!1)}var ar="serialize://";function Go(e){let t=Liferay.ThemeDisplay.getDoAsUserIdEncoded(),n=new FormData;return n.append("cmd",e),n.append("p_auth",Liferay.authToken),t&&n.append("doAsUserId",t),n}function ko(){return`${Liferay.ThemeDisplay.getPortalURL()}${Liferay.ThemeDisplay.getPathMain()}/portal/session_click`}function zo(e,t={}){let n=Go("get");return n.append("key",e),t.useHttpSession&&n.append("useHttpSession",!0),b(ko(),{body:n,method:"POST"}).then(r=>r.text()).then(r=>{if(r.startsWith(ar)){let i=r.substring(ar.length);r=JSON.parse(i)}return r})}function Ht(e,t,n={}){let r=Go("set");return t&&typeof t=="object"&&(t=ar+JSON.stringify(t)),r.append(e,t),n.useHttpSession&&r.append("useHttpSession",!0),b(ko(),{body:r,method:"POST"})}var Xo=new ye(sessionStorage);function cr(e,t){let n=document.getElementById(t);n&&(n.style.display="none",e.getModifierState("CapsLock")&&(n.style.display=""))}var Kf=/({\d+})/g;function lr(e,...t){let n=t.reduce((i,o)=>Array.isArray(o)?[...i,...o]:[...i,o],[]),r=e.split(Kf).filter(i=>i.length!==0);for(let i=0;i<n.length;i++){let o=n[i],s=`{${i}}`,a=r.indexOf(s);for(;a>=0;)r.splice(a,1,o),a=r.indexOf(s)}return r.some(i=>i&&typeof i=="object")?r:r.join("")}function fr(e,t,n,r){let i=document.getElementById(e),o=document.getElementById(t);if(i&&o){let s=i.checked;n&&(s=!s),s?o.classList.remove("hide"):o.classList.add("hide"),i.addEventListener("click",()=>{o.classList.toggle("hide"),r&&o.querySelectorAll("input[type=checkbox]").forEach(c=>{c.checked=i.checked})})}}var Vo={false:{cssClass:"controls-hidden",iconCssClass:"hidden",state:"hidden"},true:{cssClass:"controls-visible",iconCssClass:"view",state:"visible"}};function dr(e){let t=document.body;e=e._node||t;let n=e.querySelector(".toggle-controls");if(!n)return;let r=Liferay._editControlsState==="visible",i=Vo[r],o=n.querySelector(".lexicon-icon");o&&(i.icon=o),t.classList.add(i.cssClass),Liferay.fire("toggleControls",{enabled:r}),n.addEventListener("click",()=>{r=!r;let s=i;i=Vo[r],t.classList.toggle(s.cssClass),t.classList.toggle(i.cssClass);let a=i.iconCssClass,c=i.state,l=nt(a);i.icon=l,o.replaceWith(l),o=l,Liferay._editControlsState=c,Ht("com.liferay.frontend.js.web_toggleControls",c),Liferay.fire("toggleControls",{enabled:r,src:"ui"})})}function ur(e,t,n){let r=document.getElementById(e);if(r){let i;t&&(Array.isArray(t)&&(t=t.join(",#")),i=document.querySelectorAll(`#${t}`),i.forEach(o=>{r.checked?o.classList.remove("hide"):o.classList.add("hide")})),r.addEventListener("change",()=>{i&&i.forEach(o=>{o.classList.remove("hide")}),n&&(Array.isArray(n)&&(n=n.join(",#")),document.querySelectorAll(`#${n}`).forEach(s=>{s.classList.add("hide")}))})}}var Ko=(e,t,n,r)=>{let i=e.value,o=n?r(i,r):r===i;t.classList.toggle("hide",!o)};function pr(e,t,n){let r=document.getElementById(e),i=document.getElementById(n);if(!r||!i)return;let o=typeof t=="function";Ko(r,i,o,t),r.addEventListener("change",()=>Ko(r,i,o,t))}var Yo={ALERT:430,DOCK:10,DOCK_PARENT:20,DRAG_ITEM:460,DROP_AREA:440,DROP_POSITION:450,MENU:5e3,OVERLAY:1e3,POPOVER:1600,TOOLTIP:1e4,WINDOW:1200};var se=Liferay.ThemeDisplay.getPathContext();Liferay=window.Liferay||{};Liferay.BREAKPOINTS=be;Liferay.STATUS_CODE=vo;Liferay.zIndex=Yo;Liferay.component=Bi;Liferay.componentReady=_n;Liferay.destroyComponent=En;Liferay.destroyComponents=qi;Liferay.destroyUnfulfilledPromises=Wi;Liferay.getComponentCache=Gi;Liferay.initComponentCache=ki;Liferay.Address={getCountries:Mn,getRegions:$n};Liferay.DynamicSelect=qe;Liferay.LayoutExporter={all:Vi,details:Qi,icons:Ki(),proposeLayout:Yi,publishToLive:Ji,selected:Zi};Liferay.Portal={Tabs:{show:to},ToolTip:{show:no}};Liferay.Portlet=Liferay.Portlet||{};Liferay.Portlet.minimize=_o;Liferay.Portlet.openModal=(...e)=>{import(se+"/o/frontend-js-web/__liferay__/index.js").then(({openPortletModal:t})=>t(...e))};Liferay.Portlet.openWindow=(...e)=>{import(se+"/o/frontend-js-web/__liferay__/index.js").then(({openPortletWindow:t})=>t(...e))};Liferay.SideNavigation=Lo;Liferay.Util=Liferay.Util||{};Liferay.Util.MAP_HTML_CHARS_ESCAPED=Be;Liferay.Util.addParams=Dn;Liferay.Util.openAlertModal=(...e)=>{import(se+"/o/frontend-js-web/__liferay__/index.js").then(({openAlertModal:t})=>t(...e))};Liferay.Util.openSimpleInputModal=(...e)=>{import(se+"/o/frontend-js-web/__liferay__/index.js").then(({openSimpleInputModal:t})=>t(...e))};Liferay.Util.AutoSize=$i;Liferay.Util.debounce=zi;Liferay.Util.delegate=Pt;Liferay.Util.DynamicInlineScroll=Ri;Liferay.Util.runScriptsInElement=Wo;Liferay.Util.disableEsc=()=>{document.all&&window.event.keyCode===27&&(window.event.returnValue=!1)};var Yf={'"':"&quot;","&":"&amp;","'":"&#39;","<":"&lt;",">":"&gt;"},Qo=/[&<>"']/g,Jf=RegExp(Qo.source);Liferay.Util.escape=e=>e&&Jf.test(e)?e.replace(Qo,t=>Yf[t]):e||"";Liferay.Util.escapeHTML=pe;Liferay.Util.fetch=b;Liferay.Util.focusFormField=jn;Liferay.Util.formatStorage=Bn;Liferay.Util.formatXML=Wn;Liferay.Util.getCheckedCheckboxes=Ro;Liferay.Util.getUncheckedCheckboxes=No;Liferay.Util.getCropRegion=Gn;Liferay.Util.getDOM=Ze;Liferay.Util.getElement=ie;Liferay.Util.getGeolocation=kn;Liferay.Util.getFormElement=Qe;Liferay.Util.getLexiconIcon=nt;Liferay.Util.getLexiconIconTpl=zn;Liferay.Util.getOpener=Xn;Liferay.Util.getPortletConfigurationIconAction=Fo;Liferay.Util.getPortletId=ke;Liferay.Util.getPortletNamespace=ze;Liferay.Util.getSelectedOptionValues=Vn;Liferay.Util.getTop=z;Liferay.Util.getURLWithSessionId=Kn;Liferay.Util.getWindow=Yn;Liferay.Util.groupBy=Jo.default;Liferay.Util.inBrowserView=Pe;Liferay.Util.isEqual=Zo.default;Liferay.Util.isPhone=Jn;Liferay.Util.isTablet=Zn;Liferay.Util.loadClientExtensions=Fe;Liferay.Util.loadEditorClientExtensions=pn;Liferay.Util.navigate=$o;Liferay.Util.ns=er;Liferay.Util.objectToFormData=G;Liferay.Util.objectToURLSearchParams=tr;Liferay.Util.normalizeFriendlyURL=Qn;Liferay.Util.PortletURL={createActionURL:nr,createPortletURL:I,createRenderURL:rr,createResourceURL:ir};Liferay.Util.postForm=Fn;Liferay.Util.setFormValues=et;Liferay.Util.toCharCode=Ge;Liferay.Util.toggleDisabled=k;Liferay.Util.openConfirmModal=(...e)=>{import(se+"/o/frontend-js-web/__liferay__/index.js").then(({openConfirmModal:t})=>t(...e))};Liferay.Util.openModal=(...e)=>{import(se+"/o/frontend-js-web/__liferay__/index.js").then(({openModal:t})=>t(...e))};Liferay.Util.openSelectionModal=(...e)=>{import(se+"/o/frontend-js-web/__liferay__/index.js").then(({openSelectionModal:t})=>t(...e))};Liferay.Util.openToast=(...e)=>{import(se+"/o/frontend-js-web/__liferay__/index.js").then(({openToast:t})=>t(...e))};Liferay.Util.openWindow=Ae;Liferay.Util.removeEntitySelection=or;Liferay.Util.selectFolder=sr;Liferay.Util.setPortletConfigurationIconAction=Bo;Liferay.Util.showCapsLock=cr;Liferay.Util.sub=lr;Liferay.Util.Session={get:zo,set:Ht};Liferay.Util.toggleBoxes=fr;Liferay.Util.toggleControls=dr;Liferay.Util.toggleRadio=ur;Liferay.Util.toggleSelectBox=pr;var Zf={"&#39;":"'","&amp;":"&","&gt;":">","&lt;":"<","&quot;":'"'},es=/&(?:amp|lt|gt|quot|#(0+)?39);/g,Qf=RegExp(es.source);Liferay.Util.unescape=e=>e&&Qf.test(e)?e.replace(es,t=>Zf[t]||"'"):e||"";Liferay.Util.unescapeHTML=Ni;Liferay.Util.Cookie=bo;Liferay.Util.LocalStorage=Mo;Liferay.Util.SessionStorage=Xo;window.portlet=Eo;})();


