Liferay.Loader.define("item-selector-taglib@5.2.9/item_selector_uploader/js/utils/getUploadErrorMessage",["module","exports","require","frontend-js-web"],(function(e,a,r){window;Object.defineProperty(a,"__esModule",{value:!0}),a.default=function(e,a){let r=Liferay.Language.get("an-unexpected-error-occurred-while-uploading-your-file");if(e&&e.errorType){switch(e.errorType){case i.STATUS_CODE.SC_FILE_ANTIVIRUS_EXCEPTION:e.message&&(r=e.message);break;case i.STATUS_CODE.SC_FILE_EXTENSION_EXCEPTION:r=e.message?(0,i.sub)(Liferay.Language.get("please-enter-a-file-with-a-valid-extension-x"),[e.message]):Liferay.Language.get("please-enter-a-file-with-a-valid-file-type");break;case i.STATUS_CODE.SC_FILE_NAME_EXCEPTION:r=Liferay.Language.get("please-enter-a-file-with-a-valid-file-name");break;case i.STATUS_CODE.SC_FILE_SIZE_EXCEPTION:case i.STATUS_CODE.SC_UPLOAD_REQUEST_CONTENT_LENGTH_EXCEPTION:r=(0,i.sub)(Liferay.Language.get("please-enter-a-file-with-a-valid-file-size-no-larger-than-x"),[Liferay.Util.formatStorage(a)]);break;case i.STATUS_CODE.SC_UPLOAD_REQUEST_SIZE_EXCEPTION:{const e=Liferay.PropsValues.UPLOAD_SERVLET_REQUEST_IMPL_MAX_SIZE;r=(0,i.sub)(Liferay.Language.get("request-is-larger-than-x-and-could-not-be-processed"),[Liferay.Util.formatStorage(e)]);break}default:r=Liferay.Language.get("an-unexpected-error-occurred-while-uploading-your-file")}}return r};var i=r("frontend-js-web")}));
//# sourceMappingURL=getUploadErrorMessage.js.map