Liferay.Loader.define("frontend-js-web@5.0.31/liferay/util/portlet_url/create_portlet_url.es",["module","exports","require","../get_portlet_namespace.es"],(function(e,t,r){var _;window;{Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(t,r={}){if("string"!=typeof t)throw new TypeError("basePortletURL parameter must be a string");if(!r||"object"!=typeof r)throw new TypeError("parameters argument must be an object");const _=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"]);0===t.indexOf(Liferay.ThemeDisplay.getPortalURL())||(p=t,e.test(p))||(t=0!==t.indexOf("/")?"".concat(Liferay.ThemeDisplay.getPortalURL(),"/").concat(t):Liferay.ThemeDisplay.getPortalURL()+t);var p;const o=new URL(t),s=new URLSearchParams(o.search),i=r.p_p_id||s.get("p_p_id");if(Object.entries(r).length&&!i)throw new TypeError("Portlet ID must not be null if parameters are provided");let l="";Object.entries(r).length&&(l=(0,a.default)(i));return Object.keys(r).forEach((e=>{let t;t=_.has(e)?e:"".concat(l).concat(e),s.set(t,r[e])})),o.search=s.toString(),o};var a=(_=r("../get_portlet_namespace.es"))&&_.__esModule?_:{default:_};const e=/^[a-z][a-z0-9+.-]*:/i}}));
//# sourceMappingURL=create_portlet_url.es.js.map