jamespot-user-api 1.0.168 → 1.0.169
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/documentation/assets/search.js +1 -1
- package/documentation/classes/AdminLicenseApi.html +32 -12
- package/documentation/classes/AdminStoreApi.html +1 -1
- package/documentation/classes/AdminUtilsApi.html +2 -2
- package/documentation/classes/JApplicationApi.html +8 -8
- package/documentation/classes/JArticleApi.html +1 -1
- package/documentation/classes/JAssetReservation.html +1 -1
- package/documentation/classes/JAudienceApi.html +1 -1
- package/documentation/classes/JBaseApi.html +1 -1
- package/documentation/classes/JBbbApi.html +1 -1
- package/documentation/classes/JBookmarkApi.html +1 -1
- package/documentation/classes/JBusinessNetworkingApi.html +1 -1
- package/documentation/classes/JCommunityApi.html +1 -1
- package/documentation/classes/JDatasourceApi.html +1 -1
- package/documentation/classes/JDiapazoneApi.html +1 -1
- package/documentation/classes/JFaqApi.html +1 -1
- package/documentation/classes/JFileApi.html +5 -5
- package/documentation/classes/JFilebankApi.html +1 -1
- package/documentation/classes/JGlobalApi.html +1 -1
- package/documentation/classes/JGroupApi.html +12 -12
- package/documentation/classes/JIAApi.html +1 -1
- package/documentation/classes/JLandApi.html +1 -1
- package/documentation/classes/JMessengerApi.html +1 -1
- package/documentation/classes/JObjectApi.html +1 -1
- package/documentation/classes/JSearchApi.html +6 -6
- package/documentation/classes/JShareApi.html +1 -1
- package/documentation/classes/JSocialActionApi.html +1 -1
- package/documentation/classes/JTaxonomyApi.html +2 -2
- package/documentation/classes/JUserApi.html +7 -7
- package/documentation/classes/JWedocApi.html +1 -1
- package/documentation/classes/JWidgetApi.html +1 -1
- package/documentation/classes/JamespotUserApi.html +1 -1
- package/documentation/classes/Network.html +1 -1
- package/documentation/classes/TVDisplayApi.html +1 -1
- package/documentation/classes/WindowBrowser.html +1 -1
- package/documentation/enums/Format.html +1 -1
- package/documentation/enums/GroupModerateStatus.html +1 -1
- package/documentation/enums/StudioApplicationStatus.html +1 -1
- package/documentation/enums/WidgetsName.html +1 -1
- package/documentation/index.html +1 -1
- package/documentation/interfaces/AccessRightObject.html +1 -1
- package/documentation/interfaces/AdminLicenseUser.html +1 -1
- package/documentation/interfaces/ApiDefaultWrapper.html +1 -1
- package/documentation/interfaces/ApiWrapper.html +1 -1
- package/documentation/interfaces/BaseMessage.html +1 -1
- package/documentation/interfaces/Category.html +1 -1
- package/documentation/interfaces/FileBankProps.html +1 -1
- package/documentation/interfaces/FolderProps.html +1 -1
- package/documentation/interfaces/ListFilterSpec.html +1 -1
- package/documentation/interfaces/OF.html +1 -1
- package/documentation/interfaces/ObjectListProps.html +1 -1
- package/documentation/interfaces/PagingResults.html +1 -1
- package/documentation/interfaces/RootFolderProps.html +1 -1
- package/documentation/interfaces/SearchCategoryModel.html +1 -1
- package/documentation/interfaces/SearchCategoryValue.html +1 -1
- package/documentation/interfaces/SearchConfig.html +1 -1
- package/documentation/interfaces/SearchFacetModel.html +1 -1
- package/documentation/interfaces/SearchFacetValueModel.html +1 -1
- package/documentation/interfaces/SearchQuery.html +1 -1
- package/documentation/interfaces/SearchQueryFilterModel.html +1 -1
- package/documentation/interfaces/SearchQueryOption.html +1 -1
- package/documentation/interfaces/SearchQueryResult.html +1 -1
- package/documentation/interfaces/SearchQuerySortModel.html +1 -1
- package/documentation/interfaces/SearchResultCatProps.html +1 -1
- package/documentation/interfaces/SearchResultPropsApp.html +1 -1
- package/documentation/interfaces/SearchResultPropsObject.html +1 -1
- package/documentation/interfaces/SpotProps.html +1 -1
- package/documentation/interfaces/TaxonomyCreate.html +1 -1
- package/documentation/interfaces/WidgetType.html +1 -1
- package/documentation/interfaces/WindowInterface.html +1 -1
- package/documentation/modules.html +11 -11
- package/lib/jamespot-user-api.js +1 -1
- package/lib/jamespot-user-api.js.map +1 -1
- package/lib/src/apis/admin/license.d.ts +39 -4
- package/lib/src/apis/admin/licenses.mock.d.ts +6 -1
- package/lib/src/apis/admin/utils.d.ts +1 -1
- package/lib/src/apis/jamespotUserApi.d.ts +2 -0
- package/lib/src/apis/magicPad/magicPad.d.ts +6 -0
- package/lib/src/apis/magicPad/magicPad.mock.d.ts +3 -0
- package/lib/src/apis/magicPad/magicPad.test.d.ts +1 -0
- package/lib/src/types/adminLicence.d.ts +13 -3
- package/lib/src/types/adminUtils.d.ts +2 -0
- package/lib/src/types/hook.d.ts +91 -2
- package/lib/src/types/index.d.ts +1 -0
- package/lib/src/types/license.d.ts +223 -0
- package/lib/src/types/magicPad.d.ts +9 -0
- package/lib/src/types/search.d.ts +1 -3
- package/lib/src/types/utils.d.ts +11 -11
- package/lib/src/util/taxonomy.d.ts +2 -2
- package/package.json +1 -1
- package/phpunitMock/licenseManagerAssignLicenseKind-default.json +7 -0
- package/phpunitMock/licenseManagerGetUsers-default.json +205 -0
- package/phpunitMock/licenseManagerGetUsersWithLicense-default.json +24 -0
- package/phpunitMock/licenseManagerStatistics-default.json +10 -0
- package/phpunitMock/licenseManagerUnassignLicenseKind-default.json +7 -0
- package/phpunitMock/licenseManagerUnassignUnusedLicenses-default.json +7 -0
- package/phpunitMock/magicPadGetThumbnailUrl-success.json +9 -0
- /package/lib/src/apis/admin/{licences.test.d.ts → licenses.test.d.ts} +0 -0
package/lib/jamespot-user-api.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
(()=>{"use strict";var e,t={d:(e,i)=>{for(var n in i)t.o(i,n)&&!t.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:i[n]})},o:(e,t)=>Object.prototype.hasOwnProperty.call(e,t),r:e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})}},i={};t.r(i),t.d(i,{ACCESS_REQUEST_ACCEPT:()=>Xs,ACCESS_REQUEST_DENY:()=>ea,AdminLicenseApi:()=>r,AdminStoreApi:()=>s,AdminUtilsApi:()=>a,DateFormatSchema:()=>xr,Format:()=>Zn,GroupModerateStatus:()=>Xi,JApplicationApi:()=>o,JArticleApi:()=>Q,JAssetReservation:()=>X,JAudienceApi:()=>ee,JBaseApi:()=>n,JBbbApi:()=>te,JBookmarkApi:()=>ie,JBusinessNetworkingApi:()=>ne,JCommunityApi:()=>re,JDatasourceApi:()=>se,JDiapazoneApi:()=>ae,JFaqApi:()=>le,JFileApi:()=>ce,JFilebankApi:()=>de,JGlobalApi:()=>ue,JGroupApi:()=>he,JIAApi:()=>kn,JLandApi:()=>on,JMessengerApi:()=>cn,JObjectApi:()=>vn,JSearchApi:()=>ln,JShareApi:()=>fn,JSocialActionApi:()=>_n,JTaxonomyApi:()=>un,JUserApi:()=>pn,JWedocApi:()=>mn,JWidgetApi:()=>xn,JamespotUserApi:()=>jn,JamespotUserApiInstance:()=>ia,Network:()=>D,NumberFormatSchema:()=>jr,StudioApplicationStatus:()=>e,TVDisplayApi:()=>hn,UserLevel:()=>Ci,WidgetDatasourceTableContentSchema:()=>Cr,WidgetDatasourceTableTypeSchema:()=>Fr,WidgetTableColumnDataSchema:()=>Sr,WidgetTableColumnSchema:()=>Or,WidgetTableColumnTypesSchema:()=>kr,WidgetTableColumnWidgetDateSchema:()=>wr,WidgetTableColumnWidgetSelectOptionSchema:()=>br,WidgetTableColumnWidgetSelectSchema:()=>vr,WidgetTableColumnWidgetTextSchema:()=>yr,WidgetTableColumnWidgetsSchema:()=>_r,WidgetTableColumnsData:()=>Ar,WidgetTableContentSchema:()=>Tr,WidgetsName:()=>sr,WindowBrowser:()=>Sn,addCommentParamsSchema:()=>Ls,api:()=>ra,articleCreationSchema:()=>Fs,articleDisplayModeSchema:()=>mr,articleGetConfigSchema:()=>Cs,articleListConfigSchema:()=>Ts,audienceAutocompleteSchema:()=>Qn,audienceSchema:()=>Tn,baseArticleSchema:()=>Rs,baseAutocompleteSchema:()=>Jn,businessContactSchema:()=>qi,combineFormat:()=>B,combinedWidgetContentSchema:()=>Jr,combinedWidgetTypeSchema:()=>or,cssBackgroundPositionSchema:()=>Xn,cssBackgroundSizeSchema:()=>er,cssTextAlignTypeSchema:()=>Yn,deepEqual:()=>$,default:()=>na,ensureWidgetApiType:()=>Yr,ensureWidgetArticleAttachmentType:()=>ds,ensureWidgetArticleButtonType:()=>es,ensureWidgetArticleGalleryType:()=>is,ensureWidgetArticleImageType:()=>cs,ensureWidgetArticleSliderType:()=>ps,ensureWidgetArticleTextType:()=>as,ensureWidgetArticleTitleType:()=>rs,ensureWidgetCheckListType:()=>hs,ensureWidgetDatasourceTableType:()=>Rr,extensions:()=>x,extractTaxonomiesFromObject:()=>V,extractTaxonomiesFromObjectAndMapProperty:()=>J,extractTaxonomiesFromObjectAndMapUri:()=>G,fileCropConfigSchema:()=>Wn,filterSchema:()=>Ln,filterValueSchema:()=>Fn,filtersSchema:()=>Pn,formatExtensionSchema:()=>Dn,formatImgUrl:()=>_,formatListSchema:()=>In,getArgs:()=>y,getCommentsParamsSchema:()=>Es,getExtensionFromName:()=>O,getFileExtensionFromMimetype:()=>A,getFileFamily:()=>L,getFileFamilyFromName:()=>R,getFormat:()=>v,getFrom:()=>f,getMimetypeFromExtension:()=>S,getMimetypeFromName:()=>T,getSize:()=>b,getTimestamp:()=>g,getUri:()=>h,getUrl:()=>w,groupLittleSchema:()=>tn,imageSizeSchema:()=>Un,inferJInternalDraftView:()=>Os,inferWidgetWrapperPropsSchema:()=>ur,jArticleExtendViewSchema:()=>As,jArticleListSchema:()=>js,jArticleLittleSchema:()=>xs,jArticleViewSchema:()=>Ss,jArticleWidgetLittle:()=>hr,jArticleWidgetViewSchema:()=>ks,jEnsure:()=>d,jFileLittleCropSchema:()=>Bn,jFileLittleSchema:()=>$n,jFileRenditionSchema:()=>zn,jHrefSchema:()=>An,jObjectAutocompleteSchema:()=>Gn,jObjectBaseSchema:()=>Gi,jObjectListSchema:()=>Qi,jObjectLittleSchema:()=>Ki,jSpotAutocompleteSchema:()=>Hn,jUserAutocompleteSchema:()=>Kn,jUserListSchema:()=>Ri,jUserLittleSchema:()=>Fi,jUserValuesSchema:()=>Di,jUserViewSchema:()=>Li,legacyAngularJSTypeSchema:()=>pr,mediaLibraryFilesStatsSchema:()=>Hs,mediaLibraryFolderStatsSchema:()=>Qs,mediaLibraryStatsSchema:()=>Ys,mimetypeToExt:()=>j,mimetypes:()=>k,network:()=>ta,objectTimestamp:()=>C,openingTypeAnchorSchema:()=>Dr,openingTypeLinkSchema:()=>Ir,openingTypePopupSchema:()=>Mr,openingTypeSchema:()=>nr,orderSchema:()=>On,ordersSchema:()=>Cn,padStartTwoDigits:()=>m,prepareGroupForUpdate:()=>K,publicWebinarData:()=>Ms,publicWebinarFullnameRequestSchema:()=>Ns,publicWebinarGetDateRequestSchema:()=>Ds,publicWebinarUrlSchema:()=>Is,removeIfStartsWith:()=>p,replacePropertiesWithTypes:()=>q,resolveFileFamily:()=>N,resolveFileMimetype:()=>Z,resolveFilePath:()=>F,resolveFileUrl:()=>P,rightsSchema:()=>Vi,suffixIfDoesNotExist:()=>u,updateCommentParamsSchema:()=>Ps,uploadConfigSchema:()=>Mn,userDefaultFieldsTypeSchema:()=>Ii,userDirectoryConfigurationSchema:()=>Bi,userDownloadSchema:()=>Vn,userFieldSchema:()=>Ui,userFieldsConfigurationTypeSchema:()=>Mi,userFieldsSchema:()=>Wi,userMapModelSchema:()=>Zi,userReadSchema:()=>Zs,userValuesSchema:()=>$i,userlevelSpotShema:()=>en,validateIsFormatFileLittle:()=>qn,validateIsFormatHookListType:()=>Ks,validateIsFormatObjectList:()=>Yi,validateIsFormatObjectLittle:()=>Hi,validateIsFormatRights:()=>Ji,validateIsFormatUserDirectoryConfiguration:()=>zi,validateIsFormatUserLevelSpot:()=>nn,validateIsFormatUserList:()=>Ei,validateIsFormatUserMapModel:()=>Ni,validateIsFormatUserView:()=>Pi,variantSizeTypeSchema:()=>tr,variantTypeSchema:()=>ir,widgetActiveValueSchema:()=>Si,widgetApiContentSchema:()=>Zr,widgetApiTypeSchema:()=>Qr,widgetArticleAttachmentContentSchema:()=>$r,widgetArticleAttachmentTypeSchema:()=>ls,widgetArticleButtonContentSchema:()=>Ur,widgetArticleButtonTypeSchema:()=>Xr,widgetArticleCheckListTypeForFrontSchema:()=>ys,widgetArticleGalleryContentSchema:()=>Er,widgetArticleGalleryTypeSchema:()=>ts,widgetArticleImageContentSchema:()=>Wr,widgetArticleImageTypeSchema:()=>os,widgetArticleSliderContentSchema:()=>Br,widgetArticleSliderTypeSchema:()=>us,widgetArticleTextContentSchema:()=>Pr,widgetArticleTextTypeSchema:()=>ss,widgetArticleTitleContentSchema:()=>Lr,widgetArticleTitleTypeSchema:()=>ns,widgetButtonPropsSchema:()=>Nr,widgetCheckListContentArrForFrontSchema:()=>fs,widgetCheckListContentArrSchema:()=>zr,widgetCheckListContentForFrontSchema:()=>gs,widgetCheckListContentSchema:()=>Vr,widgetCheckListTypeSchema:()=>ms,widgetContentKeysSchema:()=>lr,widgetDatePickerValueSchema:()=>ji,widgetDateValueSchema:()=>ki,widgetDatetimeValueSchema:()=>xi,widgetDefaultProps:()=>Kr,widgetDefinitionPropsSchema:()=>bs,widgetDisplayModeSchema:()=>gr,widgetEmailValueSchema:()=>Ai,widgetExtendedTypeSchema:()=>dr,widgetKeysSchema:()=>ar,widgetLayerSchema:()=>fr,widgetModalPropsSchema:()=>vs,widgetNumberValueSchema:()=>_i,widgetSlideSchema:()=>qr,widgetStatePropsSchema:()=>Gr,widgetTextValueSchema:()=>vi,widgetTextareaValueSchema:()=>wi,widgetTypeKeysSchema:()=>cr,widgetUrlValueSchema:()=>Oi,widgetVectorSchema:()=>rr,widgetsRootStateSchema:()=>_s,widgetsStateSchema:()=>ws,widgetsValueSchema:()=>Ti});class n{constructor(e){this.jApi=e,this.network=e.network}}class r extends n{getLicenseUserStatistics(){return this.network.post({o:"licenseManager",f:"userStatistics"})}assignLicense(e){return this.network.postCSRF({o:"licenseManager",f:"assignLicense",uri:e})}unAssignLicense(e){return this.network.postCSRF({o:"licenseManager",f:"unassignLicense",uri:e})}getAssignmentMode(e){return this.network.post({o:"licenseManager",f:"getAssignmentMode",type:e})}setAssignmentMode(e,t){return this.network.postCSRF({o:"licenseManager",f:"setAssignmentMode",value:t,type:e})}assignPossiblesLicenses(e){return this.network.postCSRF({o:"licenseManager",f:"assignPossiblesLicenses",type:e})}unAssignUnusedLicenses(e){return this.network.postCSRF({o:"licenseManager",f:"unassignUnusedLicenses",type:e})}optimizeLicenses(e){return this.network.postCSRF({o:"licenseManager",f:"optimizeLicenses",type:e})}getObjectsWithoutLicense(e,t){return this.network.post({o:"licenseManager",f:"countObjectsWithoutLicense",type:e,filter:t})}getLicensesNotAssigned(e){return this.network.post({o:"licenseManager",f:"countLicensesNotAssigned",type:e})}getLicensesAssigned(e){return this.network.post({o:"licenseManager",f:"getLicensesAssigned",type:e})}}class s extends n{getItem(e){return this.network.post({o:"adminStore",f:"getItem",uri:e})}checkoutBilling(e){return this.network.postCSRF({o:"adminStore",f:"checkoutBilling",uri:e})}checkoutFinalize(e){return this.network.postCSRF({o:"adminStore",f:"checkoutFinalize",uri:e})}}class a extends n{getApps(){return this.network.post({o:"admin",f:"apps"})}}!function(e){e.local="local",e.installed="installed",e.autosaved="autosaved",e.saved="saved"}(e||(e={}));class o extends n{list(){return this.network.post({o:"studio",f:"list"})}get(e,t){return this.network.post({o:"studio",f:"get",idApp:e,status:t})}install(e){return this.network.postCSRF({o:"studio",f:"install",value:e})}suspend(e){return this.network.postCSRF({o:"studio",f:"suspend",idApp:e})}restart(e){return this.network.postCSRF({o:"studio",f:"restart",idApp:e})}save(t,i,n){if(n===e.saved||n===e.autosaved)return this.network.postCSRF({o:"studio",f:"save",idApp:t,value:i,status:n});throw"Invalid status value"}delete(e,t){return i=this,n=void 0,s=function*(){return this.network.postCSRF({o:"studio",f:"delete",idApp:e,status:t}).then((e=>{if(0===e.error)return e.messages;throw e.messages}))},new((r=void 0)||(r=Promise))((function(e,t){function a(e){try{c(s.next(e))}catch(e){t(e)}}function o(e){try{c(s.throw(e))}catch(e){t(e)}}function c(t){var i;t.done?e(t.value):(i=t.value,i instanceof r?i:new r((function(e){e(i)}))).then(a,o)}c((s=s.apply(i,n||[])).next())}));var i,n,r,s}cssClassList(){return this.network.post({o:"studio",f:"icons"})}}function c(e){const t=e;return t&&"number"==typeof t.id&&"number"==typeof t.targetId}const l={bookmarkLink:c},d={isBookmarkLink:function(e){return"targetId"in e&&!!e.targetId},isBookmarkCustom:function(e){const t=e;return void 0!==t.bookmarkLabel||void 0!==t.bookmarkMeta||void 0!==t.bookmarkUrl},isBookmarkRawList:c,isTVChannelType:function(e,t){return"tvChannelType"in e&&e.tvChannelType===t},objectIsType:function(e,t){return null!=t&&l[e](t)},isStandardApiError:e=>"object"==typeof e&&null!==e&&"error"in e&&"errorMsg"in e&&"messages"in e&&"number"==typeof e.error&&"string"==typeof e.errorMsg&&Array.isArray(e.messages),isAbortApiError:e=>null!==e&&"object"==typeof e&&"error"in e&&"aborted"in e&&-1===e.error&&!0===e.aborted};function u(e,t){return e&&!e.endsWith(t)?`${e}${t}`:e}function p(e,t){return e&&e.startsWith(t)?e.split("").slice(t.length).join(""):e}function m(e){return e.toString().padStart(2,"0")}function h(e){return"uri"in e&&e.uri?e.uri:`${e.type}/${e.recordId}`}function f(e){return p(u(e.from,"/"),"/")||""}function g(e){return e.timestamp?`?_=${e.timestamp}`:""}function y(e){const t=[];return"timestamp"in e&&e.timestamp&&t.push(`_=${e.timestamp}`),"iconColor"in e&&e.iconColor&&t.push(`color=${e.iconColor}`),t.length?"?"+t.join("&"):""}function b(e,t=2){return"size"in e&&e.size?e.size:"width"in e&&e.width&&"height"in e&&e.height?`${e.width*t}x${e.height*t}`:""}function v(e){return e.format||"png"}function w(e){try{return new URL(e)}catch(e){}try{return new URL(window.location.origin+"/"+p(e,"/"))}catch(e){}}function _(e,t=2){if("url"in e&&e.url){const t=w(e.url);if(t)return"timestamp"in e&&e.timestamp&&!t.searchParams.has("_")&&t.searchParams.append("_",e.timestamp.toString()),t.toString()}return`/${f(e)}${b(e,t)}/${h(e)}.${v(e)}${y(e)}`}const k=["application/vnd.openxmlformats-officedocument.wordprocessingml.document","application/vnd.openxmlformats-officedocument.spreadsheetml.sheet","application/vnd.openxmlformats-officedocument.presentationml.presentation","application/pdf","application/zip","application/illustrator","application/postscript","application/vnd.ms-opentype","application/x-font-ttf","application/octet-stream","audio/mp3","audio/mpeg","font/ttf","font/otf","image/jpeg","image/jpg","image/png","image/gif","image/vnd.adobe.photoshop","image/svg+xml","text/plain","text/csv","video/mp4","video/webm"],x=["docx","xlsx","csv","pptx","pdf","zip","ai","mp3","mpeg","ttf","otf","jpg","jpeg","png","gif","psd","svg","txt","mp4","odt","webm"],j={"application/vnd.openxmlformats-officedocument.wordprocessingml.document":"docx","application/vnd.openxmlformats-officedocument.spreadsheetml.sheet":"xlsx","application/vnd.openxmlformats-officedocument.presentationml.presentation":"pptx","application/vnd.oasis.opendocument.text":"odt","application/pdf":"pdf","application/zip":"zip","application/x-zip-compressed":"zip","application/illustrator":"ai","application/postscript":"ai","audio/mp3":"mp3","audio/mpeg":"mpeg","font/ttf":"ttf","font/otf":"otf","image/jpeg":"jpeg","image/jpg":"jpg","image/png":"png","image/gif":"gif","application/x-font-ttf":"ttf","application/vnd.ms-opentype":"otf","image/vnd.adobe.photoshop":"psd","image/svg+xml":"svg","text/plain":"txt","text/csv":"xlsx","video/mp4":"mp4","video/webm":"mp4"},S=e=>Object.keys(j).find((t=>j[t]===e)),A=e=>{var t;return null!==(t=j[e])&&void 0!==t?t:void 0};function O(e){const t=String(e).split(".").pop();return x.find((e=>e===t))}const T=e=>{var t;const i=O(e);return null!==(t=S(i))&&void 0!==t?t:"application/octet-stream"},C=e=>e?(new Date(e).getTime()/1e3).toFixed(0):void 0,F=(e,t="fitx80")=>{const i=N(e),n=C(e.dateModified);switch(i){default:return;case"video":return`/media/${e.id}.mp4?stream=true`+(n?`&_=${n}`:"");case"audio":return`/media/${e.id}.mp3`+(n?`?_=${n}`:"");case"gif":return _({timestamp:n,size:t,from:"imagecache",uri:e.uri,format:"gif"});case"image":return _({timestamp:n,size:t,from:"imagecache",uri:e.uri})}},R=e=>{const t=O(e);return void 0!==t?L(S(t)):"application"},E=e=>-1!==["image/vnd","image/svg","image/heic"].findIndex((t=>e.startsWith(t)));function L(e){return e&&e.startsWith("folder/")?"folder":null==e||E(e)?"application":e.startsWith("image/gif")?"gif":e.startsWith("image/")?"image":e.startsWith("video/")?"video":e.startsWith("audio/")?"audio":e.startsWith("font/")||e.startsWith("application/x-font-ttf")||e.startsWith("application/vnd.ms-opentype")?"font":e.startsWith("text/")?"text":"application"}const P=(e,t,i="rr")=>"ng"===i?`/ng/file/${e}/${t}`:`/ng/rr/file/${e}/${t}`,Z=e=>void 0===e.mimetype||"application/octet-stream"===e.mimetype?T(e.title):e.mimetype,N=e=>void 0===e.mimetype||"application/octet-stream"===e.mimetype?R(e.title):L(e.mimetype);var I=function(e,t,i,n){return new(i||(i=Promise))((function(r,s){function a(e){try{c(n.next(e))}catch(e){s(e)}}function o(e){try{c(n.throw(e))}catch(e){s(e)}}function c(e){var t;e.done?r(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(a,o)}c((n=n.apply(e,t||[])).next())}))};class D{constructor(e,t="api-front"){this.window=e,this.action=t}static _formatPostOptions(e){const t=e?{body:JSON.stringify(e)}:void 0;return Object.assign({method:"POST",credentials:"same-origin"},t)}getUrl(e,t){return I(this,void 0,void 0,(function*(){const i=yield this.window.getBackendUrl();let n;try{n=new URL(`/${this.action}/${e}/${t}`,i).href}catch(r){n=`${i}/${this.action}/${e}/${t}`}return n}))}getHostname(){return I(this,void 0,void 0,(function*(){const e=(yield this.window.getBackendUrl()).split("//");return e.length>1?e[1]:e[0]}))}fetch(e,t){var{o:i,f:n}=e,r=function(e,t){var i={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(i[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var r=0;for(n=Object.getOwnPropertySymbols(e);r<n.length;r++)t.indexOf(n[r])<0&&Object.prototype.propertyIsEnumerable.call(e,n[r])&&(i[n[r]]=e[n[r]])}return i}(e,["o","f"]);return I(this,void 0,void 0,(function*(){void 0===t&&(t=null);const e=yield this.getUrl(i,n);return this.window.fetch(e,Object.assign(Object.assign({},D._formatPostOptions(r)),{signal:t}))}))}post(e,t){return this.fetch(e,t).then((e=>e.json())).then((e=>{if(0===e.error)return e;throw{error:e.error,errorMsg:e.errorMsg,messages:e.messages}})).catch((e=>{if(t&&t.aborted)throw{error:-1,aborted:!0};throw e}))}postFile(e){return I(this,void 0,void 0,(function*(){const t=yield this.getUrl("file","create");if(e.append("format","raw-little"),!e.has("token")){const{result:t}=yield this.token();e.append("token",t)}const i=e.get("token");return i&&"string"==typeof i?this.window.fetch(t,{method:"POST",credentials:"same-origin",body:e}).then((e=>e.json())).then((e=>({response:e,token:i}))):Promise.reject("Missing token")}))}postCSRF(e){return this.tokenCSRF().then((t=>this.post(Object.assign(e,{tokenCSRF:t.result}))))}postToken(e){return this.token().then((t=>this.post(Object.assign(e,{token:t.result}))))}maybePostToken(e){return"token"in e&&e.token?this.post(e):this.postToken(e)}token(){return this.post({o:"misc",f:"token"})}tokenCSRF(){return this.post({o:"misc",f:"tokenCSRF"})}}const M=Array.isArray,U=Object.keys,W=Object.prototype.hasOwnProperty;function $(e,t,i){const n=null==i?void 0:i.map((e=>e.split(".")));if(e===t)return!0;if(e&&t&&"object"==typeof e&&"object"==typeof t){const r=M(e),s=M(t);let a,o,c;if(r&&s){if(o=e.length,o!==t.length)return!1;for(a=o;0!=a--;)if(!$(e[a],t[a],i))return!1;return!0}if(r!==s)return!1;const l=e instanceof Date,d=t instanceof Date;if(l!==d)return!1;if(l&&d)return e.getTime()===t.getTime();const u=e instanceof RegExp,p=t instanceof RegExp;if(u!==p)return!1;if(u&&p)return e.toString()===t.toString();const m=U(e).filter((e=>!(null==n?void 0:n.some((t=>1===t.length&&t[0]===e)))));if(o=m.length,o!==U(t).filter((e=>!(null==n?void 0:n.some((t=>1===t.length&&t[0]===e))))).length)return!1;for(a=o;0!=a--;)if(!W.call(t,m[a]))return!1;for(a=o;0!=a--;)if(c=m[a],!("_owner"===c&&e.$$typeof||$(e[c],t[c],null==n?void 0:n.filter((e=>e.length>1&&e[0]===c)).map((e=>e.splice(1).join("."))))))return!1;return!0}return e!=e&&t!=t}function q(e,t){if(Array.isArray(e))return e.map((e=>q(e,t)));if("object"==typeof e&&null!==e){let i={};return Object.keys(e).forEach((n=>{i=Object.assign(Object.assign({},i),{[n]:n&&t.includes(n)?typeof e[n]:q(e[n],t)})})),i}return e}const B=(e,t)=>Array.isArray(t)&&t.length?[e,...t].join(","):e;function z(e){return e.startsWith("tag_")||"tags"===e}function V(e){return Object.fromEntries(Object.entries(e).filter((([e])=>z(e))))}function J(e,t,i){return Object.fromEntries(Object.entries(e).filter((([e])=>z(e))).map((([e,n])=>{const r=Array.isArray(n)?n.map((e=>"object"==typeof e&&e&&t in e?e[t]:e)):n;return[e,i?i(r):r]})))}function G(e){return J(e,"uri")}const K=e=>{var t;let i={};"_errors"in e&&(i._errors=e._errors),"_options"in e&&(i._options=e._options),"title"in e&&(i.title=e.title),"description"in e&&(i.description=e.description),"activity"in e&&(i.activity=e.activity),"image"in e&&(i.image=e.image),"uri"in e&&(i.uri=e.uri),"type"in e&&(i.type=e.type),"edito"in e&&(i.edito=e.edito),"category"in e&&(i.category=e.category.toString()),"commentLevel"in e&&(i.commentLevel=e.commentLevel),"_options"in e&&(null===(t=e._options)||void 0===t?void 0:t.custom_widgets)&&(i.custom_widgets=Array.isArray(e._options.custom_widgets)?{}:e._options.custom_widgets),"displayType"in e&&(i.displayType=e.displayType),"language"in e&&(i.language=e.language),"edit_access"in e&&(i.edit_access=e.edit_access),"lock_mail"in e&&(i.lock_mail=e.lock_mail),"fileSyncEnabled"in e&&(i.fileSyncEnabled=e.fileSyncEnabled),"fileSyncVersioningType"in e&&(i.fileSyncVersioningType=e.fileSyncVersioningType),"fileBankQuota"in e&&(i.fileBankQuota=e.fileBankQuota),"idCommunity"in e&&(i.idCommunity=e.idCommunity),"lastRssExecution"in e&&(i.lastRssExecution=e.lastRssExecution),"mail_comment"in e&&(i.mail_comment=e.mail_comment),"mail_frequency"in e&&(i.mail_frequency=e.mail_frequency),"mail_spotit"in e&&(i.mail_spotit=e.mail_spotit),"mail_subscriber"in e&&(i.mail_subscriber=e.mail_subscriber),"notifyFolder"in e&&(i.notifyFolder=e.notifyFolder),"nounsubscribe"in e&&(i.nounsubscribe=e.nounsubscribe),"privacy"in e&&(i.privacy=e.privacy),"publishFolder"in e&&(i.publishFolder=e.publishFolder),"rss_access"in e&&(i.rss_access=e.rss_access),"rss_feed"in e&&(i.rss_feed=e.rss_feed&&Array.isArray(e.rss_feed)?JSON.stringify(e.rss_feed.map((e=>{var{_user:t}=e,i=function(e,t){var i={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(i[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var r=0;for(n=Object.getOwnPropertySymbols(e);r<n.length;r++)t.indexOf(n[r])<0&&Object.prototype.propertyIsEnumerable.call(e,n[r])&&(i[n[r]]=e[n[r]])}return i}(e,["_user"]);return Object.assign(Object.assign({},i),{idUser:null==t?void 0:t.id})}))):"[]"),"rss_key"in e&&(i.rss_key=e.rss_key),"spot_right_user"in e&&(i.spot_right_user=e.spot_right_user),"spotBanner"in e&&(i.spotBanner=e.spotBanner),"spotDefaultPublishType"in e&&(i.spotDefaultPublishType=e.spotDefaultPublishType),"user_level_signup"in e&&(i.user_level_signup=e.user_level_signup),"useTeaser"in e&&(i.useTeaser=e.useTeaser),"widgets"in e&&(i.widgets=e.widgets);const n=V(e);if(i=Object.assign(Object.assign({},i),n),H(e,i))return i;throw new Error},H=(e,t)=>{const i=["id","mainType","dateCreation","dateModified","_url","o2apLinksSources"],n=["custom_widgets"],r=Object.keys(e),s=Object.keys(t),a=r.filter((e=>!s.includes(e)&&!i.includes(e))),o=s.filter((e=>!r.includes(e)&&!n.includes(e))),c=[...a.map((e=>"- "+e)),...o.map((e=>"+ "+e))];if(a.length>0||o.length>0)throw new Error(`prepareGroupForUpdate :: Wrong group mapping | Diff : ${JSON.stringify(c)}`);return!0};class Q extends n{list(e){var t,i;return this.network.post(Object.assign(Object.assign({o:"objectList",f:"jamespotArticleQueryList"},e),{format:B(null!==(t=e.format)&&void 0!==t?t:"raw-list",null!==(i=e.formatExtend)&&void 0!==i?i:[])}))}get(e,t){var i;return this.network.post(Object.assign(Object.assign({o:"article",f:"get"},e),{format:B(null!==(i=e.format)&&void 0!==i?i:"raw-view",null==t?void 0:t.formatExtension)}),null==t?void 0:t.signal)}create(e,t){return this.network.maybePostToken(Object.assign({o:"article",f:"create",format:null!=t?t:"raw-list"},e))}update(e){return this.network.post(Object.assign(Object.assign({format:"raw-list"},e),{o:"article",f:"update"}))}delete(e){return this.network.postCSRF({o:"article",f:"delete",idArticle:e})}count(e){return this.network.post({o:"article",f:"count",type:e})}getAttachments(e,t,i){return this.network.post({o:"article",f:"getAttachment",idArticle:e,type:t,format:i})}permalink(e){return this.network.post({o:"article",f:"permalink",permalinkId:e})}saveAsDraft(e,t,i){return this.network.post({o:"article",f:"saveAsDraft",form:e,contentType:t,idDraft:i})}getComments(e,t){var i,n;return this.network.post(Object.assign(Object.assign({o:"article",f:"getComments"},e),{attachments:null!==(i=e.attachment)&&void 0!==i&&i,limits:null!==(n=e.limits)&&void 0!==n?n:{start:0,max:1e4},format:null!=t?t:"raw-little"}))}addComment(e,t){return this.network.post(Object.assign(Object.assign({o:"article",f:"addComment"},e),{alertAuthor:Number(e.alertAuthor),sendAlert:Number(e.sendAlert),type:"comment",format:null!=t?t:"raw-little"}))}updateComment(e,t){return this.network.post(Object.assign(Object.assign({o:"article",f:"updateComment"},e),{format:null!=t?t:"raw-little"}))}deleteComment(e){return this.network.postCSRF({o:"comment",f:"delete",idComment:e})}getRead(e){return this.network.post({o:"article",f:"getRead",uri:e})}}var Y=function(e,t){var i={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(i[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var r=0;for(n=Object.getOwnPropertySymbols(e);r<n.length;r++)t.indexOf(n[r])<0&&Object.prototype.propertyIsEnumerable.call(e,n[r])&&(i[n[r]]=e[n[r]])}return i};class X extends n{configuration(){return this.network.post({o:"assetReservation",f:"configuration"})}createReservation(e){return this.network.postCSRF(Object.assign({o:"assetReservation",f:"createReservation",format:"raw-list"},e))}getReservations(e){var{format:t="raw-list"}=e,i=Y(e,["format"]);return this.network.post(Object.assign({o:"assetReservation",f:"getReservations",format:t},i))}cancelReservation(e){return this.network.post({o:"assetReservation",f:"cancelReservation",format:"raw-list",idArticle:e})}bookByDate(e){var{format:t="raw-list"}=e,i=Y(e,["format"]);return this.network.post(Object.assign({o:"assetReservation",f:"BookByDate",format:t},i))}getList(e){var{format:t="raw-list"}=e,i=Y(e,["format"]);return this.network.post(Object.assign({o:"objectList",f:"assetReservationList",format:t},i))}}class ee extends n{autocomplete(e){return this.network.post({o:"autocomplete",f:"audience",q:e}).then((e=>{if(Array.isArray(e.result))return e.result;throw"Bad response from backend"}))}}class te extends n{publicWebinarFullname(e){return this.network.post(Object.assign({o:"bigBlueButton",f:"publicWebinarFullname"},e))}getPublicWebinarData(e){return this.network.post(Object.assign({o:"bigBlueButton",f:"getPublicWebinarData"},e))}}class ie extends n{getFormattedList(e,t){return this.network.post(Object.assign({o:"objectList",f:"bookmarksList",format:t},e))}addFormattedLink(e,t,i){const n=null!=i?i:"list";return this.network.post({o:"custom",f:"actionAdd",type:"bookmarkLink",targetId:e,targetType:t,format:n})}addBookmark(e,t){return this.network.postCSRF(Object.assign({o:"bookmarks",f:"add"},e))}delete(e){return this.network.postCSRF({o:"bookmarks",f:"delete",bookmarkID:e})}rename(e,t,i){return this.network.postCSRF({o:"bookmarks",f:"rename",bookmarkID:e,bookmarkLabel:t,bookmarkUrl:i})}move(e,t,i){return this.network.postCSRF({o:"bookmarks",f:"move",bookmarkID:e,bookmarkReference:t,bookmarkPosition:i})}}class ne extends n{getInfos(e,t){return this.network.post({o:"BusinessNetworking",f:"MarkerInfo",id:e,format:null!=t?t:"raw-little"})}}class re extends n{get(e,t){return this.network.post({o:"community",f:"getCommunity",idCommunity:e,format:t||"raw-little"})}sendRequest(e,t){return this.network.post({o:"community",f:"sendRequest",message:e,idUserTo:t})}autocomplete(e){return this.network.post({o:"autocomplete",f:"community",q:e}).then((e=>e.result))}}class se extends n{get(e,t){return this.network.post({o:"widget",f:"datasourceGet",uri:e,format:t})}getModel(e){return this.network.post({o:"widget",f:"datasourceGetModel",uri:e})}getObject(e){return this.network.post({o:"widget",f:"datasourceGetObject",uri:e})}create({title:e,datasourceType:t,datasourceIdentifier:i}){return this.network.postCSRF({o:"widget",f:"datasourceCreate",title:e,datasourceType:t,datasourceIdentifier:i})}}class ae extends n{create(e,t,i,n,r){return this.network.post({o:"article",f:"create",type:e,token:t,title:i,dateStart:n,publishTo:r})}getList(e="",t=[],i=[],n=1,r="raw-list"){return this.network.post({o:"objectList",f:"diapazoneQueryList",query:e,filters:t,orders:i,page:n,format:r})}}var oe=function(e,t,i,n){return new(i||(i=Promise))((function(r,s){function a(e){try{c(n.next(e))}catch(e){s(e)}}function o(e){try{c(n.throw(e))}catch(e){s(e)}}function c(e){var t;e.done?r(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(a,o)}c((n=n.apply(e,t||[])).next())}))};class ce extends n{upload(e){const t=new FormData;return t.append("attrName",e.attrName),e.file?t.append(e.attrName,e.file):e.url&&t.append("url",e.url),t.append("token",e.token),this.network.postFile(t)}uploadMany(e){return oe(this,void 0,void 0,(function*(){return Promise.all(e.map((e=>this.upload(e))))}))}get(e,t){return oe(this,void 0,void 0,(function*(){return this.network.post({o:"file",f:"get",idFile:e,format:t})}))}getParent(e,t){return oe(this,void 0,void 0,(function*(){return this.network.post({o:"file",f:"getParent",idFile:e,format:t})}))}getWithHash(e,t,i){return oe(this,void 0,void 0,(function*(){return this.network.post({o:"file",f:"getWithHash",idFile:e,hash:t,format:i})}))}duplicate(e,t,i){return oe(this,void 0,void 0,(function*(){return this.network.postCSRF({o:"file",f:"duplicateFile",idFile:e,title:t,publishTo:i})}))}updateFile(e,t){return oe(this,void 0,void 0,(function*(){return this.network.postCSRF({o:"file",f:"updateFile",idFile:e,title:t})}))}update(e,t,i){return oe(this,void 0,void 0,(function*(){return this.network.post({o:"file",f:"update",idFile:e,type:t,cropDatas:Object.assign(Object.assign({},i),{rotateBeforeCrop:!0}),killSize:i.killSize,format:"raw-little"})}))}deleteFile(e,t,i,n){return oe(this,void 0,void 0,(function*(){return this.network.post({o:"file",f:"delete",idFile:e,attrName:t,token:i},n)}))}deleteImage(e,t){return oe(this,void 0,void 0,(function*(){return this.network.post({o:"file",f:"deleteImage",id:e,type:t})}))}getDownload(e){return this.network.post({o:"file",f:"getDownload",id:e})}generatePreview(e){return this.network.post({o:"file",f:"generatePreview",id:e})}}class le extends n{getCategoriesList(e,t){return this.network.post({o:"objectList",f:"faqQueryList",format:null!=e?e:"raw-list",orders:null!=t?t:[{name:"dateCreation",sort:"ASC"}]})}createCategory(e,t){return this.jApi.article.create(Object.assign(Object.assign({},e),{type:"faq"}),null!=t?t:"raw-view")}updateCategory(e,t){return this.jApi.article.update(Object.assign(Object.assign({},e),{type:"faq",format:null!=t?t:"raw-view"}))}getCategory(e,t){return this.jApi.article.get({idArticle:e,format:null!=t?t:"raw-view"})}deleteCategory(e){return this.jApi.article.delete(e)}checkItem(e,t,i){return this.network.post({o:"faq",f:"checkItem",query:e,page:null!=t?t:1,format:null!=i?i:"raw-list"})}getTaxonomy(){return this.network.post({o:"faq",f:"getFaqTaxonomy"})}getHookProperties(e){return this.network.post({o:"faq",f:"getHookProperties",properties:null!=e?e:["_web"]})}getAccess(){return this.network.post({o:"faq",f:"access"})}createTheme(e,t){return this.network.postCSRF(Object.assign(Object.assign({o:"faq",f:"add-theme"},e),{format:null!=t?t:"raw-view"}))}deleteTheme(e,t){return this.network.postCSRF(Object.assign(Object.assign({o:"faq",f:"delete-theme"},e),{format:null!=t?t:"raw-view"}))}updateTheme(e,t){return this.network.postCSRF(Object.assign(Object.assign({o:"faq",f:"set-theme"},e),{format:null!=t?t:"raw-view"}))}getEntry(e,t){return this.network.post({o:"faq",f:"get-entry",uri:e,format:null!=t?t:"raw-view"})}deleteEntry(e){return this.jApi.article.delete(e)}createEntry(e,t){return this.jApi.article.create(Object.assign(Object.assign({},e),{idSpot:["content"],type:"faqItem"}),null!=t?t:"raw-view")}addEntry(e,t){return this.network.postCSRF(Object.assign(Object.assign({o:"faq",f:"add-entry"},e),{format:null!=t?t:"raw-view"}))}updateEntry(e,t){return this.jApi.article.update(Object.assign(Object.assign({},e),{type:"faqItem",format:null!=t?t:"raw-view"}))}moveEntry(e,t){return this.network.postCSRF(Object.assign(Object.assign({o:"faq",f:"move-entry"},e),{format:null!=t?t:"raw-view"}))}moveTheme(e,t){return this.network.postCSRF(Object.assign(Object.assign({o:"faq",f:"move-theme"},e),{format:null!=t?t:"raw-view"}))}}class de extends n{getBanks(e="list"){return this.network.post({o:"fileBank",f:"getBanks",format:e}).then((e=>e.result))}getFolders(e){return this.network.post({o:"fileBank",f:"getFolders",parentURI:e})}getDocuments(e){return this.network.post({o:"fileBank",f:"getDocuments",parentURI:e})}}class ue extends n{countAction(e,t){return this.network.post({o:"activityLog",f:"log",count:!0,verb:e,uri:t})}useWebVersion(){return this.network.post({o:"global",f:"useWebVersion"})}}var pe,me;class he extends n{autocomplete(e){return this.network.post({o:"autocomplete",f:"spot",q:e,idToUri:!1}).then((e=>e.result))}create(e,t){return this.network.post(Object.assign(Object.assign({o:"spot",f:"create"},e),{format:t}))}update(e,t){const{spotBanner:i}=e,n=function(e,t){var i={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(i[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var r=0;for(n=Object.getOwnPropertySymbols(e);r<n.length;r++)t.indexOf(n[r])<0&&Object.prototype.propertyIsEnumerable.call(e,n[r])&&(i[n[r]]=e[n[r]])}return i}(e,["spotBanner"]);return this.network.postCSRF(Object.assign(Object.assign({o:"spot",f:"update"},n),{format:t}))}getSpot(e,t){return this.network.post({o:"spot",f:"getSpot",idSpot:e,format:t})}getProperties(e){return this.network.post({o:"spot",f:"getProperties",idSpot:e})}getApplications(){return this.network.post({o:"spot",f:"get-available-widget"})}getCategories(){return this.network.post({o:"spot",f:"get-categories"})}getObjectListJamespotSpotMembers(e,t,i,n=1){return this.network.post({o:"objectListJamespot",f:"SpotMembers",idSpot:e,limit:i,page:n,format:"raw-little",query:t})}list(e){return this.network.post(Object.assign({o:"objectList",f:"jamespotSpotQueryList"},e))}resetNotifications(e){return this.network.post(Object.assign({o:"spot",f:"resetNotifications"},e))}getUserLevelAndRight(e){return this.network.post({o:"spot",f:"getUserLevelAndRight",idSpot:e})}groupRequest(e){return this.network.postCSRF({o:"spot",f:"request",idSpot:e})}groupAddToFavorite(e){return this.network.postCSRF({o:"spot",f:"addToFavorite",idSpot:e})}}!function(e){e.assertEqual=e=>e,e.assertIs=function(e){},e.assertNever=function(e){throw new Error},e.arrayToEnum=e=>{const t={};for(const i of e)t[i]=i;return t},e.getValidEnumValues=t=>{const i=e.objectKeys(t).filter((e=>"number"!=typeof t[t[e]])),n={};for(const e of i)n[e]=t[e];return e.objectValues(n)},e.objectValues=t=>e.objectKeys(t).map((function(e){return t[e]})),e.objectKeys="function"==typeof Object.keys?e=>Object.keys(e):e=>{const t=[];for(const i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.push(i);return t},e.find=(e,t)=>{for(const i of e)if(t(i))return i},e.isInteger="function"==typeof Number.isInteger?e=>Number.isInteger(e):e=>"number"==typeof e&&isFinite(e)&&Math.floor(e)===e,e.joinValues=function(e,t=" | "){return e.map((e=>"string"==typeof e?`'${e}'`:e)).join(t)},e.jsonStringifyReplacer=(e,t)=>"bigint"==typeof t?t.toString():t}(pe||(pe={})),function(e){e.mergeShapes=(e,t)=>({...e,...t})}(me||(me={}));const fe=pe.arrayToEnum(["string","nan","number","integer","float","boolean","date","bigint","symbol","function","undefined","null","array","object","unknown","promise","void","never","map","set"]),ge=e=>{switch(typeof e){case"undefined":return fe.undefined;case"string":return fe.string;case"number":return isNaN(e)?fe.nan:fe.number;case"boolean":return fe.boolean;case"function":return fe.function;case"bigint":return fe.bigint;case"symbol":return fe.symbol;case"object":return Array.isArray(e)?fe.array:null===e?fe.null:e.then&&"function"==typeof e.then&&e.catch&&"function"==typeof e.catch?fe.promise:"undefined"!=typeof Map&&e instanceof Map?fe.map:"undefined"!=typeof Set&&e instanceof Set?fe.set:"undefined"!=typeof Date&&e instanceof Date?fe.date:fe.object;default:return fe.unknown}},ye=pe.arrayToEnum(["invalid_type","invalid_literal","custom","invalid_union","invalid_union_discriminator","invalid_enum_value","unrecognized_keys","invalid_arguments","invalid_return_type","invalid_date","invalid_string","too_small","too_big","invalid_intersection_types","not_multiple_of","not_finite"]);class be extends Error{constructor(e){super(),this.issues=[],this.addIssue=e=>{this.issues=[...this.issues,e]},this.addIssues=(e=[])=>{this.issues=[...this.issues,...e]};const t=new.target.prototype;Object.setPrototypeOf?Object.setPrototypeOf(this,t):this.__proto__=t,this.name="ZodError",this.issues=e}get errors(){return this.issues}format(e){const t=e||function(e){return e.message},i={_errors:[]},n=e=>{for(const r of e.issues)if("invalid_union"===r.code)r.unionErrors.map(n);else if("invalid_return_type"===r.code)n(r.returnTypeError);else if("invalid_arguments"===r.code)n(r.argumentsError);else if(0===r.path.length)i._errors.push(t(r));else{let e=i,n=0;for(;n<r.path.length;){const i=r.path[n];n===r.path.length-1?(e[i]=e[i]||{_errors:[]},e[i]._errors.push(t(r))):e[i]=e[i]||{_errors:[]},e=e[i],n++}}};return n(this),i}toString(){return this.message}get message(){return JSON.stringify(this.issues,pe.jsonStringifyReplacer,2)}get isEmpty(){return 0===this.issues.length}flatten(e=(e=>e.message)){const t={},i=[];for(const n of this.issues)n.path.length>0?(t[n.path[0]]=t[n.path[0]]||[],t[n.path[0]].push(e(n))):i.push(e(n));return{formErrors:i,fieldErrors:t}}get formErrors(){return this.flatten()}}be.create=e=>new be(e);const ve=(e,t)=>{let i;switch(e.code){case ye.invalid_type:i=e.received===fe.undefined?"Required":`Expected ${e.expected}, received ${e.received}`;break;case ye.invalid_literal:i=`Invalid literal value, expected ${JSON.stringify(e.expected,pe.jsonStringifyReplacer)}`;break;case ye.unrecognized_keys:i=`Unrecognized key(s) in object: ${pe.joinValues(e.keys,", ")}`;break;case ye.invalid_union:i="Invalid input";break;case ye.invalid_union_discriminator:i=`Invalid discriminator value. Expected ${pe.joinValues(e.options)}`;break;case ye.invalid_enum_value:i=`Invalid enum value. Expected ${pe.joinValues(e.options)}, received '${e.received}'`;break;case ye.invalid_arguments:i="Invalid function arguments";break;case ye.invalid_return_type:i="Invalid function return type";break;case ye.invalid_date:i="Invalid date";break;case ye.invalid_string:"object"==typeof e.validation?"includes"in e.validation?(i=`Invalid input: must include "${e.validation.includes}"`,"number"==typeof e.validation.position&&(i=`${i} at one or more positions greater than or equal to ${e.validation.position}`)):"startsWith"in e.validation?i=`Invalid input: must start with "${e.validation.startsWith}"`:"endsWith"in e.validation?i=`Invalid input: must end with "${e.validation.endsWith}"`:pe.assertNever(e.validation):i="regex"!==e.validation?`Invalid ${e.validation}`:"Invalid";break;case ye.too_small:i="array"===e.type?`Array must contain ${e.exact?"exactly":e.inclusive?"at least":"more than"} ${e.minimum} element(s)`:"string"===e.type?`String must contain ${e.exact?"exactly":e.inclusive?"at least":"over"} ${e.minimum} character(s)`:"number"===e.type?`Number must be ${e.exact?"exactly equal to ":e.inclusive?"greater than or equal to ":"greater than "}${e.minimum}`:"date"===e.type?`Date must be ${e.exact?"exactly equal to ":e.inclusive?"greater than or equal to ":"greater than "}${new Date(Number(e.minimum))}`:"Invalid input";break;case ye.too_big:i="array"===e.type?`Array must contain ${e.exact?"exactly":e.inclusive?"at most":"less than"} ${e.maximum} element(s)`:"string"===e.type?`String must contain ${e.exact?"exactly":e.inclusive?"at most":"under"} ${e.maximum} character(s)`:"number"===e.type?`Number must be ${e.exact?"exactly":e.inclusive?"less than or equal to":"less than"} ${e.maximum}`:"bigint"===e.type?`BigInt must be ${e.exact?"exactly":e.inclusive?"less than or equal to":"less than"} ${e.maximum}`:"date"===e.type?`Date must be ${e.exact?"exactly":e.inclusive?"smaller than or equal to":"smaller than"} ${new Date(Number(e.maximum))}`:"Invalid input";break;case ye.custom:i="Invalid input";break;case ye.invalid_intersection_types:i="Intersection results could not be merged";break;case ye.not_multiple_of:i=`Number must be a multiple of ${e.multipleOf}`;break;case ye.not_finite:i="Number must be finite";break;default:i=t.defaultError,pe.assertNever(e)}return{message:i}};let we=ve;function _e(){return we}const ke=e=>{const{data:t,path:i,errorMaps:n,issueData:r}=e,s=[...i,...r.path||[]],a={...r,path:s};let o="";const c=n.filter((e=>!!e)).slice().reverse();for(const e of c)o=e(a,{data:t,defaultError:o}).message;return{...r,path:s,message:r.message||o}};function xe(e,t){const i=ke({issueData:t,data:e.data,path:e.path,errorMaps:[e.common.contextualErrorMap,e.schemaErrorMap,_e(),ve].filter((e=>!!e))});e.common.issues.push(i)}class je{constructor(){this.value="valid"}dirty(){"valid"===this.value&&(this.value="dirty")}abort(){"aborted"!==this.value&&(this.value="aborted")}static mergeArray(e,t){const i=[];for(const n of t){if("aborted"===n.status)return Se;"dirty"===n.status&&e.dirty(),i.push(n.value)}return{status:e.value,value:i}}static async mergeObjectAsync(e,t){const i=[];for(const e of t)i.push({key:await e.key,value:await e.value});return je.mergeObjectSync(e,i)}static mergeObjectSync(e,t){const i={};for(const n of t){const{key:t,value:r}=n;if("aborted"===t.status)return Se;if("aborted"===r.status)return Se;"dirty"===t.status&&e.dirty(),"dirty"===r.status&&e.dirty(),"__proto__"===t.value||void 0===r.value&&!n.alwaysSet||(i[t.value]=r.value)}return{status:e.value,value:i}}}const Se=Object.freeze({status:"aborted"}),Ae=e=>({status:"dirty",value:e}),Oe=e=>({status:"valid",value:e}),Te=e=>"aborted"===e.status,Ce=e=>"dirty"===e.status,Fe=e=>"valid"===e.status,Re=e=>"undefined"!=typeof Promise&&e instanceof Promise;var Ee;!function(e){e.errToObj=e=>"string"==typeof e?{message:e}:e||{},e.toString=e=>"string"==typeof e?e:null==e?void 0:e.message}(Ee||(Ee={}));class Le{constructor(e,t,i,n){this._cachedPath=[],this.parent=e,this.data=t,this._path=i,this._key=n}get path(){return this._cachedPath.length||(this._key instanceof Array?this._cachedPath.push(...this._path,...this._key):this._cachedPath.push(...this._path,this._key)),this._cachedPath}}const Pe=(e,t)=>{if(Fe(t))return{success:!0,data:t.value};if(!e.common.issues.length)throw new Error("Validation failed but no issues detected.");return{success:!1,get error(){if(this._error)return this._error;const t=new be(e.common.issues);return this._error=t,this._error}}};function Ze(e){if(!e)return{};const{errorMap:t,invalid_type_error:i,required_error:n,description:r}=e;if(t&&(i||n))throw new Error('Can\'t use "invalid_type_error" or "required_error" in conjunction with custom error map.');return t?{errorMap:t,description:r}:{errorMap:(e,t)=>"invalid_type"!==e.code?{message:t.defaultError}:void 0===t.data?{message:null!=n?n:t.defaultError}:{message:null!=i?i:t.defaultError},description:r}}class Ne{constructor(e){this.spa=this.safeParseAsync,this._def=e,this.parse=this.parse.bind(this),this.safeParse=this.safeParse.bind(this),this.parseAsync=this.parseAsync.bind(this),this.safeParseAsync=this.safeParseAsync.bind(this),this.spa=this.spa.bind(this),this.refine=this.refine.bind(this),this.refinement=this.refinement.bind(this),this.superRefine=this.superRefine.bind(this),this.optional=this.optional.bind(this),this.nullable=this.nullable.bind(this),this.nullish=this.nullish.bind(this),this.array=this.array.bind(this),this.promise=this.promise.bind(this),this.or=this.or.bind(this),this.and=this.and.bind(this),this.transform=this.transform.bind(this),this.brand=this.brand.bind(this),this.default=this.default.bind(this),this.catch=this.catch.bind(this),this.describe=this.describe.bind(this),this.pipe=this.pipe.bind(this),this.readonly=this.readonly.bind(this),this.isNullable=this.isNullable.bind(this),this.isOptional=this.isOptional.bind(this)}get description(){return this._def.description}_getType(e){return ge(e.data)}_getOrReturnCtx(e,t){return t||{common:e.parent.common,data:e.data,parsedType:ge(e.data),schemaErrorMap:this._def.errorMap,path:e.path,parent:e.parent}}_processInputParams(e){return{status:new je,ctx:{common:e.parent.common,data:e.data,parsedType:ge(e.data),schemaErrorMap:this._def.errorMap,path:e.path,parent:e.parent}}}_parseSync(e){const t=this._parse(e);if(Re(t))throw new Error("Synchronous parse encountered promise.");return t}_parseAsync(e){const t=this._parse(e);return Promise.resolve(t)}parse(e,t){const i=this.safeParse(e,t);if(i.success)return i.data;throw i.error}safeParse(e,t){var i;const n={common:{issues:[],async:null!==(i=null==t?void 0:t.async)&&void 0!==i&&i,contextualErrorMap:null==t?void 0:t.errorMap},path:(null==t?void 0:t.path)||[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:ge(e)},r=this._parseSync({data:e,path:n.path,parent:n});return Pe(n,r)}async parseAsync(e,t){const i=await this.safeParseAsync(e,t);if(i.success)return i.data;throw i.error}async safeParseAsync(e,t){const i={common:{issues:[],contextualErrorMap:null==t?void 0:t.errorMap,async:!0},path:(null==t?void 0:t.path)||[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:ge(e)},n=this._parse({data:e,path:i.path,parent:i}),r=await(Re(n)?n:Promise.resolve(n));return Pe(i,r)}refine(e,t){const i=e=>"string"==typeof t||void 0===t?{message:t}:"function"==typeof t?t(e):t;return this._refinement(((t,n)=>{const r=e(t),s=()=>n.addIssue({code:ye.custom,...i(t)});return"undefined"!=typeof Promise&&r instanceof Promise?r.then((e=>!!e||(s(),!1))):!!r||(s(),!1)}))}refinement(e,t){return this._refinement(((i,n)=>!!e(i)||(n.addIssue("function"==typeof t?t(i,n):t),!1)))}_refinement(e){return new xt({schema:this,typeName:Zt.ZodEffects,effect:{type:"refinement",refinement:e}})}superRefine(e){return this._refinement(e)}optional(){return jt.create(this,this._def)}nullable(){return St.create(this,this._def)}nullish(){return this.nullable().optional()}array(){return rt.create(this,this._def)}promise(){return kt.create(this,this._def)}or(e){return ot.create([this,e],this._def)}and(e){return ut.create(this,e,this._def)}transform(e){return new xt({...Ze(this._def),schema:this,typeName:Zt.ZodEffects,effect:{type:"transform",transform:e}})}default(e){const t="function"==typeof e?e:()=>e;return new At({...Ze(this._def),innerType:this,defaultValue:t,typeName:Zt.ZodDefault})}brand(){return new Ft({typeName:Zt.ZodBranded,type:this,...Ze(this._def)})}catch(e){const t="function"==typeof e?e:()=>e;return new Ot({...Ze(this._def),innerType:this,catchValue:t,typeName:Zt.ZodCatch})}describe(e){return new(0,this.constructor)({...this._def,description:e})}pipe(e){return Rt.create(this,e)}readonly(){return Et.create(this)}isOptional(){return this.safeParse(void 0).success}isNullable(){return this.safeParse(null).success}}const Ie=/^c[^\s-]{8,}$/i,De=/^[a-z][a-z0-9]*$/,Me=/^[0-9A-HJKMNP-TV-Z]{26}$/,Ue=/^[0-9a-fA-F]{8}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{12}$/i,We=/^(?!\.)(?!.*\.\.)([A-Z0-9_+-\.]*)[A-Z0-9_+-]@([A-Z0-9][A-Z0-9\-]*\.)+[A-Z]{2,}$/i;let $e;const qe=/^(((25[0-5])|(2[0-4][0-9])|(1[0-9]{2})|([0-9]{1,2}))\.){3}((25[0-5])|(2[0-4][0-9])|(1[0-9]{2})|([0-9]{1,2}))$/,Be=/^(([a-f0-9]{1,4}:){7}|::([a-f0-9]{1,4}:){0,6}|([a-f0-9]{1,4}:){1}:([a-f0-9]{1,4}:){0,5}|([a-f0-9]{1,4}:){2}:([a-f0-9]{1,4}:){0,4}|([a-f0-9]{1,4}:){3}:([a-f0-9]{1,4}:){0,3}|([a-f0-9]{1,4}:){4}:([a-f0-9]{1,4}:){0,2}|([a-f0-9]{1,4}:){5}:([a-f0-9]{1,4}:){0,1})([a-f0-9]{1,4}|(((25[0-5])|(2[0-4][0-9])|(1[0-9]{2})|([0-9]{1,2}))\.){3}((25[0-5])|(2[0-4][0-9])|(1[0-9]{2})|([0-9]{1,2})))$/;class ze extends Ne{_parse(e){if(this._def.coerce&&(e.data=String(e.data)),this._getType(e)!==fe.string){const t=this._getOrReturnCtx(e);return xe(t,{code:ye.invalid_type,expected:fe.string,received:t.parsedType}),Se}const t=new je;let i;for(const a of this._def.checks)if("min"===a.kind)e.data.length<a.value&&(i=this._getOrReturnCtx(e,i),xe(i,{code:ye.too_small,minimum:a.value,type:"string",inclusive:!0,exact:!1,message:a.message}),t.dirty());else if("max"===a.kind)e.data.length>a.value&&(i=this._getOrReturnCtx(e,i),xe(i,{code:ye.too_big,maximum:a.value,type:"string",inclusive:!0,exact:!1,message:a.message}),t.dirty());else if("length"===a.kind){const n=e.data.length>a.value,r=e.data.length<a.value;(n||r)&&(i=this._getOrReturnCtx(e,i),n?xe(i,{code:ye.too_big,maximum:a.value,type:"string",inclusive:!0,exact:!0,message:a.message}):r&&xe(i,{code:ye.too_small,minimum:a.value,type:"string",inclusive:!0,exact:!0,message:a.message}),t.dirty())}else if("email"===a.kind)We.test(e.data)||(i=this._getOrReturnCtx(e,i),xe(i,{validation:"email",code:ye.invalid_string,message:a.message}),t.dirty());else if("emoji"===a.kind)$e||($e=new RegExp("^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$","u")),$e.test(e.data)||(i=this._getOrReturnCtx(e,i),xe(i,{validation:"emoji",code:ye.invalid_string,message:a.message}),t.dirty());else if("uuid"===a.kind)Ue.test(e.data)||(i=this._getOrReturnCtx(e,i),xe(i,{validation:"uuid",code:ye.invalid_string,message:a.message}),t.dirty());else if("cuid"===a.kind)Ie.test(e.data)||(i=this._getOrReturnCtx(e,i),xe(i,{validation:"cuid",code:ye.invalid_string,message:a.message}),t.dirty());else if("cuid2"===a.kind)De.test(e.data)||(i=this._getOrReturnCtx(e,i),xe(i,{validation:"cuid2",code:ye.invalid_string,message:a.message}),t.dirty());else if("ulid"===a.kind)Me.test(e.data)||(i=this._getOrReturnCtx(e,i),xe(i,{validation:"ulid",code:ye.invalid_string,message:a.message}),t.dirty());else if("url"===a.kind)try{new URL(e.data)}catch(n){i=this._getOrReturnCtx(e,i),xe(i,{validation:"url",code:ye.invalid_string,message:a.message}),t.dirty()}else"regex"===a.kind?(a.regex.lastIndex=0,a.regex.test(e.data)||(i=this._getOrReturnCtx(e,i),xe(i,{validation:"regex",code:ye.invalid_string,message:a.message}),t.dirty())):"trim"===a.kind?e.data=e.data.trim():"includes"===a.kind?e.data.includes(a.value,a.position)||(i=this._getOrReturnCtx(e,i),xe(i,{code:ye.invalid_string,validation:{includes:a.value,position:a.position},message:a.message}),t.dirty()):"toLowerCase"===a.kind?e.data=e.data.toLowerCase():"toUpperCase"===a.kind?e.data=e.data.toUpperCase():"startsWith"===a.kind?e.data.startsWith(a.value)||(i=this._getOrReturnCtx(e,i),xe(i,{code:ye.invalid_string,validation:{startsWith:a.value},message:a.message}),t.dirty()):"endsWith"===a.kind?e.data.endsWith(a.value)||(i=this._getOrReturnCtx(e,i),xe(i,{code:ye.invalid_string,validation:{endsWith:a.value},message:a.message}),t.dirty()):"datetime"===a.kind?((s=a).precision?s.offset?new RegExp(`^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}\\.\\d{${s.precision}}(([+-]\\d{2}(:?\\d{2})?)|Z)$`):new RegExp(`^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}\\.\\d{${s.precision}}Z$`):0===s.precision?s.offset?new RegExp("^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(([+-]\\d{2}(:?\\d{2})?)|Z)$"):new RegExp("^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}Z$"):s.offset?new RegExp("^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(\\.\\d+)?(([+-]\\d{2}(:?\\d{2})?)|Z)$"):new RegExp("^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(\\.\\d+)?Z$")).test(e.data)||(i=this._getOrReturnCtx(e,i),xe(i,{code:ye.invalid_string,validation:"datetime",message:a.message}),t.dirty()):"ip"===a.kind?(n=e.data,("v4"!==(r=a.version)&&r||!qe.test(n))&&("v6"!==r&&r||!Be.test(n))&&(i=this._getOrReturnCtx(e,i),xe(i,{validation:"ip",code:ye.invalid_string,message:a.message}),t.dirty())):pe.assertNever(a);var n,r,s;return{status:t.value,value:e.data}}_regex(e,t,i){return this.refinement((t=>e.test(t)),{validation:t,code:ye.invalid_string,...Ee.errToObj(i)})}_addCheck(e){return new ze({...this._def,checks:[...this._def.checks,e]})}email(e){return this._addCheck({kind:"email",...Ee.errToObj(e)})}url(e){return this._addCheck({kind:"url",...Ee.errToObj(e)})}emoji(e){return this._addCheck({kind:"emoji",...Ee.errToObj(e)})}uuid(e){return this._addCheck({kind:"uuid",...Ee.errToObj(e)})}cuid(e){return this._addCheck({kind:"cuid",...Ee.errToObj(e)})}cuid2(e){return this._addCheck({kind:"cuid2",...Ee.errToObj(e)})}ulid(e){return this._addCheck({kind:"ulid",...Ee.errToObj(e)})}ip(e){return this._addCheck({kind:"ip",...Ee.errToObj(e)})}datetime(e){var t;return"string"==typeof e?this._addCheck({kind:"datetime",precision:null,offset:!1,message:e}):this._addCheck({kind:"datetime",precision:void 0===(null==e?void 0:e.precision)?null:null==e?void 0:e.precision,offset:null!==(t=null==e?void 0:e.offset)&&void 0!==t&&t,...Ee.errToObj(null==e?void 0:e.message)})}regex(e,t){return this._addCheck({kind:"regex",regex:e,...Ee.errToObj(t)})}includes(e,t){return this._addCheck({kind:"includes",value:e,position:null==t?void 0:t.position,...Ee.errToObj(null==t?void 0:t.message)})}startsWith(e,t){return this._addCheck({kind:"startsWith",value:e,...Ee.errToObj(t)})}endsWith(e,t){return this._addCheck({kind:"endsWith",value:e,...Ee.errToObj(t)})}min(e,t){return this._addCheck({kind:"min",value:e,...Ee.errToObj(t)})}max(e,t){return this._addCheck({kind:"max",value:e,...Ee.errToObj(t)})}length(e,t){return this._addCheck({kind:"length",value:e,...Ee.errToObj(t)})}nonempty(e){return this.min(1,Ee.errToObj(e))}trim(){return new ze({...this._def,checks:[...this._def.checks,{kind:"trim"}]})}toLowerCase(){return new ze({...this._def,checks:[...this._def.checks,{kind:"toLowerCase"}]})}toUpperCase(){return new ze({...this._def,checks:[...this._def.checks,{kind:"toUpperCase"}]})}get isDatetime(){return!!this._def.checks.find((e=>"datetime"===e.kind))}get isEmail(){return!!this._def.checks.find((e=>"email"===e.kind))}get isURL(){return!!this._def.checks.find((e=>"url"===e.kind))}get isEmoji(){return!!this._def.checks.find((e=>"emoji"===e.kind))}get isUUID(){return!!this._def.checks.find((e=>"uuid"===e.kind))}get isCUID(){return!!this._def.checks.find((e=>"cuid"===e.kind))}get isCUID2(){return!!this._def.checks.find((e=>"cuid2"===e.kind))}get isULID(){return!!this._def.checks.find((e=>"ulid"===e.kind))}get isIP(){return!!this._def.checks.find((e=>"ip"===e.kind))}get minLength(){let e=null;for(const t of this._def.checks)"min"===t.kind&&(null===e||t.value>e)&&(e=t.value);return e}get maxLength(){let e=null;for(const t of this._def.checks)"max"===t.kind&&(null===e||t.value<e)&&(e=t.value);return e}}function Ve(e,t){const i=(e.toString().split(".")[1]||"").length,n=(t.toString().split(".")[1]||"").length,r=i>n?i:n;return parseInt(e.toFixed(r).replace(".",""))%parseInt(t.toFixed(r).replace(".",""))/Math.pow(10,r)}ze.create=e=>{var t;return new ze({checks:[],typeName:Zt.ZodString,coerce:null!==(t=null==e?void 0:e.coerce)&&void 0!==t&&t,...Ze(e)})};class Je extends Ne{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte,this.step=this.multipleOf}_parse(e){if(this._def.coerce&&(e.data=Number(e.data)),this._getType(e)!==fe.number){const t=this._getOrReturnCtx(e);return xe(t,{code:ye.invalid_type,expected:fe.number,received:t.parsedType}),Se}let t;const i=new je;for(const n of this._def.checks)"int"===n.kind?pe.isInteger(e.data)||(t=this._getOrReturnCtx(e,t),xe(t,{code:ye.invalid_type,expected:"integer",received:"float",message:n.message}),i.dirty()):"min"===n.kind?(n.inclusive?e.data<n.value:e.data<=n.value)&&(t=this._getOrReturnCtx(e,t),xe(t,{code:ye.too_small,minimum:n.value,type:"number",inclusive:n.inclusive,exact:!1,message:n.message}),i.dirty()):"max"===n.kind?(n.inclusive?e.data>n.value:e.data>=n.value)&&(t=this._getOrReturnCtx(e,t),xe(t,{code:ye.too_big,maximum:n.value,type:"number",inclusive:n.inclusive,exact:!1,message:n.message}),i.dirty()):"multipleOf"===n.kind?0!==Ve(e.data,n.value)&&(t=this._getOrReturnCtx(e,t),xe(t,{code:ye.not_multiple_of,multipleOf:n.value,message:n.message}),i.dirty()):"finite"===n.kind?Number.isFinite(e.data)||(t=this._getOrReturnCtx(e,t),xe(t,{code:ye.not_finite,message:n.message}),i.dirty()):pe.assertNever(n);return{status:i.value,value:e.data}}gte(e,t){return this.setLimit("min",e,!0,Ee.toString(t))}gt(e,t){return this.setLimit("min",e,!1,Ee.toString(t))}lte(e,t){return this.setLimit("max",e,!0,Ee.toString(t))}lt(e,t){return this.setLimit("max",e,!1,Ee.toString(t))}setLimit(e,t,i,n){return new Je({...this._def,checks:[...this._def.checks,{kind:e,value:t,inclusive:i,message:Ee.toString(n)}]})}_addCheck(e){return new Je({...this._def,checks:[...this._def.checks,e]})}int(e){return this._addCheck({kind:"int",message:Ee.toString(e)})}positive(e){return this._addCheck({kind:"min",value:0,inclusive:!1,message:Ee.toString(e)})}negative(e){return this._addCheck({kind:"max",value:0,inclusive:!1,message:Ee.toString(e)})}nonpositive(e){return this._addCheck({kind:"max",value:0,inclusive:!0,message:Ee.toString(e)})}nonnegative(e){return this._addCheck({kind:"min",value:0,inclusive:!0,message:Ee.toString(e)})}multipleOf(e,t){return this._addCheck({kind:"multipleOf",value:e,message:Ee.toString(t)})}finite(e){return this._addCheck({kind:"finite",message:Ee.toString(e)})}safe(e){return this._addCheck({kind:"min",inclusive:!0,value:Number.MIN_SAFE_INTEGER,message:Ee.toString(e)})._addCheck({kind:"max",inclusive:!0,value:Number.MAX_SAFE_INTEGER,message:Ee.toString(e)})}get minValue(){let e=null;for(const t of this._def.checks)"min"===t.kind&&(null===e||t.value>e)&&(e=t.value);return e}get maxValue(){let e=null;for(const t of this._def.checks)"max"===t.kind&&(null===e||t.value<e)&&(e=t.value);return e}get isInt(){return!!this._def.checks.find((e=>"int"===e.kind||"multipleOf"===e.kind&&pe.isInteger(e.value)))}get isFinite(){let e=null,t=null;for(const i of this._def.checks){if("finite"===i.kind||"int"===i.kind||"multipleOf"===i.kind)return!0;"min"===i.kind?(null===t||i.value>t)&&(t=i.value):"max"===i.kind&&(null===e||i.value<e)&&(e=i.value)}return Number.isFinite(t)&&Number.isFinite(e)}}Je.create=e=>new Je({checks:[],typeName:Zt.ZodNumber,coerce:(null==e?void 0:e.coerce)||!1,...Ze(e)});class Ge extends Ne{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte}_parse(e){if(this._def.coerce&&(e.data=BigInt(e.data)),this._getType(e)!==fe.bigint){const t=this._getOrReturnCtx(e);return xe(t,{code:ye.invalid_type,expected:fe.bigint,received:t.parsedType}),Se}let t;const i=new je;for(const n of this._def.checks)"min"===n.kind?(n.inclusive?e.data<n.value:e.data<=n.value)&&(t=this._getOrReturnCtx(e,t),xe(t,{code:ye.too_small,type:"bigint",minimum:n.value,inclusive:n.inclusive,message:n.message}),i.dirty()):"max"===n.kind?(n.inclusive?e.data>n.value:e.data>=n.value)&&(t=this._getOrReturnCtx(e,t),xe(t,{code:ye.too_big,type:"bigint",maximum:n.value,inclusive:n.inclusive,message:n.message}),i.dirty()):"multipleOf"===n.kind?e.data%n.value!==BigInt(0)&&(t=this._getOrReturnCtx(e,t),xe(t,{code:ye.not_multiple_of,multipleOf:n.value,message:n.message}),i.dirty()):pe.assertNever(n);return{status:i.value,value:e.data}}gte(e,t){return this.setLimit("min",e,!0,Ee.toString(t))}gt(e,t){return this.setLimit("min",e,!1,Ee.toString(t))}lte(e,t){return this.setLimit("max",e,!0,Ee.toString(t))}lt(e,t){return this.setLimit("max",e,!1,Ee.toString(t))}setLimit(e,t,i,n){return new Ge({...this._def,checks:[...this._def.checks,{kind:e,value:t,inclusive:i,message:Ee.toString(n)}]})}_addCheck(e){return new Ge({...this._def,checks:[...this._def.checks,e]})}positive(e){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!1,message:Ee.toString(e)})}negative(e){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!1,message:Ee.toString(e)})}nonpositive(e){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!0,message:Ee.toString(e)})}nonnegative(e){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!0,message:Ee.toString(e)})}multipleOf(e,t){return this._addCheck({kind:"multipleOf",value:e,message:Ee.toString(t)})}get minValue(){let e=null;for(const t of this._def.checks)"min"===t.kind&&(null===e||t.value>e)&&(e=t.value);return e}get maxValue(){let e=null;for(const t of this._def.checks)"max"===t.kind&&(null===e||t.value<e)&&(e=t.value);return e}}Ge.create=e=>{var t;return new Ge({checks:[],typeName:Zt.ZodBigInt,coerce:null!==(t=null==e?void 0:e.coerce)&&void 0!==t&&t,...Ze(e)})};class Ke extends Ne{_parse(e){if(this._def.coerce&&(e.data=Boolean(e.data)),this._getType(e)!==fe.boolean){const t=this._getOrReturnCtx(e);return xe(t,{code:ye.invalid_type,expected:fe.boolean,received:t.parsedType}),Se}return Oe(e.data)}}Ke.create=e=>new Ke({typeName:Zt.ZodBoolean,coerce:(null==e?void 0:e.coerce)||!1,...Ze(e)});class He extends Ne{_parse(e){if(this._def.coerce&&(e.data=new Date(e.data)),this._getType(e)!==fe.date){const t=this._getOrReturnCtx(e);return xe(t,{code:ye.invalid_type,expected:fe.date,received:t.parsedType}),Se}if(isNaN(e.data.getTime()))return xe(this._getOrReturnCtx(e),{code:ye.invalid_date}),Se;const t=new je;let i;for(const n of this._def.checks)"min"===n.kind?e.data.getTime()<n.value&&(i=this._getOrReturnCtx(e,i),xe(i,{code:ye.too_small,message:n.message,inclusive:!0,exact:!1,minimum:n.value,type:"date"}),t.dirty()):"max"===n.kind?e.data.getTime()>n.value&&(i=this._getOrReturnCtx(e,i),xe(i,{code:ye.too_big,message:n.message,inclusive:!0,exact:!1,maximum:n.value,type:"date"}),t.dirty()):pe.assertNever(n);return{status:t.value,value:new Date(e.data.getTime())}}_addCheck(e){return new He({...this._def,checks:[...this._def.checks,e]})}min(e,t){return this._addCheck({kind:"min",value:e.getTime(),message:Ee.toString(t)})}max(e,t){return this._addCheck({kind:"max",value:e.getTime(),message:Ee.toString(t)})}get minDate(){let e=null;for(const t of this._def.checks)"min"===t.kind&&(null===e||t.value>e)&&(e=t.value);return null!=e?new Date(e):null}get maxDate(){let e=null;for(const t of this._def.checks)"max"===t.kind&&(null===e||t.value<e)&&(e=t.value);return null!=e?new Date(e):null}}He.create=e=>new He({checks:[],coerce:(null==e?void 0:e.coerce)||!1,typeName:Zt.ZodDate,...Ze(e)});class Qe extends Ne{_parse(e){if(this._getType(e)!==fe.symbol){const t=this._getOrReturnCtx(e);return xe(t,{code:ye.invalid_type,expected:fe.symbol,received:t.parsedType}),Se}return Oe(e.data)}}Qe.create=e=>new Qe({typeName:Zt.ZodSymbol,...Ze(e)});class Ye extends Ne{_parse(e){if(this._getType(e)!==fe.undefined){const t=this._getOrReturnCtx(e);return xe(t,{code:ye.invalid_type,expected:fe.undefined,received:t.parsedType}),Se}return Oe(e.data)}}Ye.create=e=>new Ye({typeName:Zt.ZodUndefined,...Ze(e)});class Xe extends Ne{_parse(e){if(this._getType(e)!==fe.null){const t=this._getOrReturnCtx(e);return xe(t,{code:ye.invalid_type,expected:fe.null,received:t.parsedType}),Se}return Oe(e.data)}}Xe.create=e=>new Xe({typeName:Zt.ZodNull,...Ze(e)});class et extends Ne{constructor(){super(...arguments),this._any=!0}_parse(e){return Oe(e.data)}}et.create=e=>new et({typeName:Zt.ZodAny,...Ze(e)});class tt extends Ne{constructor(){super(...arguments),this._unknown=!0}_parse(e){return Oe(e.data)}}tt.create=e=>new tt({typeName:Zt.ZodUnknown,...Ze(e)});class it extends Ne{_parse(e){const t=this._getOrReturnCtx(e);return xe(t,{code:ye.invalid_type,expected:fe.never,received:t.parsedType}),Se}}it.create=e=>new it({typeName:Zt.ZodNever,...Ze(e)});class nt extends Ne{_parse(e){if(this._getType(e)!==fe.undefined){const t=this._getOrReturnCtx(e);return xe(t,{code:ye.invalid_type,expected:fe.void,received:t.parsedType}),Se}return Oe(e.data)}}nt.create=e=>new nt({typeName:Zt.ZodVoid,...Ze(e)});class rt extends Ne{_parse(e){const{ctx:t,status:i}=this._processInputParams(e),n=this._def;if(t.parsedType!==fe.array)return xe(t,{code:ye.invalid_type,expected:fe.array,received:t.parsedType}),Se;if(null!==n.exactLength){const e=t.data.length>n.exactLength.value,r=t.data.length<n.exactLength.value;(e||r)&&(xe(t,{code:e?ye.too_big:ye.too_small,minimum:r?n.exactLength.value:void 0,maximum:e?n.exactLength.value:void 0,type:"array",inclusive:!0,exact:!0,message:n.exactLength.message}),i.dirty())}if(null!==n.minLength&&t.data.length<n.minLength.value&&(xe(t,{code:ye.too_small,minimum:n.minLength.value,type:"array",inclusive:!0,exact:!1,message:n.minLength.message}),i.dirty()),null!==n.maxLength&&t.data.length>n.maxLength.value&&(xe(t,{code:ye.too_big,maximum:n.maxLength.value,type:"array",inclusive:!0,exact:!1,message:n.maxLength.message}),i.dirty()),t.common.async)return Promise.all([...t.data].map(((e,i)=>n.type._parseAsync(new Le(t,e,t.path,i))))).then((e=>je.mergeArray(i,e)));const r=[...t.data].map(((e,i)=>n.type._parseSync(new Le(t,e,t.path,i))));return je.mergeArray(i,r)}get element(){return this._def.type}min(e,t){return new rt({...this._def,minLength:{value:e,message:Ee.toString(t)}})}max(e,t){return new rt({...this._def,maxLength:{value:e,message:Ee.toString(t)}})}length(e,t){return new rt({...this._def,exactLength:{value:e,message:Ee.toString(t)}})}nonempty(e){return this.min(1,e)}}function st(e){if(e instanceof at){const t={};for(const i in e.shape){const n=e.shape[i];t[i]=jt.create(st(n))}return new at({...e._def,shape:()=>t})}return e instanceof rt?new rt({...e._def,type:st(e.element)}):e instanceof jt?jt.create(st(e.unwrap())):e instanceof St?St.create(st(e.unwrap())):e instanceof pt?pt.create(e.items.map((e=>st(e)))):e}rt.create=(e,t)=>new rt({type:e,minLength:null,maxLength:null,exactLength:null,typeName:Zt.ZodArray,...Ze(t)});class at extends Ne{constructor(){super(...arguments),this._cached=null,this.nonstrict=this.passthrough,this.augment=this.extend}_getCached(){if(null!==this._cached)return this._cached;const e=this._def.shape(),t=pe.objectKeys(e);return this._cached={shape:e,keys:t}}_parse(e){if(this._getType(e)!==fe.object){const t=this._getOrReturnCtx(e);return xe(t,{code:ye.invalid_type,expected:fe.object,received:t.parsedType}),Se}const{status:t,ctx:i}=this._processInputParams(e),{shape:n,keys:r}=this._getCached(),s=[];if(!(this._def.catchall instanceof it&&"strip"===this._def.unknownKeys))for(const e in i.data)r.includes(e)||s.push(e);const a=[];for(const e of r){const t=n[e],r=i.data[e];a.push({key:{status:"valid",value:e},value:t._parse(new Le(i,r,i.path,e)),alwaysSet:e in i.data})}if(this._def.catchall instanceof it){const e=this._def.unknownKeys;if("passthrough"===e)for(const e of s)a.push({key:{status:"valid",value:e},value:{status:"valid",value:i.data[e]}});else if("strict"===e)s.length>0&&(xe(i,{code:ye.unrecognized_keys,keys:s}),t.dirty());else if("strip"!==e)throw new Error("Internal ZodObject error: invalid unknownKeys value.")}else{const e=this._def.catchall;for(const t of s){const n=i.data[t];a.push({key:{status:"valid",value:t},value:e._parse(new Le(i,n,i.path,t)),alwaysSet:t in i.data})}}return i.common.async?Promise.resolve().then((async()=>{const e=[];for(const t of a){const i=await t.key;e.push({key:i,value:await t.value,alwaysSet:t.alwaysSet})}return e})).then((e=>je.mergeObjectSync(t,e))):je.mergeObjectSync(t,a)}get shape(){return this._def.shape()}strict(e){return Ee.errToObj,new at({...this._def,unknownKeys:"strict",...void 0!==e?{errorMap:(t,i)=>{var n,r,s,a;const o=null!==(s=null===(r=(n=this._def).errorMap)||void 0===r?void 0:r.call(n,t,i).message)&&void 0!==s?s:i.defaultError;return"unrecognized_keys"===t.code?{message:null!==(a=Ee.errToObj(e).message)&&void 0!==a?a:o}:{message:o}}}:{}})}strip(){return new at({...this._def,unknownKeys:"strip"})}passthrough(){return new at({...this._def,unknownKeys:"passthrough"})}extend(e){return new at({...this._def,shape:()=>({...this._def.shape(),...e})})}merge(e){return new at({unknownKeys:e._def.unknownKeys,catchall:e._def.catchall,shape:()=>({...this._def.shape(),...e._def.shape()}),typeName:Zt.ZodObject})}setKey(e,t){return this.augment({[e]:t})}catchall(e){return new at({...this._def,catchall:e})}pick(e){const t={};return pe.objectKeys(e).forEach((i=>{e[i]&&this.shape[i]&&(t[i]=this.shape[i])})),new at({...this._def,shape:()=>t})}omit(e){const t={};return pe.objectKeys(this.shape).forEach((i=>{e[i]||(t[i]=this.shape[i])})),new at({...this._def,shape:()=>t})}deepPartial(){return st(this)}partial(e){const t={};return pe.objectKeys(this.shape).forEach((i=>{const n=this.shape[i];e&&!e[i]?t[i]=n:t[i]=n.optional()})),new at({...this._def,shape:()=>t})}required(e){const t={};return pe.objectKeys(this.shape).forEach((i=>{if(e&&!e[i])t[i]=this.shape[i];else{let e=this.shape[i];for(;e instanceof jt;)e=e._def.innerType;t[i]=e}})),new at({...this._def,shape:()=>t})}keyof(){return vt(pe.objectKeys(this.shape))}}at.create=(e,t)=>new at({shape:()=>e,unknownKeys:"strip",catchall:it.create(),typeName:Zt.ZodObject,...Ze(t)}),at.strictCreate=(e,t)=>new at({shape:()=>e,unknownKeys:"strict",catchall:it.create(),typeName:Zt.ZodObject,...Ze(t)}),at.lazycreate=(e,t)=>new at({shape:e,unknownKeys:"strip",catchall:it.create(),typeName:Zt.ZodObject,...Ze(t)});class ot extends Ne{_parse(e){const{ctx:t}=this._processInputParams(e),i=this._def.options;if(t.common.async)return Promise.all(i.map((async e=>{const i={...t,common:{...t.common,issues:[]},parent:null};return{result:await e._parseAsync({data:t.data,path:t.path,parent:i}),ctx:i}}))).then((function(e){for(const t of e)if("valid"===t.result.status)return t.result;for(const i of e)if("dirty"===i.result.status)return t.common.issues.push(...i.ctx.common.issues),i.result;const i=e.map((e=>new be(e.ctx.common.issues)));return xe(t,{code:ye.invalid_union,unionErrors:i}),Se}));{let e;const n=[];for(const r of i){const i={...t,common:{...t.common,issues:[]},parent:null},s=r._parseSync({data:t.data,path:t.path,parent:i});if("valid"===s.status)return s;"dirty"!==s.status||e||(e={result:s,ctx:i}),i.common.issues.length&&n.push(i.common.issues)}if(e)return t.common.issues.push(...e.ctx.common.issues),e.result;const r=n.map((e=>new be(e)));return xe(t,{code:ye.invalid_union,unionErrors:r}),Se}}get options(){return this._def.options}}ot.create=(e,t)=>new ot({options:e,typeName:Zt.ZodUnion,...Ze(t)});const ct=e=>e instanceof yt?ct(e.schema):e instanceof xt?ct(e.innerType()):e instanceof bt?[e.value]:e instanceof wt?e.options:e instanceof _t?Object.keys(e.enum):e instanceof At?ct(e._def.innerType):e instanceof Ye?[void 0]:e instanceof Xe?[null]:null;class lt extends Ne{_parse(e){const{ctx:t}=this._processInputParams(e);if(t.parsedType!==fe.object)return xe(t,{code:ye.invalid_type,expected:fe.object,received:t.parsedType}),Se;const i=this.discriminator,n=t.data[i],r=this.optionsMap.get(n);return r?t.common.async?r._parseAsync({data:t.data,path:t.path,parent:t}):r._parseSync({data:t.data,path:t.path,parent:t}):(xe(t,{code:ye.invalid_union_discriminator,options:Array.from(this.optionsMap.keys()),path:[i]}),Se)}get discriminator(){return this._def.discriminator}get options(){return this._def.options}get optionsMap(){return this._def.optionsMap}static create(e,t,i){const n=new Map;for(const i of t){const t=ct(i.shape[e]);if(!t)throw new Error(`A discriminator value for key \`${e}\` could not be extracted from all schema options`);for(const r of t){if(n.has(r))throw new Error(`Discriminator property ${String(e)} has duplicate value ${String(r)}`);n.set(r,i)}}return new lt({typeName:Zt.ZodDiscriminatedUnion,discriminator:e,options:t,optionsMap:n,...Ze(i)})}}function dt(e,t){const i=ge(e),n=ge(t);if(e===t)return{valid:!0,data:e};if(i===fe.object&&n===fe.object){const i=pe.objectKeys(t),n=pe.objectKeys(e).filter((e=>-1!==i.indexOf(e))),r={...e,...t};for(const i of n){const n=dt(e[i],t[i]);if(!n.valid)return{valid:!1};r[i]=n.data}return{valid:!0,data:r}}if(i===fe.array&&n===fe.array){if(e.length!==t.length)return{valid:!1};const i=[];for(let n=0;n<e.length;n++){const r=dt(e[n],t[n]);if(!r.valid)return{valid:!1};i.push(r.data)}return{valid:!0,data:i}}return i===fe.date&&n===fe.date&&+e==+t?{valid:!0,data:e}:{valid:!1}}class ut extends Ne{_parse(e){const{status:t,ctx:i}=this._processInputParams(e),n=(e,n)=>{if(Te(e)||Te(n))return Se;const r=dt(e.value,n.value);return r.valid?((Ce(e)||Ce(n))&&t.dirty(),{status:t.value,value:r.data}):(xe(i,{code:ye.invalid_intersection_types}),Se)};return i.common.async?Promise.all([this._def.left._parseAsync({data:i.data,path:i.path,parent:i}),this._def.right._parseAsync({data:i.data,path:i.path,parent:i})]).then((([e,t])=>n(e,t))):n(this._def.left._parseSync({data:i.data,path:i.path,parent:i}),this._def.right._parseSync({data:i.data,path:i.path,parent:i}))}}ut.create=(e,t,i)=>new ut({left:e,right:t,typeName:Zt.ZodIntersection,...Ze(i)});class pt extends Ne{_parse(e){const{status:t,ctx:i}=this._processInputParams(e);if(i.parsedType!==fe.array)return xe(i,{code:ye.invalid_type,expected:fe.array,received:i.parsedType}),Se;if(i.data.length<this._def.items.length)return xe(i,{code:ye.too_small,minimum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),Se;!this._def.rest&&i.data.length>this._def.items.length&&(xe(i,{code:ye.too_big,maximum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),t.dirty());const n=[...i.data].map(((e,t)=>{const n=this._def.items[t]||this._def.rest;return n?n._parse(new Le(i,e,i.path,t)):null})).filter((e=>!!e));return i.common.async?Promise.all(n).then((e=>je.mergeArray(t,e))):je.mergeArray(t,n)}get items(){return this._def.items}rest(e){return new pt({...this._def,rest:e})}}pt.create=(e,t)=>{if(!Array.isArray(e))throw new Error("You must pass an array of schemas to z.tuple([ ... ])");return new pt({items:e,typeName:Zt.ZodTuple,rest:null,...Ze(t)})};class mt extends Ne{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(e){const{status:t,ctx:i}=this._processInputParams(e);if(i.parsedType!==fe.object)return xe(i,{code:ye.invalid_type,expected:fe.object,received:i.parsedType}),Se;const n=[],r=this._def.keyType,s=this._def.valueType;for(const e in i.data)n.push({key:r._parse(new Le(i,e,i.path,e)),value:s._parse(new Le(i,i.data[e],i.path,e))});return i.common.async?je.mergeObjectAsync(t,n):je.mergeObjectSync(t,n)}get element(){return this._def.valueType}static create(e,t,i){return new mt(t instanceof Ne?{keyType:e,valueType:t,typeName:Zt.ZodRecord,...Ze(i)}:{keyType:ze.create(),valueType:e,typeName:Zt.ZodRecord,...Ze(t)})}}class ht extends Ne{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(e){const{status:t,ctx:i}=this._processInputParams(e);if(i.parsedType!==fe.map)return xe(i,{code:ye.invalid_type,expected:fe.map,received:i.parsedType}),Se;const n=this._def.keyType,r=this._def.valueType,s=[...i.data.entries()].map((([e,t],s)=>({key:n._parse(new Le(i,e,i.path,[s,"key"])),value:r._parse(new Le(i,t,i.path,[s,"value"]))})));if(i.common.async){const e=new Map;return Promise.resolve().then((async()=>{for(const i of s){const n=await i.key,r=await i.value;if("aborted"===n.status||"aborted"===r.status)return Se;"dirty"!==n.status&&"dirty"!==r.status||t.dirty(),e.set(n.value,r.value)}return{status:t.value,value:e}}))}{const e=new Map;for(const i of s){const n=i.key,r=i.value;if("aborted"===n.status||"aborted"===r.status)return Se;"dirty"!==n.status&&"dirty"!==r.status||t.dirty(),e.set(n.value,r.value)}return{status:t.value,value:e}}}}ht.create=(e,t,i)=>new ht({valueType:t,keyType:e,typeName:Zt.ZodMap,...Ze(i)});class ft extends Ne{_parse(e){const{status:t,ctx:i}=this._processInputParams(e);if(i.parsedType!==fe.set)return xe(i,{code:ye.invalid_type,expected:fe.set,received:i.parsedType}),Se;const n=this._def;null!==n.minSize&&i.data.size<n.minSize.value&&(xe(i,{code:ye.too_small,minimum:n.minSize.value,type:"set",inclusive:!0,exact:!1,message:n.minSize.message}),t.dirty()),null!==n.maxSize&&i.data.size>n.maxSize.value&&(xe(i,{code:ye.too_big,maximum:n.maxSize.value,type:"set",inclusive:!0,exact:!1,message:n.maxSize.message}),t.dirty());const r=this._def.valueType;function s(e){const i=new Set;for(const n of e){if("aborted"===n.status)return Se;"dirty"===n.status&&t.dirty(),i.add(n.value)}return{status:t.value,value:i}}const a=[...i.data.values()].map(((e,t)=>r._parse(new Le(i,e,i.path,t))));return i.common.async?Promise.all(a).then((e=>s(e))):s(a)}min(e,t){return new ft({...this._def,minSize:{value:e,message:Ee.toString(t)}})}max(e,t){return new ft({...this._def,maxSize:{value:e,message:Ee.toString(t)}})}size(e,t){return this.min(e,t).max(e,t)}nonempty(e){return this.min(1,e)}}ft.create=(e,t)=>new ft({valueType:e,minSize:null,maxSize:null,typeName:Zt.ZodSet,...Ze(t)});class gt extends Ne{constructor(){super(...arguments),this.validate=this.implement}_parse(e){const{ctx:t}=this._processInputParams(e);if(t.parsedType!==fe.function)return xe(t,{code:ye.invalid_type,expected:fe.function,received:t.parsedType}),Se;function i(e,i){return ke({data:e,path:t.path,errorMaps:[t.common.contextualErrorMap,t.schemaErrorMap,_e(),ve].filter((e=>!!e)),issueData:{code:ye.invalid_arguments,argumentsError:i}})}function n(e,i){return ke({data:e,path:t.path,errorMaps:[t.common.contextualErrorMap,t.schemaErrorMap,_e(),ve].filter((e=>!!e)),issueData:{code:ye.invalid_return_type,returnTypeError:i}})}const r={errorMap:t.common.contextualErrorMap},s=t.data;if(this._def.returns instanceof kt){const e=this;return Oe((async function(...t){const a=new be([]),o=await e._def.args.parseAsync(t,r).catch((e=>{throw a.addIssue(i(t,e)),a})),c=await Reflect.apply(s,this,o);return await e._def.returns._def.type.parseAsync(c,r).catch((e=>{throw a.addIssue(n(c,e)),a}))}))}{const e=this;return Oe((function(...t){const a=e._def.args.safeParse(t,r);if(!a.success)throw new be([i(t,a.error)]);const o=Reflect.apply(s,this,a.data),c=e._def.returns.safeParse(o,r);if(!c.success)throw new be([n(o,c.error)]);return c.data}))}}parameters(){return this._def.args}returnType(){return this._def.returns}args(...e){return new gt({...this._def,args:pt.create(e).rest(tt.create())})}returns(e){return new gt({...this._def,returns:e})}implement(e){return this.parse(e)}strictImplement(e){return this.parse(e)}static create(e,t,i){return new gt({args:e||pt.create([]).rest(tt.create()),returns:t||tt.create(),typeName:Zt.ZodFunction,...Ze(i)})}}class yt extends Ne{get schema(){return this._def.getter()}_parse(e){const{ctx:t}=this._processInputParams(e);return this._def.getter()._parse({data:t.data,path:t.path,parent:t})}}yt.create=(e,t)=>new yt({getter:e,typeName:Zt.ZodLazy,...Ze(t)});class bt extends Ne{_parse(e){if(e.data!==this._def.value){const t=this._getOrReturnCtx(e);return xe(t,{received:t.data,code:ye.invalid_literal,expected:this._def.value}),Se}return{status:"valid",value:e.data}}get value(){return this._def.value}}function vt(e,t){return new wt({values:e,typeName:Zt.ZodEnum,...Ze(t)})}bt.create=(e,t)=>new bt({value:e,typeName:Zt.ZodLiteral,...Ze(t)});class wt extends Ne{_parse(e){if("string"!=typeof e.data){const t=this._getOrReturnCtx(e),i=this._def.values;return xe(t,{expected:pe.joinValues(i),received:t.parsedType,code:ye.invalid_type}),Se}if(-1===this._def.values.indexOf(e.data)){const t=this._getOrReturnCtx(e),i=this._def.values;return xe(t,{received:t.data,code:ye.invalid_enum_value,options:i}),Se}return Oe(e.data)}get options(){return this._def.values}get enum(){const e={};for(const t of this._def.values)e[t]=t;return e}get Values(){const e={};for(const t of this._def.values)e[t]=t;return e}get Enum(){const e={};for(const t of this._def.values)e[t]=t;return e}extract(e){return wt.create(e)}exclude(e){return wt.create(this.options.filter((t=>!e.includes(t))))}}wt.create=vt;class _t extends Ne{_parse(e){const t=pe.getValidEnumValues(this._def.values),i=this._getOrReturnCtx(e);if(i.parsedType!==fe.string&&i.parsedType!==fe.number){const e=pe.objectValues(t);return xe(i,{expected:pe.joinValues(e),received:i.parsedType,code:ye.invalid_type}),Se}if(-1===t.indexOf(e.data)){const e=pe.objectValues(t);return xe(i,{received:i.data,code:ye.invalid_enum_value,options:e}),Se}return Oe(e.data)}get enum(){return this._def.values}}_t.create=(e,t)=>new _t({values:e,typeName:Zt.ZodNativeEnum,...Ze(t)});class kt extends Ne{unwrap(){return this._def.type}_parse(e){const{ctx:t}=this._processInputParams(e);if(t.parsedType!==fe.promise&&!1===t.common.async)return xe(t,{code:ye.invalid_type,expected:fe.promise,received:t.parsedType}),Se;const i=t.parsedType===fe.promise?t.data:Promise.resolve(t.data);return Oe(i.then((e=>this._def.type.parseAsync(e,{path:t.path,errorMap:t.common.contextualErrorMap}))))}}kt.create=(e,t)=>new kt({type:e,typeName:Zt.ZodPromise,...Ze(t)});class xt extends Ne{innerType(){return this._def.schema}sourceType(){return this._def.schema._def.typeName===Zt.ZodEffects?this._def.schema.sourceType():this._def.schema}_parse(e){const{status:t,ctx:i}=this._processInputParams(e),n=this._def.effect||null,r={addIssue:e=>{xe(i,e),e.fatal?t.abort():t.dirty()},get path(){return i.path}};if(r.addIssue=r.addIssue.bind(r),"preprocess"===n.type){const e=n.transform(i.data,r);return i.common.issues.length?{status:"dirty",value:i.data}:i.common.async?Promise.resolve(e).then((e=>this._def.schema._parseAsync({data:e,path:i.path,parent:i}))):this._def.schema._parseSync({data:e,path:i.path,parent:i})}if("refinement"===n.type){const e=e=>{const t=n.refinement(e,r);if(i.common.async)return Promise.resolve(t);if(t instanceof Promise)throw new Error("Async refinement encountered during synchronous parse operation. Use .parseAsync instead.");return e};if(!1===i.common.async){const n=this._def.schema._parseSync({data:i.data,path:i.path,parent:i});return"aborted"===n.status?Se:("dirty"===n.status&&t.dirty(),e(n.value),{status:t.value,value:n.value})}return this._def.schema._parseAsync({data:i.data,path:i.path,parent:i}).then((i=>"aborted"===i.status?Se:("dirty"===i.status&&t.dirty(),e(i.value).then((()=>({status:t.value,value:i.value}))))))}if("transform"===n.type){if(!1===i.common.async){const e=this._def.schema._parseSync({data:i.data,path:i.path,parent:i});if(!Fe(e))return e;const s=n.transform(e.value,r);if(s instanceof Promise)throw new Error("Asynchronous transform encountered during synchronous parse operation. Use .parseAsync instead.");return{status:t.value,value:s}}return this._def.schema._parseAsync({data:i.data,path:i.path,parent:i}).then((e=>Fe(e)?Promise.resolve(n.transform(e.value,r)).then((e=>({status:t.value,value:e}))):e))}pe.assertNever(n)}}xt.create=(e,t,i)=>new xt({schema:e,typeName:Zt.ZodEffects,effect:t,...Ze(i)}),xt.createWithPreprocess=(e,t,i)=>new xt({schema:t,effect:{type:"preprocess",transform:e},typeName:Zt.ZodEffects,...Ze(i)});class jt extends Ne{_parse(e){return this._getType(e)===fe.undefined?Oe(void 0):this._def.innerType._parse(e)}unwrap(){return this._def.innerType}}jt.create=(e,t)=>new jt({innerType:e,typeName:Zt.ZodOptional,...Ze(t)});class St extends Ne{_parse(e){return this._getType(e)===fe.null?Oe(null):this._def.innerType._parse(e)}unwrap(){return this._def.innerType}}St.create=(e,t)=>new St({innerType:e,typeName:Zt.ZodNullable,...Ze(t)});class At extends Ne{_parse(e){const{ctx:t}=this._processInputParams(e);let i=t.data;return t.parsedType===fe.undefined&&(i=this._def.defaultValue()),this._def.innerType._parse({data:i,path:t.path,parent:t})}removeDefault(){return this._def.innerType}}At.create=(e,t)=>new At({innerType:e,typeName:Zt.ZodDefault,defaultValue:"function"==typeof t.default?t.default:()=>t.default,...Ze(t)});class Ot extends Ne{_parse(e){const{ctx:t}=this._processInputParams(e),i={...t,common:{...t.common,issues:[]}},n=this._def.innerType._parse({data:i.data,path:i.path,parent:{...i}});return Re(n)?n.then((e=>({status:"valid",value:"valid"===e.status?e.value:this._def.catchValue({get error(){return new be(i.common.issues)},input:i.data})}))):{status:"valid",value:"valid"===n.status?n.value:this._def.catchValue({get error(){return new be(i.common.issues)},input:i.data})}}removeCatch(){return this._def.innerType}}Ot.create=(e,t)=>new Ot({innerType:e,typeName:Zt.ZodCatch,catchValue:"function"==typeof t.catch?t.catch:()=>t.catch,...Ze(t)});class Tt extends Ne{_parse(e){if(this._getType(e)!==fe.nan){const t=this._getOrReturnCtx(e);return xe(t,{code:ye.invalid_type,expected:fe.nan,received:t.parsedType}),Se}return{status:"valid",value:e.data}}}Tt.create=e=>new Tt({typeName:Zt.ZodNaN,...Ze(e)});const Ct=Symbol("zod_brand");class Ft extends Ne{_parse(e){const{ctx:t}=this._processInputParams(e),i=t.data;return this._def.type._parse({data:i,path:t.path,parent:t})}unwrap(){return this._def.type}}class Rt extends Ne{_parse(e){const{status:t,ctx:i}=this._processInputParams(e);if(i.common.async)return(async()=>{const e=await this._def.in._parseAsync({data:i.data,path:i.path,parent:i});return"aborted"===e.status?Se:"dirty"===e.status?(t.dirty(),Ae(e.value)):this._def.out._parseAsync({data:e.value,path:i.path,parent:i})})();{const e=this._def.in._parseSync({data:i.data,path:i.path,parent:i});return"aborted"===e.status?Se:"dirty"===e.status?(t.dirty(),{status:"dirty",value:e.value}):this._def.out._parseSync({data:e.value,path:i.path,parent:i})}}static create(e,t){return new Rt({in:e,out:t,typeName:Zt.ZodPipeline})}}class Et extends Ne{_parse(e){const t=this._def.innerType._parse(e);return Fe(t)&&(t.value=Object.freeze(t.value)),t}}Et.create=(e,t)=>new Et({innerType:e,typeName:Zt.ZodReadonly,...Ze(t)});const Lt=(e,t={},i)=>e?et.create().superRefine(((n,r)=>{var s,a;if(!e(n)){const e="function"==typeof t?t(n):"string"==typeof t?{message:t}:t,o=null===(a=null!==(s=e.fatal)&&void 0!==s?s:i)||void 0===a||a,c="string"==typeof e?{message:e}:e;r.addIssue({code:"custom",...c,fatal:o})}})):et.create(),Pt={object:at.lazycreate};var Zt;!function(e){e.ZodString="ZodString",e.ZodNumber="ZodNumber",e.ZodNaN="ZodNaN",e.ZodBigInt="ZodBigInt",e.ZodBoolean="ZodBoolean",e.ZodDate="ZodDate",e.ZodSymbol="ZodSymbol",e.ZodUndefined="ZodUndefined",e.ZodNull="ZodNull",e.ZodAny="ZodAny",e.ZodUnknown="ZodUnknown",e.ZodNever="ZodNever",e.ZodVoid="ZodVoid",e.ZodArray="ZodArray",e.ZodObject="ZodObject",e.ZodUnion="ZodUnion",e.ZodDiscriminatedUnion="ZodDiscriminatedUnion",e.ZodIntersection="ZodIntersection",e.ZodTuple="ZodTuple",e.ZodRecord="ZodRecord",e.ZodMap="ZodMap",e.ZodSet="ZodSet",e.ZodFunction="ZodFunction",e.ZodLazy="ZodLazy",e.ZodLiteral="ZodLiteral",e.ZodEnum="ZodEnum",e.ZodEffects="ZodEffects",e.ZodNativeEnum="ZodNativeEnum",e.ZodOptional="ZodOptional",e.ZodNullable="ZodNullable",e.ZodDefault="ZodDefault",e.ZodCatch="ZodCatch",e.ZodPromise="ZodPromise",e.ZodBranded="ZodBranded",e.ZodPipeline="ZodPipeline",e.ZodReadonly="ZodReadonly"}(Zt||(Zt={}));const Nt=ze.create,It=Je.create,Dt=Tt.create,Mt=Ge.create,Ut=Ke.create,Wt=He.create,$t=Qe.create,qt=Ye.create,Bt=Xe.create,zt=et.create,Vt=tt.create,Jt=it.create,Gt=nt.create,Kt=rt.create,Ht=at.create,Qt=at.strictCreate,Yt=ot.create,Xt=lt.create,ei=ut.create,ti=pt.create,ii=mt.create,ni=ht.create,ri=ft.create,si=gt.create,ai=yt.create,oi=bt.create,ci=wt.create,li=_t.create,di=kt.create,ui=xt.create,pi=jt.create,mi=St.create,hi=xt.createWithPreprocess,fi=Rt.create,gi={string:e=>ze.create({...e,coerce:!0}),number:e=>Je.create({...e,coerce:!0}),boolean:e=>Ke.create({...e,coerce:!0}),bigint:e=>Ge.create({...e,coerce:!0}),date:e=>He.create({...e,coerce:!0})},yi=Se;var bi=Object.freeze({__proto__:null,defaultErrorMap:ve,setErrorMap:function(e){we=e},getErrorMap:_e,makeIssue:ke,EMPTY_PATH:[],addIssueToContext:xe,ParseStatus:je,INVALID:Se,DIRTY:Ae,OK:Oe,isAborted:Te,isDirty:Ce,isValid:Fe,isAsync:Re,get util(){return pe},get objectUtil(){return me},ZodParsedType:fe,getParsedType:ge,ZodType:Ne,ZodString:ze,ZodNumber:Je,ZodBigInt:Ge,ZodBoolean:Ke,ZodDate:He,ZodSymbol:Qe,ZodUndefined:Ye,ZodNull:Xe,ZodAny:et,ZodUnknown:tt,ZodNever:it,ZodVoid:nt,ZodArray:rt,ZodObject:at,ZodUnion:ot,ZodDiscriminatedUnion:lt,ZodIntersection:ut,ZodTuple:pt,ZodRecord:mt,ZodMap:ht,ZodSet:ft,ZodFunction:gt,ZodLazy:yt,ZodLiteral:bt,ZodEnum:wt,ZodNativeEnum:_t,ZodPromise:kt,ZodEffects:xt,ZodTransformer:xt,ZodOptional:jt,ZodNullable:St,ZodDefault:At,ZodCatch:Ot,ZodNaN:Tt,BRAND:Ct,ZodBranded:Ft,ZodPipeline:Rt,ZodReadonly:Et,custom:Lt,Schema:Ne,ZodSchema:Ne,late:Pt,get ZodFirstPartyTypeKind(){return Zt},coerce:gi,any:zt,array:Kt,bigint:Mt,boolean:Ut,date:Wt,discriminatedUnion:Xt,effect:ui,enum:ci,function:si,instanceof:(e,t={message:`Input not instance of ${e.name}`})=>Lt((t=>t instanceof e),t),intersection:ei,lazy:ai,literal:oi,map:ni,nan:Dt,nativeEnum:li,never:Jt,null:Bt,nullable:mi,number:It,object:Ht,oboolean:()=>Ut().optional(),onumber:()=>It().optional(),optional:pi,ostring:()=>Nt().optional(),pipeline:fi,preprocess:hi,promise:di,record:ii,set:ri,strictObject:Qt,string:Nt,symbol:$t,transformer:ui,tuple:ti,undefined:qt,union:Yt,unknown:Vt,void:Gt,NEVER:yi,ZodIssueCode:ye,quotelessJson:e=>JSON.stringify(e,null,2).replace(/"([^"]+)":/g,"$1:"),ZodError:be});const vi=bi.string(),wi=bi.string().nullable(),_i=bi.number(),ki=bi.string().nullable(),xi=bi.string().nullable(),ji=bi.string().nullable(),Si=bi.number(),Ai=bi.string(),Oi=bi.string(),Ti=bi.union([Si,ji,xi,ki,Ai,_i,wi,vi,Oi]),Ci={ADMIN:9,USER:5,EXTERNAL:3,GUEST:0},Fi=bi.lazy((()=>Gi.extend({title:bi.string(),_url:bi.string(),level:bi.nativeEnum(Ci),dateCreation:bi.string(),dateModified:bi.string()}).catchall(Ti))),Ri=bi.lazy((()=>Fi.schema.extend({active:bi.number()}))),Ei=e=>Ri.safeParse(e).success,Li=Ri,Pi=e=>Li.safeParse(e).success,Zi=bi.object({idInType:bi.number(),lat:bi.number(),lng:bi.number()}),Ni=e=>Zi.safeParse(e).success,Ii=bi.object({title:bi.string(),firstname:bi.string(),lastname:bi.string(),mail:bi.union([bi.string(),bi.undefined()]).optional(),description:bi.string().optional(),dateOfBirth:bi.string().optional(),phoneNumber:bi.string().optional(),language:bi.string().optional(),timeZone:bi.string().optional(),mobileNumber:bi.string().optional(),company:bi.string().optional(),country:bi.string().optional(),department:bi.string().optional(),function:bi.string().optional(),webSite:bi.string().optional(),image:bi.union([bi.string(),bi.undefined()]).optional(),userBanner:bi.union([bi.string(),bi.undefined()]).optional(),field1:bi.string().optional(),field2:bi.string().optional(),field3:bi.string().optional(),field4:bi.string().optional(),field5:bi.string().optional()}),Di=Ii.required().extend({level:bi.string(),image:bi.string().optional(),businessManagementManager:Fi.array().optional(),businessNetworkingUserToCompanySrc:Fi.array().optional()}),Mi=bi.object({user_field_edit_profil:bi.record(Ii.keyof(),bi.number()),user_field_editable:bi.record(Ii.keyof(),bi.number()),user_field_my_page:bi.record(Ii.keyof(),bi.number()),user_page_mandatory_fields:bi.object({firstname:bi.enum(["0","1"]),lastname:bi.enum(["0","1"]),pseudo:bi.enum(["0","1"])})}),Ui=bi.object({name:bi.string(),value:bi.union([bi.string(),bi.record(bi.string(),bi.any())])}),Wi=bi.enum(["popover"]),$i=bi.object({values:Di,mobileEditableFields:Di.keyof().array()}),qi=bi.object({mail:bi.union([bi.string(),bi.undefined()]),title:bi.string(),firstname:bi.string(),lastname:bi.string(),phoneNumber:bi.union([bi.string(),bi.undefined()]).optional(),company:bi.union([bi.string(),bi.undefined()]).optional(),function:bi.union([bi.string(),bi.undefined()]).optional(),uri:bi.union([bi.string(),bi.undefined()]).optional(),field1:bi.union([bi.string(),bi.undefined()]).optional(),field2:bi.union([bi.string(),bi.undefined()]).optional(),field3:bi.union([bi.string(),bi.undefined()]).optional(),field4:bi.union([bi.string(),bi.undefined()]).optional(),field5:bi.union([bi.string(),bi.undefined()]).optional()}),Bi=bi.object({userDirectoryShow:bi.union([bi.literal(""),bi.literal("1")]),contactDirectoryShow:bi.union([bi.literal("0"),bi.literal("1")]),businessContactShow:bi.boolean(),menu:bi.union([bi.literal("0"),bi.literal("1")]),cardFields:bi.string().array(),tableFields:bi.string().array(),viewFields:bi.string().array(),userGeoloc:bi.boolean().optional(),sort:bi.string(),cnt:bi.number().optional(),filters:bi.object({name:bi.string(),type:bi.string()}).array()}),zi=e=>Bi.safeParse(e).success,Vi=bi.object({create:bi.boolean(),read:bi.boolean(),publish:bi.boolean(),administrate:bi.boolean(),update:bi.boolean(),delete:bi.boolean(),comment:bi.boolean(),member:bi.boolean()}),Ji=e=>Vi.safeParse(e).success,Gi=bi.object({id:bi.number(),mainType:bi.string(),type:bi.string(),uri:bi.string(),dateCreation:bi.string().optional(),dateModified:bi.string().optional().nullable()}),Ki=Gi.extend({title:bi.string(),_url:bi.string()}),Hi=e=>Ki.safeParse(e).success,Qi=bi.lazy((()=>Ki.extend({description:bi.string().optional().nullable(),_user:Fi,_right:Vi}))),Yi=e=>Qi.safeParse(e).success;var Xi;!function(e){e[e.SPOT_MODERATE_IGNORE=0]="SPOT_MODERATE_IGNORE",e[e.SPOT_MODERATE_ACCEPT=1]="SPOT_MODERATE_ACCEPT",e[e.SPOT_MODERATE_PENDING=2]="SPOT_MODERATE_PENDING"}(Xi||(Xi={}));const en=bi.object({RF_Constant_levelName:bi.string(),RF_delete:bi.boolean(),RF_editing:bi.boolean(),RF_level:bi.number(),RF_levelName:bi.string(),RF_levelName_Trad:bi.string(),RF_parameters:bi.boolean(),RF_setAdmin:bi.boolean(),RF_spotit:bi.boolean(),RF_spotit_own:bi.boolean()}),tn=Ki.extend({dateCreation:bi.string(),dateModified:bi.string(),category:bi.number(),privacy:bi.number()}),nn=e=>en.safeParse(e).success;class rn extends n{list(e,t,i,n=[{name:"dateCreation",sort:"DESC"}]){return this.jApi.article.list({type:"aseiClearanceTicket",format:"raw-view",limit:t,page:e,orders:n,filters:i})}requestStatus(e,t,i){return this.network.post({o:"asei",f:"setStatus",uri:e,requestedStatus:t,audience:i})}getDedicatedGroups(){return this.network.post({o:"asei",f:"getDedicatedGroups"})}getConfiguration(){return this.network.post({o:"asei",f:"configuration"})}}class sn extends n{tenants(){return this.network.post({o:"drive",f:"getTenants"})}groups(e,t){return this.network.post({o:"drive",f:"getGroups",query:e,filter:t})}sites(){return this.network.post({o:"drive",f:"getSites"})}listAccount(e){return this.network.post({o:"drive",f:"listAccount",service:e})}isAccountLogged(e,t){return this.network.post({o:"drive",f:"isAccountLogged",service:e,id:t})}checkAccountToken(e){return this.network.post({o:"drive",f:"checkAccountToken",service:e})}documents(e,t){return this.network.post({o:"drive",f:"getDocuments",service:e,documentParams:t})}}class an extends n{GetUnclassifiedFiles(e){var t;return this.network.post({o:"objectListMediaLibrary",f:"GetUnclassifiedFiles",format:e.format,page:null!==(t=e.page)&&void 0!==t?t:1,limit:e.limit,nolimit:e.nolimit})}getAccess(){return this.network.post({o:"mediaLibrary",f:"access"})}getFoldersStatsList(e=[],t=[],i=1){return this.network.post({o:"objectListMediaLibrary",f:"FoldersStatsList",filters:e,orders:t,page:i})}getFilesStatsList(e=[],t=[],i=1){return this.network.post({o:"objectListMediaLibrary",f:"FilesStatsList",filters:e,orders:t,page:i})}getStats(){return this.network.post({o:"mediaLibrary",f:"moderatorStats"})}readFolder(e){return this.network.post({o:"mediaLibrary",f:"readFolder",uri:e})}readFile(e){return this.network.post({o:"mediaLibrary",f:"readFile",uri:e})}}class on extends n{getLogs({dateEnd:e,idLogMax:t}){return this.network.post({o:"jLand",f:"adminLogs",dateEnd:e,idLogMax:t})}getStats({map:e,dateStart:t,dateEnd:i}){return this.network.post({o:"jLand",f:"adminStats",map:e,dateStart:t,dateEnd:i})}getAllMapsAsAdmin(e="raw-list,licenses"){return this.network.post({o:"objectListJLand",f:"jLandList",format:e})}createMap(e,t="raw-list"){return this.network.maybePostToken(Object.assign(Object.assign({},e),{o:"article",f:"create",format:t,type:"jlandmap"}))}}class cn extends n{sendMessage(e,t){return this.network.post({o:"messenger",f:"newMessage",idDiscussion:t,msg:{description:e}})}getOrCreateDiscussion(e,t){const i=e<t?`${e}.${t}`:`${t}.${e}`;return this.network.post({o:"messenger",f:"getDiscussion",idDiscussion:i,type:"messengerUser",idUserTo:t})}}class ln extends n{getConfig(){return this.network.post({o:"search",f:"getConfig"})}proposition({query:e,format:t},i){return this.network.post({o:"search",f:"proposition",query:e,format:t||"little"},i)}searchQuery(e,t){const{keywords:i,category:n,facetCategories:r,filters:s,page:a,limit:o,sort:c,options:l,format:d}=e;return this.network.post({o:"search",f:"query",keywords:i,category:n,facetCategories:r,filters:s,page:a,limit:o,sort:c,options:l,format:B(d,null==t?void 0:t.formatExtension)},null==t?void 0:t.signal)}getLastQueries(){return this.network.post({o:"search",f:"getLastQueries"})}getAdminConfig(){return this.network.post({o:"search",f:"getAdminConfig"})}setAdminConfig(e){return this.network.post({o:"search",f:"setAdminConfig",config:e})}}var dn=function(e,t){var i={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(i[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var r=0;for(n=Object.getOwnPropertySymbols(e);r<n.length;r++)t.indexOf(n[r])<0&&Object.prototype.propertyIsEnumerable.call(e,n[r])&&(i[n[r]]=e[n[r]])}return i};class un extends n{list(){return this.network.post({o:"taxonomy",f:"list",format:"raw-little"}).then((e=>{if(Array.isArray(e.result))return e.result;throw"Bad response from backend"}))}create(e){var{format:t="raw-little"}=e,i=dn(e,["format"]);return this.network.post(Object.assign({o:"taxonomy",f:"create",format:t},i))}autocomplete(e,t){return this.network.post({o:"autocomplete",f:"taxonomy",q:t,idTaxonomy:e,idToUri:!1})}autocompleteList(e){var{format:t="autocomplete"}=e,i=dn(e,["format"]);return this.network.post(Object.assign({o:"objectListTaxonomy",f:"concept",format:t},i))}autocompleteHierarchy(e){return this.network.post(Object.assign({o:"objectListTaxonomyHierarchy",f:"concept"},e))}}class pn extends n{autocomplete(e){return this.network.post({o:"autocomplete",f:"user",q:e,idToUri:!1}).then((e=>e.result))}get(e,t="little",i){return this.network.post({o:"user",f:"get",uri:e,format:t},i)}updateImage(e,t="raw-little"){return this.network.postCSRF({o:"user",f:"updateImage",idFile:e,format:t})}updateBanner(e,t="raw-little"){return this.network.postCSRF({o:"user",f:"updateBanner",idFile:e,format:t})}updateMail(e,t){return this.network.postCSRF({o:"user",f:"editMail",mail:e,password:t})}userUpdateProfile(e){return this.network.postCSRF(Object.assign({o:"user",f:"updateProfile"},e))}configuration(){return this.network.post({o:"userDirectory",f:"configuration"})}fieldsConfiguration(){return this.network.post({o:"user",f:"fieldsConfiguration"})}userList(e,t){return this.network.post(Object.assign(Object.assign({o:"objectList",f:"JamespotUserList"},e),{format:B(e.format,null==t?void 0:t.formatExtension)}),null==t?void 0:t.signal)}userQueryList(e,t){return this.network.post(Object.assign(Object.assign({o:"objectList",f:"JamespotUserQueryList"},e),{format:B(e.format,null==t?void 0:t.formatExtension)}))}userMap(e){return this.network.post(Object.assign({o:"objectListJamespot",f:"userMap"},e))}userBusinessContactQueryList(e){return this.network.post(Object.assign({o:"businessContact",f:"queryList"},e))}userCreateBusinessContact(e){const t=Object.assign(Object.assign({},e),{pseudo:e.title,firstName:e.firstname,lastName:e.lastname,champ1:e.field1,champ2:e.field2,champ3:e.field3,champ4:e.field4,champ5:e.field5}),i=Object.assign(Object.assign({},t),{type:"businessContactCard",publishTo:"networkPublic/1"});return this.jApi.article.create(i)}userUpdateBusinessContact(e){const t=Object.assign(Object.assign({},e),{pseudo:e.title,firstName:e.firstname,lastName:e.lastname,champ1:e.field1,champ2:e.field2,champ3:e.field3,champ4:e.field4,champ5:e.field5}),i=Object.assign(Object.assign({},t),{uri:e.uri,publishTo:"networkPublic/1"});return this.jApi.article.update(i)}userDeleteBusinessContact(e){return this.jApi.article.delete(e)}userAddContact(e){return this.network.post({o:"user",f:"addContact",idUser:e})}userRemoveContact(e){return this.network.post({o:"user",f:"removeContact",idUser:e})}signIn(e,t){return this.network.post({o:"user",f:"signIn",mail:e,password:t})}getFields(e,t){return this.network.post({o:"user",f:"getFields",idUser:e,fieldsType:t})}}class mn extends n{getFiles(e){return this.network.post(Object.assign({o:"onlyOffice",f:"getFiles"},e))}getFile(e,t){return this.network.post({o:"onlyOffice",f:"getFile",idFile:e,hash:t})}getTemplates(e){return this.network.post({o:"onlyOffice",f:"getTemplates"},e)}deleteFile(e,t){return this.network.postCSRF({o:"onlyOffice",f:"deleteFile",idFile:e,withParent:t})}createFile(e,t,i){return this.network.postCSRF({o:"onlyOffice",f:"createFile",title:e,type:t,publishTo:i})}updateFile(e,t){return this.network.postCSRF({o:"onlyOffice",f:"updateFile",idFile:e,title:t})}createVersion(e){return this.network.post({o:"onlyOffice",f:"createVersion",idFile:e})}setAccessRequest(e,t,i,n){return this.network.postCSRF({o:"onlyOffice",f:"setAccessRequest",uri:e,idUser:t,requestAccessValue:i,requestResponseMessage:n})}getAccessRequest(e,t){return this.network.post({o:"onlyOffice",f:"getAccessRequest",format:"raw-little",uri:e,idUser:t})}askAccess(e,t,i){return this.network.postCSRF({o:"onlyOffice",f:"askAccess",uri:e,askAccess:t,askMessage:i})}}class hn extends n{createChannel(e,t="raw-list"){return this.network.maybePostToken(Object.assign(Object.assign({},e),{o:"article",f:"create",format:t,type:"tvDisplayChannel"}))}getChannel(e){return this.network.post(Object.assign(Object.assign({},e),{o:"tvDisplay",f:"getChannel"}))}getConfigureChannel(e){return this.network.post(Object.assign(Object.assign({},e),{o:"tvDisplay",f:"getConfigureChannel"}))}}class fn extends n{contentObjectLinks(e){return this.network.post({o:"shared",f:"contentObjectLinks",format:"raw-little",uri:e})}contentSetObjectAccessRule(e,t,i){return this.network.postCSRF({o:"shared",f:"contentSetObjectAccessRule",format:"raw-little",uri:e,rule:t,hash:i})}}var gn=function(e,t,i,n){return new(i||(i=Promise))((function(r,s){function a(e){try{c(n.next(e))}catch(e){s(e)}}function o(e){try{c(n.throw(e))}catch(e){s(e)}}function c(e){var t;e.done?r(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(a,o)}c((n=n.apply(e,t||[])).next())}))};class yn extends n{SaveAnimationConfiguration(e){return gn(this,void 0,void 0,(function*(){return this.network.post({o:"animations",f:"saveConfiguration",animation:e})}))}DeleteAnimation(){return gn(this,void 0,void 0,(function*(){return this.network.post({o:"animations",f:"deleteAnimation"})}))}GetCurrentAnimation(){return gn(this,void 0,void 0,(function*(){return this.network.post({o:"animations",f:"getConfiguration"})}))}GetCurrentAnimationApp(){return gn(this,void 0,void 0,(function*(){return this.network.post({o:"animations",f:"getConfigurationApp"})}))}ToggleAnimationActive(){return gn(this,void 0,void 0,(function*(){return this.network.post({o:"animations",f:"toggleAnimationActive"})}))}GetAnimationActive(){return gn(this,void 0,void 0,(function*(){return this.network.post({o:"animations",f:"getAnimationActive"})}))}}class bn extends n{GetStatus(){return e=this,t=void 0,n=function*(){return this.network.post({o:"accessibility",f:"getStatus"})},new((i=void 0)||(i=Promise))((function(r,s){function a(e){try{c(n.next(e))}catch(e){s(e)}}function o(e){try{c(n.throw(e))}catch(e){s(e)}}function c(e){var t;e.done?r(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(a,o)}c((n=n.apply(e,t||[])).next())}));var e,t,i,n}}class vn extends n{getObject(e){return this.network.post({o:"object",f:"getObject",uri:e})}setAccess(e,t,i,n){return this.network.post({o:"object",f:"setAccess",uri:e,access:t,message:i,generalAccessRule:n})}getAccess(e){return this.network.post({o:"object",f:"getAccess",uri:e})}getAccessHash(e){return this.network.post({o:"object",f:"getAccessHash",uri:e})}}class wn extends n{getFileBanks(e){return this.network.post({o:"file-sync",f:"getFileBanks"},e)}saveFileBanks(e){return this.network.post({o:"file-sync",f:"saveFileBanks",fileBanks:e})}getUserQuota(e){return this.network.post({o:"file-sync",f:"getUserQuota"},e)}getAdminSpots(e,t){return this.network.post(Object.assign({o:"objectList",f:"fileSyncAdminSpots"},e),t)}}class _n extends n{getUsers(e,t){return this.network.post(Object.assign(Object.assign({o:"customAction",f:"getUsers"},e),{format:null!=t?t:"raw-list"}))}add(e,t){return this.network.post(Object.assign(Object.assign({o:"customAction",f:"add"},e),{format:null!=t?t:"raw-little"}))}remove(e,t){return this.network.post(Object.assign(Object.assign({o:"customAction",f:"remove"},e),{format:null!=t?t:"raw-little"}))}}class kn extends n{textEnhancement({text:e,capacity:t}){return this.network.post({o:"jia",f:"textEnhancement",text:e,capacity:t})}}class xn extends n{responseUserList(e,t,i){return this.network.post({o:"widget",f:"responseUserList",uri:e,uniqid:t,page:i})}removeWidget({id:e,type:t,uniqid:i}){return this.network.post({o:"widget",f:"removeWidget",id:e,type:t,uniqid:i})}checkListRespond({id:e,type:t,idUser:i,uniqid:n,index:r}){return this.network.post({o:"widget",f:"checkListRespond",id:e,type:t,uniqid:n,idUser:i,index:r})}updateWidget({id:e,uniqid:t,content:i,title:n,type:r}){return this.network.post({o:"widget",f:"updateWidget",id:e,uniqid:t,content:i,title:n,type:r})}}class jn{constructor(e){this.version="1.0",this.network=e,this.admin={license:new r(this),store:new s(this),utils:new a(this)},this.accessibility=new bn(this),this.application=new o(this),this.article=new Q(this),this.asei=new rn(this),this.assetReservation=new X(this),this.audience=new ee(this),this.bbb=new te(this),this.bookmark=new ie(this),this.businessNetworking=new ne(this),this.community=new re(this),this.datasource=new se(this),this.diapazone=new ae(this),this.drive=new sn(this),this.faq=new le(this),this.file=new ce(this),this.filebank=new de(this),this.fileSync=new wn(this),this.global=new ue(this),this.group=new he(this),this.jia=new kn(this),this.jland=new on(this),this.mediaLibrary=new an(this),this.messenger=new cn(this),this.object=new vn(this),this.search=new ln(this),this.share=new fn(this),this.socialAction=new _n(this),this.taxonomy=new un(this),this.tvDisplay=new hn(this),this.user=new pn(this),this.wedoc=new mn(this),this.widget=new xn(this),this.animations=new yn(this)}}class Sn{getBackendUrl(){return e=this,t=void 0,n=function*(){const e=window.location;return`${e.protocol}//${e.host}`},new((i=void 0)||(i=Promise))((function(r,s){function a(e){try{c(n.next(e))}catch(e){s(e)}}function o(e){try{c(n.throw(e))}catch(e){s(e)}}function c(e){var t;e.done?r(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(a,o)}c((n=n.apply(e,t||[])).next())}));var e,t,i,n}fetch(e,t){return window.fetch(e,t)}}const An=bi.object({href:bi.string(),target:bi.string()}),On=bi.object({name:bi.string(),sort:bi.union([bi.literal("ASC"),bi.literal("DESC")])}),Tn=bi.union([Fi,tn]),Cn=bi.array(On),Fn=bi.union([bi.boolean(),bi.string(),bi.number(),bi.array(bi.string()),bi.object({srcId:bi.union([bi.number(),bi.string()]),srcType:bi.string()}),bi.object({targetId:bi.union([bi.number(),bi.string()]),targetType:bi.string()}),bi.object({start:bi.string(),end:bi.string()})]),Rn=bi.union([bi.literal("<"),bi.literal(">"),bi.literal("<="),bi.literal(">="),bi.literal("!="),bi.literal("<>"),bi.literal("like"),bi.literal("between"),bi.literal("is"),bi.literal("is not"),bi.literal("in"),bi.literal("link"),bi.literal("match"),bi.literal("equal")]),En=bi.union([bi.literal("<"),bi.literal(">"),bi.literal("<="),bi.literal(">="),bi.literal("!="),bi.literal("<>"),bi.literal("+"),bi.literal("-"),bi.literal("like"),bi.literal("between"),bi.literal("is"),bi.literal("is not"),bi.literal("in"),bi.literal("link"),bi.literal("match"),bi.literal("equal")]),Ln=bi.object({name:bi.string(),value:Fn,operator:Rn.optional(),method:En.optional(),or:bi.boolean().optional(),isNull:bi.boolean().optional(),isNotNull:bi.boolean().optional()}),Pn=bi.array(Ln);var Zn;!function(e){e.LITTLE="raw-little",e.LIST="raw-list",e.VIEW="raw-view",e.USER_API="user-api",e.MOBILE="mobile"}(Zn||(Zn={}));const Nn=bi.nativeEnum(Zn).transform((e=>`${e}`)),In=bi.union([Nn,bi.undefined()]),Dn=bi.array(bi.union([bi.literal("bookmark"),bi.literal("contact"),bi.literal("licenses"),bi.literal("quizFieldDefinitions"),bi.literal("quizResponseRecord"),bi.literal("search"),bi.literal("socialEventRecord"),bi.literal("surveyDateRecord")])),Mn=bi.object({attrName:bi.string(),token:bi.string(),file:bi.instanceof(File).nullable().optional(),url:bi.string().optional()}),Un=bi.object({width:bi.number(),height:bi.number()}),Wn=bi.object({x:bi.number(),y:bi.number(),w:bi.number(),h:bi.number(),rotation:bi.number(),killSize:bi.boolean().optional()}),$n=Ki.extend({dateCreation:bi.string(),dateModified:bi.string().nullable(),mimetype:bi.string(),path:bi.string().optional(),size:bi.number()}),qn=e=>$n.parse(e),Bn=$n.extend({_extend:bi.object({crop:Wn})}),zn=bi.object({name:bi.string(),filename:bi.string(),dateModified:bi.string(),mimetype:bi.string()}),Vn=bi.object({idUser:bi.string(),dateDownload:bi.string(),Pseudo:bi.string(),type:bi.string()}),Jn=bi.object({id:bi.string(),uri:bi.string(),shortUri:bi.string(),title:bi.string(),name:bi.string(),mainType:bi.string(),type:bi.string(),label:bi.string(),cssClass:bi.string(),cssColor:bi.string(),class:bi.string()}),Gn=Jn.extend({title:bi.string()}),Kn=Gn.extend({Pseudo:bi.string()}),Hn=Gn.extend({idspot:bi.string()}),Qn=bi.union([Gn,Kn,Hn]),Yn=bi.enum(["left","right","center","justify"]),Xn=bi.enum(["top","bottom","center","left","right"]),er=bi.enum(["auto","contain","cover"]),tr=bi.enum(["sm","md","lg"]),ir=bi.enum(["contained","outlined"]),nr=bi.enum(["link","anchor","popup"]),rr=bi.object({x:bi.number(),y:bi.number()});var sr;!function(e){e.ArticleButton="widget-article-button",e.ArticleGallery="widget-article-gallery",e.ArticleTitle="widget-article-title",e.ArticleText="widget-article-text",e.ArticleImage="widget-article-image",e.ArticleAttachment="widget-article-attachment",e.Api="widget-api",e.ArticleSlider="widget-article-slider",e.CheckList="widget-check-list",e.DatasourceTable="widget-datasource-table"}(sr||(sr={}));const ar=bi.nativeEnum(sr),or=bi.lazy((()=>bi.union([Xr,ts,ns,ss,os,ls,Qr,us,ms,Fr]))),cr=bi.lazy((()=>bi.object({[sr.ArticleButton]:Xr,[sr.ArticleGallery]:ts,[sr.ArticleTitle]:ns,[sr.ArticleText]:ss,[sr.ArticleImage]:os,[sr.ArticleAttachment]:ls,[sr.Api]:Qr,[sr.ArticleSlider]:us,[sr.CheckList]:ms,[sr.DatasourceTable]:Fr}))),lr=bi.lazy((()=>bi.object({[sr.ArticleButton]:Ur,[sr.ArticleGallery]:Er,[sr.ArticleTitle]:Lr,[sr.ArticleText]:Pr,[sr.ArticleImage]:Wr,[sr.ArticleAttachment]:$r,[sr.Api]:Zr,[sr.ArticleSlider]:Br,[sr.CheckList]:Vr,[sr.DatasourceTable]:Cr}))),dr=bi.object({layers:bi.string().array().optional()}),ur=e=>bi.object({title:bi.string(),widget:dr.and(null!=e?e:or)}),pr=bi.object({css:bi.record(bi.string(),bi.string()).optional(),widgets:ur().array().optional()}),mr=bi.enum(["default","vertical"]),hr=bi.lazy((()=>xs.schema.extend({articleWidgets:ur().array(),articleWidgetDisplayMode:mr.nullable().or(bi.undefined())}))),fr=bi.object({uniqid:bi.string(),title:bi.string(),locked:bi.boolean(),visible:bi.boolean(),widgets:ur().array(),position:rr.optional()}),gr=bi.enum(["edit","view","preview"]),yr=bi.object({type:bi.literal("text")}),br=bi.object({label:bi.string(),value:bi.string()}),vr=bi.object({type:bi.literal("select"),options:br.array()}),wr=bi.object({type:bi.literal("date")}),_r=bi.union([yr,vr,wr]),kr=bi.enum(["text","uri","file","select","url","transient","date","email","number","title"]),xr=bi.enum(["date","date-time","date-time-sec","time","time-sec"]),jr=bi.enum(["fr-FR","en-EN","filesize"]),Sr=bi.object({name:bi.string().optional(),isVisible:bi.boolean().optional(),textEllipsis:bi.boolean().optional(),label:bi.string().optional(),dateFormat:xr.optional(),numberFormat:jr.optional()}),Ar=Sr.array(),Or=bi.object({name:bi.string(),label:bi.string(),sortable:bi.boolean().optional(),type:kr,widget:_r}),Tr=bi.object({limit:bi.number().optional(),tableColumnsData:Sr.array().optional(),tableHeadColor:bi.string().optional(),tableHeadTextColor:bi.string().optional(),tableHeadIconColor:bi.string().optional(),tableRowColor:bi.string().optional(),tableRowTextColor:bi.string().optional(),tableBorderRadius:bi.number().optional(),tableSizedColumns:bi.boolean().optional(),tableSizedColumnsWidth:bi.number().optional()}),Cr=Tr.extend({uri:bi.string().optional()}),Fr=bi.lazy((()=>bi.object({name:bi.literal(sr.DatasourceTable),uniqid:bi.string(),content:Cr}))),Rr=e=>Hr(e,Fr),Er=bi.object({gap:bi.string().optional(),column:bi.string().optional(),files:$n.array().optional()}),Lr=bi.object({text:bi.string().optional(),textAlign:Yn.optional(),heading:bi.string().optional(),color:bi.string().optional(),backgroundColor:bi.string().optional()}),Pr=bi.object({text:bi.string().optional(),color:bi.string().optional(),fontSize:bi.string().optional(),lineHeight:bi.string().optional(),linkColor:bi.string().optional()}),Zr=bi.object({url:bi.string().optional(),keys:bi.array(bi.string()).optional(),order:bi.string().optional(),orderBy:bi.string().optional()}),Nr=bi.object({text:bi.string().optional(),color:bi.string().optional(),backgroundColor:bi.string().optional(),borderRadius:bi.string().optional(),fontSize:bi.string().optional(),buttonSize:tr.optional(),variant:ir.optional(),url:bi.string().optional(),target:bi.string().optional()}),Ir=bi.object({url:bi.string(),target:bi.string()}),Dr=bi.object({uniqid:bi.string()}),Mr=bi.object({title:bi.string(),widgets:ur().array()}),Ur=Nr.extend({openingType:nr.optional(),openingTypeLink:Ir.optional(),openingTypeAnchor:Dr.optional(),openingTypePopup:Mr.optional()}),Wr=bi.object({file:$n.optional(),useFilter:bi.boolean().optional()}),$r=bi.object({files:$n.array().optional(),fileDisplay:bi.enum(["list","gallery"]).optional()}),qr=bi.object({title:bi.string(),text:bi.string(),titleHeading:bi.enum(["h1","h2","h3","h4","h5","h6","p","span"]).optional(),textColor:bi.string().optional(),opacityFilter:bi.number().optional(),opacityColor:bi.string().optional(),file:$n.optional()}),Br=bi.object({slides:qr.array().optional(),maxWidth:bi.number().optional(),loop:bi.boolean().optional(),useDots:bi.boolean().optional(),startAt:bi.number().optional()}),zr=bi.object({title:bi.string(),value:bi.boolean().optional(),links:An.array().optional(),id:bi.number().optional(),user:bi.object({id:bi.number(),type:bi.literal("user"),mainType:bi.literal("user")}).optional()}),Vr=bi.object({arr:zr.array().optional()}),Jr=bi.object({widgets:ur().array().optional()}).and(bi.union([Pr,Wr,Lr,Ur,Er,$r,Zr,Br,Vr,Cr])),Gr=bi.object({busy:bi.union([bi.boolean(),bi.undefined()]).optional(),loading:bi.union([bi.boolean(),bi.undefined()]).optional(),initialized:bi.union([bi.boolean(),bi.undefined()]).optional(),mounted:bi.union([bi.boolean(),bi.undefined()]).optional(),hover:bi.union([bi.boolean(),bi.undefined()]).optional(),empty:bi.boolean().optional()}),Kr=bi.object({width:bi.number().or(bi.undefined()).optional(),inplace:bi.boolean(),isComponentVisible:bi.boolean().optional(),mode:gr,onClick:bi.function().returns(bi.void()).optional(),onChange:bi.function().args(Jr,bi.boolean()).returns(bi.void()),onStateChange:bi.function().args(Gr).returns(bi.void())}),Hr=(e,t)=>t.safeParse(e).success,Qr=bi.object({name:bi.literal(sr.Api),uniqid:bi.string(),content:Zr}),Yr=e=>Hr(e,Qr),Xr=bi.lazy((()=>bi.object({name:bi.literal(sr.ArticleButton),uniqid:bi.string(),content:Ur}))),es=e=>Hr(e,Xr),ts=bi.object({name:bi.literal(sr.ArticleGallery),uniqid:bi.string(),content:Er}),is=e=>Hr(e,ts),ns=bi.object({name:bi.literal(sr.ArticleTitle),uniqid:bi.string(),content:Lr}),rs=e=>Hr(e,ns),ss=bi.object({name:bi.literal(sr.ArticleText),uniqid:bi.string(),content:Pr}),as=e=>Hr(e,ss),os=bi.object({name:bi.literal(sr.ArticleImage),uniqid:bi.string(),content:Wr}),cs=e=>Hr(e,os),ls=bi.object({name:bi.literal(sr.ArticleAttachment),uniqid:bi.string(),content:$r}),ds=e=>Hr(e,ls),us=bi.object({name:bi.literal(sr.ArticleSlider),uniqid:bi.string(),content:Br}),ps=e=>Hr(e,us),ms=bi.object({name:bi.literal(sr.CheckList),uniqid:bi.string(),content:Vr.and(pr)}),hs=e=>Hr(e,ms),fs=bi.object({text:bi.string(),value:bi.boolean().optional(),links:An.array().optional(),uri:bi.string().optional(),mimetype:bi.string().optional(),id:bi.number().optional(),user:Fi.optional()}),gs=bi.object({arr:fs.array().optional()}),ys=bi.object({name:bi.literal("widget-check-list"),uniqid:bi.string(),content:gs,title:bi.string()}),bs=bi.object({label:bi.string(),description:bi.string(),name:ar,img:bi.string(),available:bi.boolean(),panel:bi.object({useWrapper:bi.boolean(),useEditor:bi.boolean(),useWidgets:bi.boolean()})}),vs=bi.object({title:bi.string().optional(),view:bi.any().optional()}),ws=bi.object({token:bi.string().or(bi.undefined()).optional(),ids:bi.record(bi.string(),ur()),layers:bi.record(bi.string(),fr),states:bi.record(bi.string(),Gr),modal:vs.or(bi.undefined()),editableMap:bi.record(bi.string(),bi.object({index:bi.number(),uniqid:bi.string()})),currentEditableIndex:bi.number(),currentEditableWidgetId:bi.string().or(bi.undefined()),widgetObject:bi.record(bi.string(),Ki.partial())}),_s=bi.object({widgets:ws}),ks=bi.lazy((()=>hr.schema.extend({articleWidgetsCover:bi.number().or(bi.undefined()),_audience:Qn.array()}))),xs=bi.lazy((()=>Ki.extend({dateCreation:bi.string(),dateModified:bi.string()}))),js=xs.schema.extend({description:bi.string().nullable().optional(),_user:Fi,_right:Vi,_audience:Tn.array(),image:Un.optional(),articleWidgets:ur().array().optional()}),Ss=js.extend({_attachedFiles:$n.array()}),As=Ss.extend({processContext:bi.null(),uiObjectLink:Ki.array().optional()}),Os=e=>Ss.extend({idDraft:bi.number(),form:e}),Ts=bi.object({type:bi.string().optional(),format:In.optional(),formatExtend:Dn.optional(),query:bi.string().optional(),limit:bi.number().optional(),page:bi.number().optional(),orders:Cn.optional(),filters:Pn.optional()}),Cs=bi.object({uri:bi.string().optional(),idArticle:bi.number().optional(),format:In.optional()}),Fs=bi.object({title:bi.string().optional(),description:bi.string().optional().nullable(),type:bi.string().optional(),publishTo:bi.string().optional(),idSpot:bi.array(bi.string()).optional()}),Rs=bi.object({id:bi.number(),type:bi.string(),dateCreation:bi.string(),dateModified:bi.string(),title:bi.string(),uri:bi.string()}),Es=bi.object({attachment:bi.boolean().optional(),idArticle:bi.number(),limits:bi.object({max:bi.number(),start:bi.number()}).optional()}),Ls=bi.object({token:bi.string(),content:bi.string(),idArticle:bi.number(),sendAlert:bi.boolean(),alertAuthor:bi.boolean(),widgets:ur().array().optional()}),Ps=bi.object({token:bi.string().optional(),description:bi.string().optional(),idComment:bi.number(),widgets:ur().array().optional()}),Zs=bi.object({idUser:bi.string(),dateRead:bi.string(),Pseudo:bi.string(),type:bi.string()}),Ns=bi.object({token:bi.string(),fullname:bi.string()}),Is=bi.object({redirectUrl:bi.string()}),Ds=bi.object({token:bi.string()}),Ms=bi.object({dateStart:bi.string(),title:bi.string()}),Us=e=>bi.object({isActive:bi.boolean()}).and(e),Ws=bi.enum(["drive_microsoft_graph","drive_dropbox","drive_google"]),$s=Us(bi.object({drives:bi.record(Ws,bi.boolean())})),qs=Us(bi.object({label:bi.string()})),Bs=Us(bi.object({orderBy:bi.string(),order:bi.enum(["ASC","DESC"])})),zs=Us(bi.object({sendAlert:bi.boolean()})),Vs=Us(bi.object({})),Js=Us(bi.object({create:bi.boolean(),autorize:bi.array(bi.enum(["message","comment","board","article"]).optional())})),Gs=bi.object({DriveHook:$s,calendarHook:qs,FileBankHook:Bs,spotRssFeed:Vs,WidgetHook:Js,AdminAdvancedHook:zs}).partial(),Ks=e=>Gs.and(bi.record(bi.string(),bi.any())).parse(e),Hs=bi.object({id:bi.number(),idFolder:bi.number().optional(),fileName:bi.string(),nbViews:bi.number(),nbDistinctViews:bi.number(),nbDownloads:bi.number()}),Qs=bi.object({id:bi.number(),folderName:bi.string(),nb:bi.number(),nbDistinct:bi.number()}),Ys=bi.object({nbFolders:bi.number(),nbFiles:bi.number()}),Xs="accept",ea="deny",ta=new D(new Sn),ia=new jn(ta);window.JamespotUserApi=ia;const na=ia,ra=jn;module.exports=i})();
|
|
1
|
+
(()=>{"use strict";var e={d:(t,i)=>{for(var n in i)e.o(i,n)&&!e.o(t,n)&&Object.defineProperty(t,n,{enumerable:!0,get:i[n]})},o:(e,t)=>Object.prototype.hasOwnProperty.call(e,t),r:e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})}},t={};e.r(t),e.d(t,{ACCESS_REQUEST_ACCEPT:()=>sa,ACCESS_REQUEST_DENY:()=>aa,AdminLicenseApi:()=>r,AdminStoreApi:()=>s,AdminUtilsApi:()=>a,DateFormatSchema:()=>Sr,Format:()=>In,GroupModerateStatus:()=>Xi,JApplicationApi:()=>o,JArticleApi:()=>Q,JAssetReservation:()=>X,JAudienceApi:()=>ee,JBaseApi:()=>i,JBbbApi:()=>te,JBookmarkApi:()=>ie,JBusinessNetworkingApi:()=>ne,JCommunityApi:()=>re,JDatasourceApi:()=>se,JDiapazoneApi:()=>ae,JFaqApi:()=>le,JFileApi:()=>ce,JFilebankApi:()=>de,JGlobalApi:()=>ue,JGroupApi:()=>he,JIAApi:()=>kn,JLandApi:()=>on,JMessengerApi:()=>cn,JObjectApi:()=>vn,JSearchApi:()=>ln,JShareApi:()=>fn,JSocialActionApi:()=>_n,JTaxonomyApi:()=>un,JUserApi:()=>pn,JWedocApi:()=>mn,JWidgetApi:()=>xn,JamespotUserApi:()=>Sn,JamespotUserApiInstance:()=>ca,Network:()=>M,NumberFormatSchema:()=>Ar,StudioApplicationStatus:()=>n,TVDisplayApi:()=>hn,UserLevel:()=>Ci,WidgetDatasourceTableContentSchema:()=>Rr,WidgetDatasourceTableTypeSchema:()=>Lr,WidgetTableColumnDataSchema:()=>Or,WidgetTableColumnSchema:()=>Cr,WidgetTableColumnTypesSchema:()=>jr,WidgetTableColumnWidgetDateSchema:()=>kr,WidgetTableColumnWidgetSelectOptionSchema:()=>wr,WidgetTableColumnWidgetSelectSchema:()=>_r,WidgetTableColumnWidgetTextSchema:()=>vr,WidgetTableColumnWidgetsSchema:()=>xr,WidgetTableColumnsData:()=>Tr,WidgetTableContentSchema:()=>Fr,WidgetsName:()=>or,WindowBrowser:()=>An,addCommentParamsSchema:()=>Zs,adminLicenseStatsSchema:()=>On,api:()=>da,articleCreationSchema:()=>Ls,articleDisplayModeSchema:()=>fr,articleGetConfigSchema:()=>Rs,articleListConfigSchema:()=>Fs,audienceAutocompleteSchema:()=>Xn,audienceSchema:()=>Fn,baseArticleSchema:()=>Es,baseAutocompleteSchema:()=>Gn,businessContactSchema:()=>qi,combineFormat:()=>B,combinedWidgetContentSchema:()=>Gr,combinedWidgetTypeSchema:()=>lr,cssBackgroundPositionSchema:()=>tr,cssBackgroundSizeSchema:()=>ir,cssTextAlignTypeSchema:()=>er,deepEqual:()=>$,default:()=>la,ensureWidgetApiType:()=>es,ensureWidgetArticleAttachmentType:()=>ps,ensureWidgetArticleButtonType:()=>is,ensureWidgetArticleGalleryType:()=>rs,ensureWidgetArticleImageType:()=>ds,ensureWidgetArticleSliderType:()=>hs,ensureWidgetArticleTextType:()=>cs,ensureWidgetArticleTitleType:()=>as,ensureWidgetCheckListType:()=>gs,ensureWidgetDatasourceTableType:()=>Er,extensions:()=>x,extractTaxonomiesFromObject:()=>V,extractTaxonomiesFromObjectAndMapProperty:()=>J,extractTaxonomiesFromObjectAndMapUri:()=>K,fileCropConfigSchema:()=>qn,filterSchema:()=>Pn,filterValueSchema:()=>Rn,filtersSchema:()=>Nn,formatExtensionSchema:()=>Un,formatImgUrl:()=>_,formatListSchema:()=>Dn,getArgs:()=>y,getCommentsParamsSchema:()=>Ps,getExtensionFromName:()=>O,getFileExtensionFromMimetype:()=>A,getFileFamily:()=>E,getFileFamilyFromName:()=>R,getFormat:()=>v,getFrom:()=>f,getLicenseKindUsersParamsSchema:()=>ea,getMimetypeFromExtension:()=>S,getMimetypeFromName:()=>T,getSize:()=>b,getTimestamp:()=>g,getUri:()=>h,getUrl:()=>w,groupLittleSchema:()=>tn,imageSizeSchema:()=>$n,inferJInternalDraftView:()=>Cs,inferUserLicenseSchema:()=>ta,inferWidgetWrapperPropsSchema:()=>mr,jArticleExtendViewSchema:()=>Ts,jArticleListSchema:()=>As,jArticleLittleSchema:()=>Ss,jArticleViewSchema:()=>Os,jArticleWidgetLittle:()=>gr,jArticleWidgetViewSchema:()=>js,jEnsure:()=>d,jFileLittleCropSchema:()=>Vn,jFileLittleSchema:()=>Bn,jFileRenditionSchema:()=>Jn,jHrefSchema:()=>Tn,jObjectAutocompleteSchema:()=>Hn,jObjectBaseSchema:()=>Ki,jObjectListSchema:()=>Qi,jObjectLittleSchema:()=>Gi,jSpotAutocompleteSchema:()=>Yn,jUserAutocompleteSchema:()=>Qn,jUserListSchema:()=>Ri,jUserLittleSchema:()=>Fi,jUserValuesSchema:()=>Mi,jUserViewSchema:()=>Ei,legacyAngularJSTypeSchema:()=>hr,mediaLibraryFilesStatsSchema:()=>ia,mediaLibraryFolderStatsSchema:()=>na,mediaLibraryStatsSchema:()=>ra,mimetypeToExt:()=>j,mimetypes:()=>k,network:()=>oa,objectTimestamp:()=>C,openingTypeAnchorSchema:()=>Ur,openingTypeLinkSchema:()=>Dr,openingTypePopupSchema:()=>Wr,openingTypeSchema:()=>sr,orderSchema:()=>Cn,ordersSchema:()=>Zn,padStartTwoDigits:()=>m,prepareGroupForUpdate:()=>G,publicWebinarData:()=>Ws,publicWebinarFullnameRequestSchema:()=>Ms,publicWebinarGetDateRequestSchema:()=>Us,publicWebinarUrlSchema:()=>Ds,removeIfStartsWith:()=>p,replacePropertiesWithTypes:()=>q,resolveFileFamily:()=>N,resolveFileMimetype:()=>Z,resolveFilePath:()=>F,resolveFileUrl:()=>P,rightsSchema:()=>Vi,suffixIfDoesNotExist:()=>u,updateCommentParamsSchema:()=>Ns,uploadConfigSchema:()=>Wn,userDefaultFieldsTypeSchema:()=>Ii,userDirectoryConfigurationSchema:()=>Bi,userDownloadSchema:()=>Kn,userFieldSchema:()=>Ui,userFieldsConfigurationTypeSchema:()=>Di,userFieldsSchema:()=>Wi,userMapModelSchema:()=>Zi,userReadSchema:()=>Is,userValuesSchema:()=>$i,userlevelSpotShema:()=>en,validateIsFormatFileLittle:()=>zn,validateIsFormatHookListType:()=>Xs,validateIsFormatObjectList:()=>Yi,validateIsFormatObjectLittle:()=>Hi,validateIsFormatRights:()=>Ji,validateIsFormatUserDirectoryConfiguration:()=>zi,validateIsFormatUserLevelSpot:()=>nn,validateIsFormatUserList:()=>Li,validateIsFormatUserMapModel:()=>Ni,validateIsFormatUserView:()=>Pi,variantSizeTypeSchema:()=>nr,variantTypeSchema:()=>rr,widgetActiveValueSchema:()=>Si,widgetApiContentSchema:()=>Ir,widgetApiTypeSchema:()=>Xr,widgetArticleAttachmentContentSchema:()=>Br,widgetArticleAttachmentTypeSchema:()=>us,widgetArticleButtonContentSchema:()=>$r,widgetArticleButtonTypeSchema:()=>ts,widgetArticleCheckListTypeForFrontSchema:()=>vs,widgetArticleGalleryContentSchema:()=>Pr,widgetArticleGalleryTypeSchema:()=>ns,widgetArticleImageContentSchema:()=>qr,widgetArticleImageTypeSchema:()=>ls,widgetArticleSliderContentSchema:()=>Vr,widgetArticleSliderTypeSchema:()=>ms,widgetArticleTextContentSchema:()=>Nr,widgetArticleTextTypeSchema:()=>os,widgetArticleTitleContentSchema:()=>Zr,widgetArticleTitleTypeSchema:()=>ss,widgetButtonPropsSchema:()=>Mr,widgetCheckListContentArrForFrontSchema:()=>ys,widgetCheckListContentArrSchema:()=>Jr,widgetCheckListContentForFrontSchema:()=>bs,widgetCheckListContentSchema:()=>Kr,widgetCheckListTypeSchema:()=>fs,widgetContentKeysSchema:()=>ur,widgetDatePickerValueSchema:()=>ji,widgetDateValueSchema:()=>ki,widgetDatetimeValueSchema:()=>xi,widgetDefaultProps:()=>Qr,widgetDefinitionPropsSchema:()=>ws,widgetDisplayModeSchema:()=>br,widgetEmailValueSchema:()=>Ai,widgetExtendedTypeSchema:()=>pr,widgetKeysSchema:()=>cr,widgetLayerSchema:()=>yr,widgetModalPropsSchema:()=>_s,widgetNumberValueSchema:()=>_i,widgetSlideSchema:()=>zr,widgetStatePropsSchema:()=>Hr,widgetTextValueSchema:()=>vi,widgetTextareaValueSchema:()=>wi,widgetTypeKeysSchema:()=>dr,widgetUrlValueSchema:()=>Oi,widgetVectorSchema:()=>ar,widgetsRootStateSchema:()=>xs,widgetsStateSchema:()=>ks,widgetsValueSchema:()=>Ti});class i{constructor(e){this.jApi=e,this.network=e.network}}var n;class r extends i{getLicenseUserStatistics(e){return this.network.post({o:"licenseManager",f:"userStatistics"},e)}getLicenseStatistics(e,t){return this.network.post({o:"licenseManager",f:"statistics",kind:e},t)}assignLicense(e){return this.network.postCSRF({o:"licenseManager",f:"assignLicense",uri:e})}assignKindLicense(e,t){return this.network.postCSRF({o:"licenseManager",f:"assignLicenseKind",uri:e,kind:t})}unAssignLicense(e){return this.network.postCSRF({o:"licenseManager",f:"unassignLicense",uri:e})}unAssignKindLicense(e,t){return this.network.postCSRF({o:"licenseManager",f:"unassignLicenseKind",uri:e,kind:t})}getAssignmentMode(e,t){return this.network.post({o:"licenseManager",f:"getAssignmentMode",type:e},t)}setAssignmentMode(e,t){return this.network.postCSRF({o:"licenseManager",f:"setAssignmentMode",value:t,type:e})}assignPossiblesLicenses(e){return this.network.postCSRF({o:"licenseManager",f:"assignPossiblesLicenses",type:e})}unAssignUnusedLicenses(e,t){return this.network.postCSRF({o:"licenseManager",f:"unassignUnusedLicenses",type:e,kind:t})}optimizeLicenses(e){return this.network.postCSRF({o:"licenseManager",f:"optimizeLicenses",type:e})}getObjectsWithoutLicense(e,t){return this.network.post({o:"licenseManager",f:"countObjectsWithoutLicense",type:e,filter:t})}getLicensesNotAssigned(e){return this.network.post({o:"licenseManager",f:"countLicensesNotAssigned",type:e})}getLicensesAssigned(e){return this.network.post({o:"licenseManager",f:"getLicensesAssigned",type:e})}getLicenceUsersByKind(e,t,i){var n=function(e,t){var i={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(i[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var r=0;for(n=Object.getOwnPropertySymbols(e);r<n.length;r++)t.indexOf(n[r])<0&&Object.prototype.propertyIsEnumerable.call(e,n[r])&&(i[n[r]]=e[n[r]])}return i}(e,[]);return this.network.post(Object.assign(Object.assign({o:"licenseManager",f:"getUsers"},n),{format:t}),i)}}class s extends i{getItem(e){return this.network.post({o:"adminStore",f:"getItem",uri:e})}checkoutBilling(e){return this.network.postCSRF({o:"adminStore",f:"checkoutBilling",uri:e})}checkoutFinalize(e){return this.network.postCSRF({o:"adminStore",f:"checkoutFinalize",uri:e})}}class a extends i{getApps(e){return this.network.post({o:"admin",f:"apps"},e)}}!function(e){e.local="local",e.installed="installed",e.autosaved="autosaved",e.saved="saved"}(n||(n={}));class o extends i{list(){return this.network.post({o:"studio",f:"list"})}get(e,t){return this.network.post({o:"studio",f:"get",idApp:e,status:t})}install(e){return this.network.postCSRF({o:"studio",f:"install",value:e})}suspend(e){return this.network.postCSRF({o:"studio",f:"suspend",idApp:e})}restart(e){return this.network.postCSRF({o:"studio",f:"restart",idApp:e})}save(e,t,i){if(i===n.saved||i===n.autosaved)return this.network.postCSRF({o:"studio",f:"save",idApp:e,value:t,status:i});throw"Invalid status value"}delete(e,t){return i=this,n=void 0,s=function*(){return this.network.postCSRF({o:"studio",f:"delete",idApp:e,status:t}).then((e=>{if(0===e.error)return e.messages;throw e.messages}))},new((r=void 0)||(r=Promise))((function(e,t){function a(e){try{c(s.next(e))}catch(e){t(e)}}function o(e){try{c(s.throw(e))}catch(e){t(e)}}function c(t){var i;t.done?e(t.value):(i=t.value,i instanceof r?i:new r((function(e){e(i)}))).then(a,o)}c((s=s.apply(i,n||[])).next())}));var i,n,r,s}cssClassList(){return this.network.post({o:"studio",f:"icons"})}}function c(e){const t=e;return t&&"number"==typeof t.id&&"number"==typeof t.targetId}const l={bookmarkLink:c},d={isBookmarkLink:function(e){return"targetId"in e&&!!e.targetId},isBookmarkCustom:function(e){const t=e;return void 0!==t.bookmarkLabel||void 0!==t.bookmarkMeta||void 0!==t.bookmarkUrl},isBookmarkRawList:c,isTVChannelType:function(e,t){return"tvChannelType"in e&&e.tvChannelType===t},objectIsType:function(e,t){return null!=t&&l[e](t)},isStandardApiError:e=>"object"==typeof e&&null!==e&&"error"in e&&"errorMsg"in e&&"messages"in e&&"number"==typeof e.error&&"string"==typeof e.errorMsg&&Array.isArray(e.messages),isAbortApiError:e=>null!==e&&"object"==typeof e&&"error"in e&&"aborted"in e&&-1===e.error&&!0===e.aborted};function u(e,t){return e&&!e.endsWith(t)?`${e}${t}`:e}function p(e,t){return e&&e.startsWith(t)?e.split("").slice(t.length).join(""):e}function m(e){return e.toString().padStart(2,"0")}function h(e){return"uri"in e&&e.uri?e.uri:`${e.type}/${e.recordId}`}function f(e){return p(u(e.from,"/"),"/")||""}function g(e){return e.timestamp?`?_=${e.timestamp}`:""}function y(e){const t=[];return"timestamp"in e&&e.timestamp&&t.push(`_=${e.timestamp}`),"iconColor"in e&&e.iconColor&&t.push(`color=${e.iconColor}`),t.length?"?"+t.join("&"):""}function b(e,t=2){return"size"in e&&e.size?e.size:"width"in e&&e.width&&"height"in e&&e.height?`${e.width*t}x${e.height*t}`:""}function v(e){return e.format||"png"}function w(e){try{return new URL(e)}catch(e){}try{return new URL(window.location.origin+"/"+p(e,"/"))}catch(e){}}function _(e,t=2){if("url"in e&&e.url){const t=w(e.url);if(t)return"timestamp"in e&&e.timestamp&&!t.searchParams.has("_")&&t.searchParams.append("_",e.timestamp.toString()),t.toString()}return`/${f(e)}${b(e,t)}/${h(e)}.${v(e)}${y(e)}`}const k=["application/vnd.openxmlformats-officedocument.wordprocessingml.document","application/vnd.openxmlformats-officedocument.spreadsheetml.sheet","application/vnd.openxmlformats-officedocument.presentationml.presentation","application/pdf","application/zip","application/illustrator","application/postscript","application/vnd.ms-opentype","application/x-font-ttf","application/octet-stream","audio/mp3","audio/mpeg","font/ttf","font/otf","image/jpeg","image/jpg","image/png","image/gif","image/vnd.adobe.photoshop","image/svg+xml","text/plain","text/csv","video/mp4","video/webm"],x=["docx","xlsx","csv","pptx","pdf","zip","ai","mp3","mpeg","ttf","otf","jpg","jpeg","png","gif","psd","svg","txt","mp4","odt","webm"],j={"application/vnd.openxmlformats-officedocument.wordprocessingml.document":"docx","application/vnd.openxmlformats-officedocument.spreadsheetml.sheet":"xlsx","application/vnd.openxmlformats-officedocument.presentationml.presentation":"pptx","application/vnd.oasis.opendocument.text":"odt","application/pdf":"pdf","application/zip":"zip","application/x-zip-compressed":"zip","application/illustrator":"ai","application/postscript":"ai","audio/mp3":"mp3","audio/mpeg":"mpeg","font/ttf":"ttf","font/otf":"otf","image/jpeg":"jpeg","image/jpg":"jpg","image/png":"png","image/gif":"gif","application/x-font-ttf":"ttf","application/vnd.ms-opentype":"otf","image/vnd.adobe.photoshop":"psd","image/svg+xml":"svg","text/plain":"txt","text/csv":"xlsx","video/mp4":"mp4","video/webm":"mp4"},S=e=>Object.keys(j).find((t=>j[t]===e)),A=e=>{var t;return null!==(t=j[e])&&void 0!==t?t:void 0};function O(e){const t=String(e).split(".").pop();return x.find((e=>e===t))}const T=e=>{var t;const i=O(e);return null!==(t=S(i))&&void 0!==t?t:"application/octet-stream"},C=e=>e?(new Date(e).getTime()/1e3).toFixed(0):void 0,F=(e,t="fitx80")=>{const i=N(e),n=C(e.dateModified);switch(i){default:return;case"video":return`/media/${e.id}.mp4?stream=true`+(n?`&_=${n}`:"");case"audio":return`/media/${e.id}.mp3`+(n?`?_=${n}`:"");case"gif":return _({timestamp:n,size:t,from:"imagecache",uri:e.uri,format:"gif"});case"image":return _({timestamp:n,size:t,from:"imagecache",uri:e.uri})}},R=e=>{const t=O(e);return void 0!==t?E(S(t)):"application"},L=e=>-1!==["image/vnd","image/svg","image/heic"].findIndex((t=>e.startsWith(t)));function E(e){return e&&e.startsWith("folder/")?"folder":null==e||L(e)?"application":e.startsWith("image/gif")?"gif":e.startsWith("image/")?"image":e.startsWith("video/")?"video":e.startsWith("audio/")?"audio":e.startsWith("font/")||e.startsWith("application/x-font-ttf")||e.startsWith("application/vnd.ms-opentype")?"font":e.startsWith("text/")?"text":"application"}const P=(e,t,i="rr")=>"ng"===i?`/ng/file/${e}/${t}`:`/ng/rr/file/${e}/${t}`,Z=e=>void 0===e.mimetype||"application/octet-stream"===e.mimetype?T(e.title):e.mimetype,N=e=>void 0===e.mimetype||"application/octet-stream"===e.mimetype?R(e.title):E(e.mimetype);var I=function(e,t,i,n){return new(i||(i=Promise))((function(r,s){function a(e){try{c(n.next(e))}catch(e){s(e)}}function o(e){try{c(n.throw(e))}catch(e){s(e)}}function c(e){var t;e.done?r(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(a,o)}c((n=n.apply(e,t||[])).next())}))};class M{constructor(e,t="api-front"){this.window=e,this.action=t}static _formatPostOptions(e){const t=e?{body:JSON.stringify(e)}:void 0;return Object.assign({method:"POST",credentials:"same-origin"},t)}getUrl(e,t){return I(this,void 0,void 0,(function*(){const i=yield this.window.getBackendUrl();let n;try{n=new URL(`/${this.action}/${e}/${t}`,i).href}catch(r){n=`${i}/${this.action}/${e}/${t}`}return n}))}getHostname(){return I(this,void 0,void 0,(function*(){const e=(yield this.window.getBackendUrl()).split("//");return e.length>1?e[1]:e[0]}))}fetch(e,t){var{o:i,f:n}=e,r=function(e,t){var i={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(i[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var r=0;for(n=Object.getOwnPropertySymbols(e);r<n.length;r++)t.indexOf(n[r])<0&&Object.prototype.propertyIsEnumerable.call(e,n[r])&&(i[n[r]]=e[n[r]])}return i}(e,["o","f"]);return I(this,void 0,void 0,(function*(){void 0===t&&(t=null);const e=yield this.getUrl(i,n);return this.window.fetch(e,Object.assign(Object.assign({},M._formatPostOptions(r)),{signal:t}))}))}post(e,t){return this.fetch(e,t).then((e=>e.json())).then((e=>{if(0===e.error)return e;throw{error:e.error,errorMsg:e.errorMsg,messages:e.messages}})).catch((e=>{if(t&&t.aborted)throw{error:-1,aborted:!0};throw e}))}postFile(e){return I(this,void 0,void 0,(function*(){const t=yield this.getUrl("file","create");if(e.append("format","raw-little"),!e.has("token")){const{result:t}=yield this.token();e.append("token",t)}const i=e.get("token");return i&&"string"==typeof i?this.window.fetch(t,{method:"POST",credentials:"same-origin",body:e}).then((e=>e.json())).then((e=>({response:e,token:i}))):Promise.reject("Missing token")}))}postCSRF(e){return this.tokenCSRF().then((t=>this.post(Object.assign(e,{tokenCSRF:t.result}))))}postToken(e){return this.token().then((t=>this.post(Object.assign(e,{token:t.result}))))}maybePostToken(e){return"token"in e&&e.token?this.post(e):this.postToken(e)}token(){return this.post({o:"misc",f:"token"})}tokenCSRF(){return this.post({o:"misc",f:"tokenCSRF"})}}const D=Array.isArray,U=Object.keys,W=Object.prototype.hasOwnProperty;function $(e,t,i){const n=null==i?void 0:i.map((e=>e.split(".")));if(e===t)return!0;if(e&&t&&"object"==typeof e&&"object"==typeof t){const r=D(e),s=D(t);let a,o,c;if(r&&s){if(o=e.length,o!==t.length)return!1;for(a=o;0!=a--;)if(!$(e[a],t[a],i))return!1;return!0}if(r!==s)return!1;const l=e instanceof Date,d=t instanceof Date;if(l!==d)return!1;if(l&&d)return e.getTime()===t.getTime();const u=e instanceof RegExp,p=t instanceof RegExp;if(u!==p)return!1;if(u&&p)return e.toString()===t.toString();const m=U(e).filter((e=>!(null==n?void 0:n.some((t=>1===t.length&&t[0]===e)))));if(o=m.length,o!==U(t).filter((e=>!(null==n?void 0:n.some((t=>1===t.length&&t[0]===e))))).length)return!1;for(a=o;0!=a--;)if(!W.call(t,m[a]))return!1;for(a=o;0!=a--;)if(c=m[a],!("_owner"===c&&e.$$typeof||$(e[c],t[c],null==n?void 0:n.filter((e=>e.length>1&&e[0]===c)).map((e=>e.splice(1).join("."))))))return!1;return!0}return e!=e&&t!=t}function q(e,t){if(Array.isArray(e))return e.map((e=>q(e,t)));if("object"==typeof e&&null!==e){let i={};return Object.keys(e).forEach((n=>{i=Object.assign(Object.assign({},i),{[n]:n&&t.includes(n)?typeof e[n]:q(e[n],t)})})),i}return e}const B=(e,t)=>Array.isArray(t)&&t.length?[e,...t].join(","):e;function z(e){return e.startsWith("tag_")||"tags"===e}function V(e){return Object.fromEntries(Object.entries(e).filter((([e])=>z(e))))}function J(e,t,i){return Object.fromEntries(Object.entries(e).filter((([e])=>z(e))).map((([e,n])=>{const r=Array.isArray(n)?n.map((e=>"object"==typeof e&&e&&t in e?e[t]:e)):n;return[e,i&&Array.isArray(r)?i(r):r]})))}function K(e){return J(e,"uri")}const G=e=>{var t;let i={};"_errors"in e&&(i._errors=e._errors),"_options"in e&&(i._options=e._options),"title"in e&&(i.title=e.title),"description"in e&&(i.description=e.description),"activity"in e&&(i.activity=e.activity),"image"in e&&(i.image=e.image),"uri"in e&&(i.uri=e.uri),"type"in e&&(i.type=e.type),"edito"in e&&(i.edito=e.edito),"category"in e&&(i.category=e.category.toString()),"commentLevel"in e&&(i.commentLevel=e.commentLevel),"_options"in e&&(null===(t=e._options)||void 0===t?void 0:t.custom_widgets)&&(i.custom_widgets=Array.isArray(e._options.custom_widgets)?{}:e._options.custom_widgets),"displayType"in e&&(i.displayType=e.displayType),"language"in e&&(i.language=e.language),"edit_access"in e&&(i.edit_access=e.edit_access),"lock_mail"in e&&(i.lock_mail=e.lock_mail),"fileSyncEnabled"in e&&(i.fileSyncEnabled=e.fileSyncEnabled),"fileSyncVersioningType"in e&&(i.fileSyncVersioningType=e.fileSyncVersioningType),"fileBankQuota"in e&&(i.fileBankQuota=e.fileBankQuota),"idCommunity"in e&&(i.idCommunity=e.idCommunity),"lastRssExecution"in e&&(i.lastRssExecution=e.lastRssExecution),"mail_comment"in e&&(i.mail_comment=e.mail_comment),"mail_frequency"in e&&(i.mail_frequency=e.mail_frequency),"mail_spotit"in e&&(i.mail_spotit=e.mail_spotit),"mail_subscriber"in e&&(i.mail_subscriber=e.mail_subscriber),"notifyFolder"in e&&(i.notifyFolder=e.notifyFolder),"nounsubscribe"in e&&(i.nounsubscribe=e.nounsubscribe),"privacy"in e&&(i.privacy=e.privacy),"publishFolder"in e&&(i.publishFolder=e.publishFolder),"rss_access"in e&&(i.rss_access=e.rss_access),"rss_feed"in e&&(i.rss_feed=e.rss_feed&&Array.isArray(e.rss_feed)?JSON.stringify(e.rss_feed.map((e=>{var{_user:t}=e,i=function(e,t){var i={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(i[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var r=0;for(n=Object.getOwnPropertySymbols(e);r<n.length;r++)t.indexOf(n[r])<0&&Object.prototype.propertyIsEnumerable.call(e,n[r])&&(i[n[r]]=e[n[r]])}return i}(e,["_user"]);return Object.assign(Object.assign({},i),{idUser:null==t?void 0:t.id})}))):"[]"),"rss_key"in e&&(i.rss_key=e.rss_key),"spot_right_user"in e&&(i.spot_right_user=e.spot_right_user),"spotBanner"in e&&(i.spotBanner=e.spotBanner),"spotDefaultPublishType"in e&&(i.spotDefaultPublishType=e.spotDefaultPublishType),"user_level_signup"in e&&(i.user_level_signup=e.user_level_signup),"useTeaser"in e&&(i.useTeaser=e.useTeaser),"widgets"in e&&(i.widgets=e.widgets);const n=V(e);if(i=Object.assign(Object.assign({},i),n),H(e,i))return i;throw new Error},H=(e,t)=>{const i=["id","mainType","dateCreation","dateModified","_url","o2apLinksSources"],n=["custom_widgets"],r=Object.keys(e),s=Object.keys(t),a=r.filter((e=>!s.includes(e)&&!i.includes(e))),o=s.filter((e=>!r.includes(e)&&!n.includes(e))),c=[...a.map((e=>"- "+e)),...o.map((e=>"+ "+e))];if(a.length>0||o.length>0)throw new Error(`prepareGroupForUpdate :: Wrong group mapping | Diff : ${JSON.stringify(c)}`);return!0};class Q extends i{list(e){var t,i;return this.network.post(Object.assign(Object.assign({o:"objectList",f:"jamespotArticleQueryList"},e),{format:B(null!==(t=e.format)&&void 0!==t?t:"raw-list",null!==(i=e.formatExtend)&&void 0!==i?i:[])}))}get(e,t){var i;return this.network.post(Object.assign(Object.assign({o:"article",f:"get"},e),{format:B(null!==(i=e.format)&&void 0!==i?i:"raw-view",null==t?void 0:t.formatExtension)}),null==t?void 0:t.signal)}create(e,t){return this.network.maybePostToken(Object.assign({o:"article",f:"create",format:null!=t?t:"raw-list"},e))}update(e){return this.network.post(Object.assign(Object.assign({format:"raw-list"},e),{o:"article",f:"update"}))}delete(e){return this.network.postCSRF({o:"article",f:"delete",idArticle:e})}count(e){return this.network.post({o:"article",f:"count",type:e})}getAttachments(e,t,i){return this.network.post({o:"article",f:"getAttachment",idArticle:e,type:t,format:i})}permalink(e){return this.network.post({o:"article",f:"permalink",permalinkId:e})}saveAsDraft(e,t,i){return this.network.post({o:"article",f:"saveAsDraft",form:e,contentType:t,idDraft:i})}getComments(e,t){var i,n;return this.network.post(Object.assign(Object.assign({o:"article",f:"getComments"},e),{attachments:null!==(i=e.attachment)&&void 0!==i&&i,limits:null!==(n=e.limits)&&void 0!==n?n:{start:0,max:1e4},format:null!=t?t:"raw-little"}))}addComment(e,t){return this.network.post(Object.assign(Object.assign({o:"article",f:"addComment"},e),{alertAuthor:Number(e.alertAuthor),sendAlert:Number(e.sendAlert),type:"comment",format:null!=t?t:"raw-little"}))}updateComment(e,t){return this.network.post(Object.assign(Object.assign({o:"article",f:"updateComment"},e),{format:null!=t?t:"raw-little"}))}deleteComment(e){return this.network.postCSRF({o:"comment",f:"delete",idComment:e})}getRead(e){return this.network.post({o:"article",f:"getRead",uri:e})}}var Y=function(e,t){var i={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(i[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var r=0;for(n=Object.getOwnPropertySymbols(e);r<n.length;r++)t.indexOf(n[r])<0&&Object.prototype.propertyIsEnumerable.call(e,n[r])&&(i[n[r]]=e[n[r]])}return i};class X extends i{configuration(){return this.network.post({o:"assetReservation",f:"configuration"})}createReservation(e){return this.network.postCSRF(Object.assign({o:"assetReservation",f:"createReservation",format:"raw-list"},e))}getReservations(e){var{format:t="raw-list"}=e,i=Y(e,["format"]);return this.network.post(Object.assign({o:"assetReservation",f:"getReservations",format:t},i))}cancelReservation(e){return this.network.post({o:"assetReservation",f:"cancelReservation",format:"raw-list",idArticle:e})}bookByDate(e){var{format:t="raw-list"}=e,i=Y(e,["format"]);return this.network.post(Object.assign({o:"assetReservation",f:"BookByDate",format:t},i))}getList(e){var{format:t="raw-list"}=e,i=Y(e,["format"]);return this.network.post(Object.assign({o:"objectList",f:"assetReservationList",format:t},i))}}class ee extends i{autocomplete(e){return this.network.post({o:"autocomplete",f:"audience",q:e}).then((e=>{if(Array.isArray(e.result))return e.result;throw"Bad response from backend"}))}}class te extends i{publicWebinarFullname(e){return this.network.post(Object.assign({o:"bigBlueButton",f:"publicWebinarFullname"},e))}getPublicWebinarData(e){return this.network.post(Object.assign({o:"bigBlueButton",f:"getPublicWebinarData"},e))}}class ie extends i{getFormattedList(e,t){return this.network.post(Object.assign({o:"objectList",f:"bookmarksList",format:t},e))}addFormattedLink(e,t,i){const n=null!=i?i:"list";return this.network.post({o:"custom",f:"actionAdd",type:"bookmarkLink",targetId:e,targetType:t,format:n})}addBookmark(e,t){return this.network.postCSRF(Object.assign({o:"bookmarks",f:"add"},e))}delete(e){return this.network.postCSRF({o:"bookmarks",f:"delete",bookmarkID:e})}rename(e,t,i){return this.network.postCSRF({o:"bookmarks",f:"rename",bookmarkID:e,bookmarkLabel:t,bookmarkUrl:i})}move(e,t,i){return this.network.postCSRF({o:"bookmarks",f:"move",bookmarkID:e,bookmarkReference:t,bookmarkPosition:i})}}class ne extends i{getInfos(e,t){return this.network.post({o:"BusinessNetworking",f:"MarkerInfo",id:e,format:null!=t?t:"raw-little"})}}class re extends i{get(e,t){return this.network.post({o:"community",f:"getCommunity",idCommunity:e,format:t||"raw-little"})}sendRequest(e,t){return this.network.post({o:"community",f:"sendRequest",message:e,idUserTo:t})}autocomplete(e){return this.network.post({o:"autocomplete",f:"community",q:e}).then((e=>e.result))}}class se extends i{get(e,t){return this.network.post({o:"widget",f:"datasourceGet",uri:e,format:t})}getModel(e){return this.network.post({o:"widget",f:"datasourceGetModel",uri:e})}getObject(e){return this.network.post({o:"widget",f:"datasourceGetObject",uri:e})}create({title:e,datasourceType:t,datasourceIdentifier:i}){return this.network.postCSRF({o:"widget",f:"datasourceCreate",title:e,datasourceType:t,datasourceIdentifier:i})}}class ae extends i{create(e,t,i,n,r){return this.network.post({o:"article",f:"create",type:e,token:t,title:i,dateStart:n,publishTo:r})}getList(e="",t=[],i=[],n=1,r="raw-list"){return this.network.post({o:"objectList",f:"diapazoneQueryList",query:e,filters:t,orders:i,page:n,format:r})}}var oe=function(e,t,i,n){return new(i||(i=Promise))((function(r,s){function a(e){try{c(n.next(e))}catch(e){s(e)}}function o(e){try{c(n.throw(e))}catch(e){s(e)}}function c(e){var t;e.done?r(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(a,o)}c((n=n.apply(e,t||[])).next())}))};class ce extends i{upload(e){const t=new FormData;return t.append("attrName",e.attrName),e.file?t.append(e.attrName,e.file):e.url&&t.append("url",e.url),t.append("token",e.token),this.network.postFile(t)}uploadMany(e){return oe(this,void 0,void 0,(function*(){return Promise.all(e.map((e=>this.upload(e))))}))}get(e,t){return oe(this,void 0,void 0,(function*(){return this.network.post({o:"file",f:"get",idFile:e,format:t})}))}getParent(e,t){return oe(this,void 0,void 0,(function*(){return this.network.post({o:"file",f:"getParent",idFile:e,format:t})}))}getWithHash(e,t,i){return oe(this,void 0,void 0,(function*(){return this.network.post({o:"file",f:"getWithHash",idFile:e,hash:t,format:i})}))}duplicate(e,t,i){return oe(this,void 0,void 0,(function*(){return this.network.postCSRF({o:"file",f:"duplicateFile",idFile:e,title:t,publishTo:i})}))}updateFile(e,t){return oe(this,void 0,void 0,(function*(){return this.network.postCSRF({o:"file",f:"updateFile",idFile:e,title:t})}))}update(e,t,i){return oe(this,void 0,void 0,(function*(){return this.network.post({o:"file",f:"update",idFile:e,type:t,cropDatas:Object.assign(Object.assign({},i),{rotateBeforeCrop:!0}),killSize:i.killSize,format:"raw-little"})}))}deleteFile(e,t,i,n){return oe(this,void 0,void 0,(function*(){return this.network.post({o:"file",f:"delete",idFile:e,attrName:t,token:i},n)}))}deleteImage(e,t){return oe(this,void 0,void 0,(function*(){return this.network.post({o:"file",f:"deleteImage",id:e,type:t})}))}getDownload(e){return this.network.post({o:"file",f:"getDownload",id:e})}generatePreview(e){return this.network.post({o:"file",f:"generatePreview",id:e})}}class le extends i{getCategoriesList(e,t){return this.network.post({o:"objectList",f:"faqQueryList",format:null!=e?e:"raw-list",orders:null!=t?t:[{name:"dateCreation",sort:"ASC"}]})}createCategory(e,t){return this.jApi.article.create(Object.assign(Object.assign({},e),{type:"faq"}),null!=t?t:"raw-view")}updateCategory(e,t){return this.jApi.article.update(Object.assign(Object.assign({},e),{type:"faq",format:null!=t?t:"raw-view"}))}getCategory(e,t){return this.jApi.article.get({idArticle:e,format:null!=t?t:"raw-view"})}deleteCategory(e){return this.jApi.article.delete(e)}checkItem(e,t,i){return this.network.post({o:"faq",f:"checkItem",query:e,page:null!=t?t:1,format:null!=i?i:"raw-list"})}getTaxonomy(){return this.network.post({o:"faq",f:"getFaqTaxonomy"})}getHookProperties(e){return this.network.post({o:"faq",f:"getHookProperties",properties:null!=e?e:["_web"]})}getAccess(){return this.network.post({o:"faq",f:"access"})}createTheme(e,t){return this.network.postCSRF(Object.assign(Object.assign({o:"faq",f:"add-theme"},e),{format:null!=t?t:"raw-view"}))}deleteTheme(e,t){return this.network.postCSRF(Object.assign(Object.assign({o:"faq",f:"delete-theme"},e),{format:null!=t?t:"raw-view"}))}updateTheme(e,t){return this.network.postCSRF(Object.assign(Object.assign({o:"faq",f:"set-theme"},e),{format:null!=t?t:"raw-view"}))}getEntry(e,t){return this.network.post({o:"faq",f:"get-entry",uri:e,format:null!=t?t:"raw-view"})}deleteEntry(e){return this.jApi.article.delete(e)}createEntry(e,t){return this.jApi.article.create(Object.assign(Object.assign({},e),{idSpot:["content"],type:"faqItem"}),null!=t?t:"raw-view")}addEntry(e,t){return this.network.postCSRF(Object.assign(Object.assign({o:"faq",f:"add-entry"},e),{format:null!=t?t:"raw-view"}))}updateEntry(e,t){return this.jApi.article.update(Object.assign(Object.assign({},e),{type:"faqItem",format:null!=t?t:"raw-view"}))}moveEntry(e,t){return this.network.postCSRF(Object.assign(Object.assign({o:"faq",f:"move-entry"},e),{format:null!=t?t:"raw-view"}))}moveTheme(e,t){return this.network.postCSRF(Object.assign(Object.assign({o:"faq",f:"move-theme"},e),{format:null!=t?t:"raw-view"}))}}class de extends i{getBanks(e="list"){return this.network.post({o:"fileBank",f:"getBanks",format:e}).then((e=>e.result))}getFolders(e){return this.network.post({o:"fileBank",f:"getFolders",parentURI:e})}getDocuments(e){return this.network.post({o:"fileBank",f:"getDocuments",parentURI:e})}}class ue extends i{countAction(e,t){return this.network.post({o:"activityLog",f:"log",count:!0,verb:e,uri:t})}useWebVersion(){return this.network.post({o:"global",f:"useWebVersion"})}}var pe,me;class he extends i{autocomplete(e){return this.network.post({o:"autocomplete",f:"spot",q:e,idToUri:!1}).then((e=>e.result))}create(e,t){return this.network.post(Object.assign(Object.assign({o:"spot",f:"create"},e),{format:t}))}update(e,t){const{spotBanner:i}=e,n=function(e,t){var i={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(i[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var r=0;for(n=Object.getOwnPropertySymbols(e);r<n.length;r++)t.indexOf(n[r])<0&&Object.prototype.propertyIsEnumerable.call(e,n[r])&&(i[n[r]]=e[n[r]])}return i}(e,["spotBanner"]);return this.network.postCSRF(Object.assign(Object.assign({o:"spot",f:"update"},n),{format:t}))}getSpot(e,t){return this.network.post({o:"spot",f:"getSpot",idSpot:e,format:t})}getProperties(e){return this.network.post({o:"spot",f:"getProperties",idSpot:e})}getApplications(){return this.network.post({o:"spot",f:"get-available-widget"})}getCategories(){return this.network.post({o:"spot",f:"get-categories"})}getObjectListJamespotSpotMembers(e,t,i,n=1){return this.network.post({o:"objectListJamespot",f:"SpotMembers",idSpot:e,limit:i,page:n,format:"raw-little",query:t})}list(e){return this.network.post(Object.assign({o:"objectList",f:"jamespotSpotQueryList"},e))}resetNotifications(e){return this.network.post(Object.assign({o:"spot",f:"resetNotifications"},e))}getUserLevelAndRight(e){return this.network.post({o:"spot",f:"getUserLevelAndRight",idSpot:e})}groupRequest(e){return this.network.postCSRF({o:"spot",f:"request",idSpot:e})}groupAddToFavorite(e){return this.network.postCSRF({o:"spot",f:"addToFavorite",idSpot:e})}}!function(e){e.assertEqual=e=>e,e.assertIs=function(e){},e.assertNever=function(e){throw new Error},e.arrayToEnum=e=>{const t={};for(const i of e)t[i]=i;return t},e.getValidEnumValues=t=>{const i=e.objectKeys(t).filter((e=>"number"!=typeof t[t[e]])),n={};for(const e of i)n[e]=t[e];return e.objectValues(n)},e.objectValues=t=>e.objectKeys(t).map((function(e){return t[e]})),e.objectKeys="function"==typeof Object.keys?e=>Object.keys(e):e=>{const t=[];for(const i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.push(i);return t},e.find=(e,t)=>{for(const i of e)if(t(i))return i},e.isInteger="function"==typeof Number.isInteger?e=>Number.isInteger(e):e=>"number"==typeof e&&isFinite(e)&&Math.floor(e)===e,e.joinValues=function(e,t=" | "){return e.map((e=>"string"==typeof e?`'${e}'`:e)).join(t)},e.jsonStringifyReplacer=(e,t)=>"bigint"==typeof t?t.toString():t}(pe||(pe={})),function(e){e.mergeShapes=(e,t)=>({...e,...t})}(me||(me={}));const fe=pe.arrayToEnum(["string","nan","number","integer","float","boolean","date","bigint","symbol","function","undefined","null","array","object","unknown","promise","void","never","map","set"]),ge=e=>{switch(typeof e){case"undefined":return fe.undefined;case"string":return fe.string;case"number":return isNaN(e)?fe.nan:fe.number;case"boolean":return fe.boolean;case"function":return fe.function;case"bigint":return fe.bigint;case"symbol":return fe.symbol;case"object":return Array.isArray(e)?fe.array:null===e?fe.null:e.then&&"function"==typeof e.then&&e.catch&&"function"==typeof e.catch?fe.promise:"undefined"!=typeof Map&&e instanceof Map?fe.map:"undefined"!=typeof Set&&e instanceof Set?fe.set:"undefined"!=typeof Date&&e instanceof Date?fe.date:fe.object;default:return fe.unknown}},ye=pe.arrayToEnum(["invalid_type","invalid_literal","custom","invalid_union","invalid_union_discriminator","invalid_enum_value","unrecognized_keys","invalid_arguments","invalid_return_type","invalid_date","invalid_string","too_small","too_big","invalid_intersection_types","not_multiple_of","not_finite"]);class be extends Error{constructor(e){super(),this.issues=[],this.addIssue=e=>{this.issues=[...this.issues,e]},this.addIssues=(e=[])=>{this.issues=[...this.issues,...e]};const t=new.target.prototype;Object.setPrototypeOf?Object.setPrototypeOf(this,t):this.__proto__=t,this.name="ZodError",this.issues=e}get errors(){return this.issues}format(e){const t=e||function(e){return e.message},i={_errors:[]},n=e=>{for(const r of e.issues)if("invalid_union"===r.code)r.unionErrors.map(n);else if("invalid_return_type"===r.code)n(r.returnTypeError);else if("invalid_arguments"===r.code)n(r.argumentsError);else if(0===r.path.length)i._errors.push(t(r));else{let e=i,n=0;for(;n<r.path.length;){const i=r.path[n];n===r.path.length-1?(e[i]=e[i]||{_errors:[]},e[i]._errors.push(t(r))):e[i]=e[i]||{_errors:[]},e=e[i],n++}}};return n(this),i}toString(){return this.message}get message(){return JSON.stringify(this.issues,pe.jsonStringifyReplacer,2)}get isEmpty(){return 0===this.issues.length}flatten(e=(e=>e.message)){const t={},i=[];for(const n of this.issues)n.path.length>0?(t[n.path[0]]=t[n.path[0]]||[],t[n.path[0]].push(e(n))):i.push(e(n));return{formErrors:i,fieldErrors:t}}get formErrors(){return this.flatten()}}be.create=e=>new be(e);const ve=(e,t)=>{let i;switch(e.code){case ye.invalid_type:i=e.received===fe.undefined?"Required":`Expected ${e.expected}, received ${e.received}`;break;case ye.invalid_literal:i=`Invalid literal value, expected ${JSON.stringify(e.expected,pe.jsonStringifyReplacer)}`;break;case ye.unrecognized_keys:i=`Unrecognized key(s) in object: ${pe.joinValues(e.keys,", ")}`;break;case ye.invalid_union:i="Invalid input";break;case ye.invalid_union_discriminator:i=`Invalid discriminator value. Expected ${pe.joinValues(e.options)}`;break;case ye.invalid_enum_value:i=`Invalid enum value. Expected ${pe.joinValues(e.options)}, received '${e.received}'`;break;case ye.invalid_arguments:i="Invalid function arguments";break;case ye.invalid_return_type:i="Invalid function return type";break;case ye.invalid_date:i="Invalid date";break;case ye.invalid_string:"object"==typeof e.validation?"includes"in e.validation?(i=`Invalid input: must include "${e.validation.includes}"`,"number"==typeof e.validation.position&&(i=`${i} at one or more positions greater than or equal to ${e.validation.position}`)):"startsWith"in e.validation?i=`Invalid input: must start with "${e.validation.startsWith}"`:"endsWith"in e.validation?i=`Invalid input: must end with "${e.validation.endsWith}"`:pe.assertNever(e.validation):i="regex"!==e.validation?`Invalid ${e.validation}`:"Invalid";break;case ye.too_small:i="array"===e.type?`Array must contain ${e.exact?"exactly":e.inclusive?"at least":"more than"} ${e.minimum} element(s)`:"string"===e.type?`String must contain ${e.exact?"exactly":e.inclusive?"at least":"over"} ${e.minimum} character(s)`:"number"===e.type?`Number must be ${e.exact?"exactly equal to ":e.inclusive?"greater than or equal to ":"greater than "}${e.minimum}`:"date"===e.type?`Date must be ${e.exact?"exactly equal to ":e.inclusive?"greater than or equal to ":"greater than "}${new Date(Number(e.minimum))}`:"Invalid input";break;case ye.too_big:i="array"===e.type?`Array must contain ${e.exact?"exactly":e.inclusive?"at most":"less than"} ${e.maximum} element(s)`:"string"===e.type?`String must contain ${e.exact?"exactly":e.inclusive?"at most":"under"} ${e.maximum} character(s)`:"number"===e.type?`Number must be ${e.exact?"exactly":e.inclusive?"less than or equal to":"less than"} ${e.maximum}`:"bigint"===e.type?`BigInt must be ${e.exact?"exactly":e.inclusive?"less than or equal to":"less than"} ${e.maximum}`:"date"===e.type?`Date must be ${e.exact?"exactly":e.inclusive?"smaller than or equal to":"smaller than"} ${new Date(Number(e.maximum))}`:"Invalid input";break;case ye.custom:i="Invalid input";break;case ye.invalid_intersection_types:i="Intersection results could not be merged";break;case ye.not_multiple_of:i=`Number must be a multiple of ${e.multipleOf}`;break;case ye.not_finite:i="Number must be finite";break;default:i=t.defaultError,pe.assertNever(e)}return{message:i}};let we=ve;function _e(){return we}const ke=e=>{const{data:t,path:i,errorMaps:n,issueData:r}=e,s=[...i,...r.path||[]],a={...r,path:s};let o="";const c=n.filter((e=>!!e)).slice().reverse();for(const e of c)o=e(a,{data:t,defaultError:o}).message;return{...r,path:s,message:r.message||o}};function xe(e,t){const i=ke({issueData:t,data:e.data,path:e.path,errorMaps:[e.common.contextualErrorMap,e.schemaErrorMap,_e(),ve].filter((e=>!!e))});e.common.issues.push(i)}class je{constructor(){this.value="valid"}dirty(){"valid"===this.value&&(this.value="dirty")}abort(){"aborted"!==this.value&&(this.value="aborted")}static mergeArray(e,t){const i=[];for(const n of t){if("aborted"===n.status)return Se;"dirty"===n.status&&e.dirty(),i.push(n.value)}return{status:e.value,value:i}}static async mergeObjectAsync(e,t){const i=[];for(const e of t)i.push({key:await e.key,value:await e.value});return je.mergeObjectSync(e,i)}static mergeObjectSync(e,t){const i={};for(const n of t){const{key:t,value:r}=n;if("aborted"===t.status)return Se;if("aborted"===r.status)return Se;"dirty"===t.status&&e.dirty(),"dirty"===r.status&&e.dirty(),"__proto__"===t.value||void 0===r.value&&!n.alwaysSet||(i[t.value]=r.value)}return{status:e.value,value:i}}}const Se=Object.freeze({status:"aborted"}),Ae=e=>({status:"dirty",value:e}),Oe=e=>({status:"valid",value:e}),Te=e=>"aborted"===e.status,Ce=e=>"dirty"===e.status,Fe=e=>"valid"===e.status,Re=e=>"undefined"!=typeof Promise&&e instanceof Promise;var Le;!function(e){e.errToObj=e=>"string"==typeof e?{message:e}:e||{},e.toString=e=>"string"==typeof e?e:null==e?void 0:e.message}(Le||(Le={}));class Ee{constructor(e,t,i,n){this._cachedPath=[],this.parent=e,this.data=t,this._path=i,this._key=n}get path(){return this._cachedPath.length||(this._key instanceof Array?this._cachedPath.push(...this._path,...this._key):this._cachedPath.push(...this._path,this._key)),this._cachedPath}}const Pe=(e,t)=>{if(Fe(t))return{success:!0,data:t.value};if(!e.common.issues.length)throw new Error("Validation failed but no issues detected.");return{success:!1,get error(){if(this._error)return this._error;const t=new be(e.common.issues);return this._error=t,this._error}}};function Ze(e){if(!e)return{};const{errorMap:t,invalid_type_error:i,required_error:n,description:r}=e;if(t&&(i||n))throw new Error('Can\'t use "invalid_type_error" or "required_error" in conjunction with custom error map.');return t?{errorMap:t,description:r}:{errorMap:(e,t)=>"invalid_type"!==e.code?{message:t.defaultError}:void 0===t.data?{message:null!=n?n:t.defaultError}:{message:null!=i?i:t.defaultError},description:r}}class Ne{constructor(e){this.spa=this.safeParseAsync,this._def=e,this.parse=this.parse.bind(this),this.safeParse=this.safeParse.bind(this),this.parseAsync=this.parseAsync.bind(this),this.safeParseAsync=this.safeParseAsync.bind(this),this.spa=this.spa.bind(this),this.refine=this.refine.bind(this),this.refinement=this.refinement.bind(this),this.superRefine=this.superRefine.bind(this),this.optional=this.optional.bind(this),this.nullable=this.nullable.bind(this),this.nullish=this.nullish.bind(this),this.array=this.array.bind(this),this.promise=this.promise.bind(this),this.or=this.or.bind(this),this.and=this.and.bind(this),this.transform=this.transform.bind(this),this.brand=this.brand.bind(this),this.default=this.default.bind(this),this.catch=this.catch.bind(this),this.describe=this.describe.bind(this),this.pipe=this.pipe.bind(this),this.readonly=this.readonly.bind(this),this.isNullable=this.isNullable.bind(this),this.isOptional=this.isOptional.bind(this)}get description(){return this._def.description}_getType(e){return ge(e.data)}_getOrReturnCtx(e,t){return t||{common:e.parent.common,data:e.data,parsedType:ge(e.data),schemaErrorMap:this._def.errorMap,path:e.path,parent:e.parent}}_processInputParams(e){return{status:new je,ctx:{common:e.parent.common,data:e.data,parsedType:ge(e.data),schemaErrorMap:this._def.errorMap,path:e.path,parent:e.parent}}}_parseSync(e){const t=this._parse(e);if(Re(t))throw new Error("Synchronous parse encountered promise.");return t}_parseAsync(e){const t=this._parse(e);return Promise.resolve(t)}parse(e,t){const i=this.safeParse(e,t);if(i.success)return i.data;throw i.error}safeParse(e,t){var i;const n={common:{issues:[],async:null!==(i=null==t?void 0:t.async)&&void 0!==i&&i,contextualErrorMap:null==t?void 0:t.errorMap},path:(null==t?void 0:t.path)||[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:ge(e)},r=this._parseSync({data:e,path:n.path,parent:n});return Pe(n,r)}async parseAsync(e,t){const i=await this.safeParseAsync(e,t);if(i.success)return i.data;throw i.error}async safeParseAsync(e,t){const i={common:{issues:[],contextualErrorMap:null==t?void 0:t.errorMap,async:!0},path:(null==t?void 0:t.path)||[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:ge(e)},n=this._parse({data:e,path:i.path,parent:i}),r=await(Re(n)?n:Promise.resolve(n));return Pe(i,r)}refine(e,t){const i=e=>"string"==typeof t||void 0===t?{message:t}:"function"==typeof t?t(e):t;return this._refinement(((t,n)=>{const r=e(t),s=()=>n.addIssue({code:ye.custom,...i(t)});return"undefined"!=typeof Promise&&r instanceof Promise?r.then((e=>!!e||(s(),!1))):!!r||(s(),!1)}))}refinement(e,t){return this._refinement(((i,n)=>!!e(i)||(n.addIssue("function"==typeof t?t(i,n):t),!1)))}_refinement(e){return new xt({schema:this,typeName:Zt.ZodEffects,effect:{type:"refinement",refinement:e}})}superRefine(e){return this._refinement(e)}optional(){return jt.create(this,this._def)}nullable(){return St.create(this,this._def)}nullish(){return this.nullable().optional()}array(){return rt.create(this,this._def)}promise(){return kt.create(this,this._def)}or(e){return ot.create([this,e],this._def)}and(e){return ut.create(this,e,this._def)}transform(e){return new xt({...Ze(this._def),schema:this,typeName:Zt.ZodEffects,effect:{type:"transform",transform:e}})}default(e){const t="function"==typeof e?e:()=>e;return new At({...Ze(this._def),innerType:this,defaultValue:t,typeName:Zt.ZodDefault})}brand(){return new Ft({typeName:Zt.ZodBranded,type:this,...Ze(this._def)})}catch(e){const t="function"==typeof e?e:()=>e;return new Ot({...Ze(this._def),innerType:this,catchValue:t,typeName:Zt.ZodCatch})}describe(e){return new(0,this.constructor)({...this._def,description:e})}pipe(e){return Rt.create(this,e)}readonly(){return Lt.create(this)}isOptional(){return this.safeParse(void 0).success}isNullable(){return this.safeParse(null).success}}const Ie=/^c[^\s-]{8,}$/i,Me=/^[a-z][a-z0-9]*$/,De=/^[0-9A-HJKMNP-TV-Z]{26}$/,Ue=/^[0-9a-fA-F]{8}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{12}$/i,We=/^(?!\.)(?!.*\.\.)([A-Z0-9_+-\.]*)[A-Z0-9_+-]@([A-Z0-9][A-Z0-9\-]*\.)+[A-Z]{2,}$/i;let $e;const qe=/^(((25[0-5])|(2[0-4][0-9])|(1[0-9]{2})|([0-9]{1,2}))\.){3}((25[0-5])|(2[0-4][0-9])|(1[0-9]{2})|([0-9]{1,2}))$/,Be=/^(([a-f0-9]{1,4}:){7}|::([a-f0-9]{1,4}:){0,6}|([a-f0-9]{1,4}:){1}:([a-f0-9]{1,4}:){0,5}|([a-f0-9]{1,4}:){2}:([a-f0-9]{1,4}:){0,4}|([a-f0-9]{1,4}:){3}:([a-f0-9]{1,4}:){0,3}|([a-f0-9]{1,4}:){4}:([a-f0-9]{1,4}:){0,2}|([a-f0-9]{1,4}:){5}:([a-f0-9]{1,4}:){0,1})([a-f0-9]{1,4}|(((25[0-5])|(2[0-4][0-9])|(1[0-9]{2})|([0-9]{1,2}))\.){3}((25[0-5])|(2[0-4][0-9])|(1[0-9]{2})|([0-9]{1,2})))$/;class ze extends Ne{_parse(e){if(this._def.coerce&&(e.data=String(e.data)),this._getType(e)!==fe.string){const t=this._getOrReturnCtx(e);return xe(t,{code:ye.invalid_type,expected:fe.string,received:t.parsedType}),Se}const t=new je;let i;for(const a of this._def.checks)if("min"===a.kind)e.data.length<a.value&&(i=this._getOrReturnCtx(e,i),xe(i,{code:ye.too_small,minimum:a.value,type:"string",inclusive:!0,exact:!1,message:a.message}),t.dirty());else if("max"===a.kind)e.data.length>a.value&&(i=this._getOrReturnCtx(e,i),xe(i,{code:ye.too_big,maximum:a.value,type:"string",inclusive:!0,exact:!1,message:a.message}),t.dirty());else if("length"===a.kind){const n=e.data.length>a.value,r=e.data.length<a.value;(n||r)&&(i=this._getOrReturnCtx(e,i),n?xe(i,{code:ye.too_big,maximum:a.value,type:"string",inclusive:!0,exact:!0,message:a.message}):r&&xe(i,{code:ye.too_small,minimum:a.value,type:"string",inclusive:!0,exact:!0,message:a.message}),t.dirty())}else if("email"===a.kind)We.test(e.data)||(i=this._getOrReturnCtx(e,i),xe(i,{validation:"email",code:ye.invalid_string,message:a.message}),t.dirty());else if("emoji"===a.kind)$e||($e=new RegExp("^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$","u")),$e.test(e.data)||(i=this._getOrReturnCtx(e,i),xe(i,{validation:"emoji",code:ye.invalid_string,message:a.message}),t.dirty());else if("uuid"===a.kind)Ue.test(e.data)||(i=this._getOrReturnCtx(e,i),xe(i,{validation:"uuid",code:ye.invalid_string,message:a.message}),t.dirty());else if("cuid"===a.kind)Ie.test(e.data)||(i=this._getOrReturnCtx(e,i),xe(i,{validation:"cuid",code:ye.invalid_string,message:a.message}),t.dirty());else if("cuid2"===a.kind)Me.test(e.data)||(i=this._getOrReturnCtx(e,i),xe(i,{validation:"cuid2",code:ye.invalid_string,message:a.message}),t.dirty());else if("ulid"===a.kind)De.test(e.data)||(i=this._getOrReturnCtx(e,i),xe(i,{validation:"ulid",code:ye.invalid_string,message:a.message}),t.dirty());else if("url"===a.kind)try{new URL(e.data)}catch(n){i=this._getOrReturnCtx(e,i),xe(i,{validation:"url",code:ye.invalid_string,message:a.message}),t.dirty()}else"regex"===a.kind?(a.regex.lastIndex=0,a.regex.test(e.data)||(i=this._getOrReturnCtx(e,i),xe(i,{validation:"regex",code:ye.invalid_string,message:a.message}),t.dirty())):"trim"===a.kind?e.data=e.data.trim():"includes"===a.kind?e.data.includes(a.value,a.position)||(i=this._getOrReturnCtx(e,i),xe(i,{code:ye.invalid_string,validation:{includes:a.value,position:a.position},message:a.message}),t.dirty()):"toLowerCase"===a.kind?e.data=e.data.toLowerCase():"toUpperCase"===a.kind?e.data=e.data.toUpperCase():"startsWith"===a.kind?e.data.startsWith(a.value)||(i=this._getOrReturnCtx(e,i),xe(i,{code:ye.invalid_string,validation:{startsWith:a.value},message:a.message}),t.dirty()):"endsWith"===a.kind?e.data.endsWith(a.value)||(i=this._getOrReturnCtx(e,i),xe(i,{code:ye.invalid_string,validation:{endsWith:a.value},message:a.message}),t.dirty()):"datetime"===a.kind?((s=a).precision?s.offset?new RegExp(`^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}\\.\\d{${s.precision}}(([+-]\\d{2}(:?\\d{2})?)|Z)$`):new RegExp(`^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}\\.\\d{${s.precision}}Z$`):0===s.precision?s.offset?new RegExp("^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(([+-]\\d{2}(:?\\d{2})?)|Z)$"):new RegExp("^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}Z$"):s.offset?new RegExp("^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(\\.\\d+)?(([+-]\\d{2}(:?\\d{2})?)|Z)$"):new RegExp("^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(\\.\\d+)?Z$")).test(e.data)||(i=this._getOrReturnCtx(e,i),xe(i,{code:ye.invalid_string,validation:"datetime",message:a.message}),t.dirty()):"ip"===a.kind?(n=e.data,("v4"!==(r=a.version)&&r||!qe.test(n))&&("v6"!==r&&r||!Be.test(n))&&(i=this._getOrReturnCtx(e,i),xe(i,{validation:"ip",code:ye.invalid_string,message:a.message}),t.dirty())):pe.assertNever(a);var n,r,s;return{status:t.value,value:e.data}}_regex(e,t,i){return this.refinement((t=>e.test(t)),{validation:t,code:ye.invalid_string,...Le.errToObj(i)})}_addCheck(e){return new ze({...this._def,checks:[...this._def.checks,e]})}email(e){return this._addCheck({kind:"email",...Le.errToObj(e)})}url(e){return this._addCheck({kind:"url",...Le.errToObj(e)})}emoji(e){return this._addCheck({kind:"emoji",...Le.errToObj(e)})}uuid(e){return this._addCheck({kind:"uuid",...Le.errToObj(e)})}cuid(e){return this._addCheck({kind:"cuid",...Le.errToObj(e)})}cuid2(e){return this._addCheck({kind:"cuid2",...Le.errToObj(e)})}ulid(e){return this._addCheck({kind:"ulid",...Le.errToObj(e)})}ip(e){return this._addCheck({kind:"ip",...Le.errToObj(e)})}datetime(e){var t;return"string"==typeof e?this._addCheck({kind:"datetime",precision:null,offset:!1,message:e}):this._addCheck({kind:"datetime",precision:void 0===(null==e?void 0:e.precision)?null:null==e?void 0:e.precision,offset:null!==(t=null==e?void 0:e.offset)&&void 0!==t&&t,...Le.errToObj(null==e?void 0:e.message)})}regex(e,t){return this._addCheck({kind:"regex",regex:e,...Le.errToObj(t)})}includes(e,t){return this._addCheck({kind:"includes",value:e,position:null==t?void 0:t.position,...Le.errToObj(null==t?void 0:t.message)})}startsWith(e,t){return this._addCheck({kind:"startsWith",value:e,...Le.errToObj(t)})}endsWith(e,t){return this._addCheck({kind:"endsWith",value:e,...Le.errToObj(t)})}min(e,t){return this._addCheck({kind:"min",value:e,...Le.errToObj(t)})}max(e,t){return this._addCheck({kind:"max",value:e,...Le.errToObj(t)})}length(e,t){return this._addCheck({kind:"length",value:e,...Le.errToObj(t)})}nonempty(e){return this.min(1,Le.errToObj(e))}trim(){return new ze({...this._def,checks:[...this._def.checks,{kind:"trim"}]})}toLowerCase(){return new ze({...this._def,checks:[...this._def.checks,{kind:"toLowerCase"}]})}toUpperCase(){return new ze({...this._def,checks:[...this._def.checks,{kind:"toUpperCase"}]})}get isDatetime(){return!!this._def.checks.find((e=>"datetime"===e.kind))}get isEmail(){return!!this._def.checks.find((e=>"email"===e.kind))}get isURL(){return!!this._def.checks.find((e=>"url"===e.kind))}get isEmoji(){return!!this._def.checks.find((e=>"emoji"===e.kind))}get isUUID(){return!!this._def.checks.find((e=>"uuid"===e.kind))}get isCUID(){return!!this._def.checks.find((e=>"cuid"===e.kind))}get isCUID2(){return!!this._def.checks.find((e=>"cuid2"===e.kind))}get isULID(){return!!this._def.checks.find((e=>"ulid"===e.kind))}get isIP(){return!!this._def.checks.find((e=>"ip"===e.kind))}get minLength(){let e=null;for(const t of this._def.checks)"min"===t.kind&&(null===e||t.value>e)&&(e=t.value);return e}get maxLength(){let e=null;for(const t of this._def.checks)"max"===t.kind&&(null===e||t.value<e)&&(e=t.value);return e}}function Ve(e,t){const i=(e.toString().split(".")[1]||"").length,n=(t.toString().split(".")[1]||"").length,r=i>n?i:n;return parseInt(e.toFixed(r).replace(".",""))%parseInt(t.toFixed(r).replace(".",""))/Math.pow(10,r)}ze.create=e=>{var t;return new ze({checks:[],typeName:Zt.ZodString,coerce:null!==(t=null==e?void 0:e.coerce)&&void 0!==t&&t,...Ze(e)})};class Je extends Ne{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte,this.step=this.multipleOf}_parse(e){if(this._def.coerce&&(e.data=Number(e.data)),this._getType(e)!==fe.number){const t=this._getOrReturnCtx(e);return xe(t,{code:ye.invalid_type,expected:fe.number,received:t.parsedType}),Se}let t;const i=new je;for(const n of this._def.checks)"int"===n.kind?pe.isInteger(e.data)||(t=this._getOrReturnCtx(e,t),xe(t,{code:ye.invalid_type,expected:"integer",received:"float",message:n.message}),i.dirty()):"min"===n.kind?(n.inclusive?e.data<n.value:e.data<=n.value)&&(t=this._getOrReturnCtx(e,t),xe(t,{code:ye.too_small,minimum:n.value,type:"number",inclusive:n.inclusive,exact:!1,message:n.message}),i.dirty()):"max"===n.kind?(n.inclusive?e.data>n.value:e.data>=n.value)&&(t=this._getOrReturnCtx(e,t),xe(t,{code:ye.too_big,maximum:n.value,type:"number",inclusive:n.inclusive,exact:!1,message:n.message}),i.dirty()):"multipleOf"===n.kind?0!==Ve(e.data,n.value)&&(t=this._getOrReturnCtx(e,t),xe(t,{code:ye.not_multiple_of,multipleOf:n.value,message:n.message}),i.dirty()):"finite"===n.kind?Number.isFinite(e.data)||(t=this._getOrReturnCtx(e,t),xe(t,{code:ye.not_finite,message:n.message}),i.dirty()):pe.assertNever(n);return{status:i.value,value:e.data}}gte(e,t){return this.setLimit("min",e,!0,Le.toString(t))}gt(e,t){return this.setLimit("min",e,!1,Le.toString(t))}lte(e,t){return this.setLimit("max",e,!0,Le.toString(t))}lt(e,t){return this.setLimit("max",e,!1,Le.toString(t))}setLimit(e,t,i,n){return new Je({...this._def,checks:[...this._def.checks,{kind:e,value:t,inclusive:i,message:Le.toString(n)}]})}_addCheck(e){return new Je({...this._def,checks:[...this._def.checks,e]})}int(e){return this._addCheck({kind:"int",message:Le.toString(e)})}positive(e){return this._addCheck({kind:"min",value:0,inclusive:!1,message:Le.toString(e)})}negative(e){return this._addCheck({kind:"max",value:0,inclusive:!1,message:Le.toString(e)})}nonpositive(e){return this._addCheck({kind:"max",value:0,inclusive:!0,message:Le.toString(e)})}nonnegative(e){return this._addCheck({kind:"min",value:0,inclusive:!0,message:Le.toString(e)})}multipleOf(e,t){return this._addCheck({kind:"multipleOf",value:e,message:Le.toString(t)})}finite(e){return this._addCheck({kind:"finite",message:Le.toString(e)})}safe(e){return this._addCheck({kind:"min",inclusive:!0,value:Number.MIN_SAFE_INTEGER,message:Le.toString(e)})._addCheck({kind:"max",inclusive:!0,value:Number.MAX_SAFE_INTEGER,message:Le.toString(e)})}get minValue(){let e=null;for(const t of this._def.checks)"min"===t.kind&&(null===e||t.value>e)&&(e=t.value);return e}get maxValue(){let e=null;for(const t of this._def.checks)"max"===t.kind&&(null===e||t.value<e)&&(e=t.value);return e}get isInt(){return!!this._def.checks.find((e=>"int"===e.kind||"multipleOf"===e.kind&&pe.isInteger(e.value)))}get isFinite(){let e=null,t=null;for(const i of this._def.checks){if("finite"===i.kind||"int"===i.kind||"multipleOf"===i.kind)return!0;"min"===i.kind?(null===t||i.value>t)&&(t=i.value):"max"===i.kind&&(null===e||i.value<e)&&(e=i.value)}return Number.isFinite(t)&&Number.isFinite(e)}}Je.create=e=>new Je({checks:[],typeName:Zt.ZodNumber,coerce:(null==e?void 0:e.coerce)||!1,...Ze(e)});class Ke extends Ne{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte}_parse(e){if(this._def.coerce&&(e.data=BigInt(e.data)),this._getType(e)!==fe.bigint){const t=this._getOrReturnCtx(e);return xe(t,{code:ye.invalid_type,expected:fe.bigint,received:t.parsedType}),Se}let t;const i=new je;for(const n of this._def.checks)"min"===n.kind?(n.inclusive?e.data<n.value:e.data<=n.value)&&(t=this._getOrReturnCtx(e,t),xe(t,{code:ye.too_small,type:"bigint",minimum:n.value,inclusive:n.inclusive,message:n.message}),i.dirty()):"max"===n.kind?(n.inclusive?e.data>n.value:e.data>=n.value)&&(t=this._getOrReturnCtx(e,t),xe(t,{code:ye.too_big,type:"bigint",maximum:n.value,inclusive:n.inclusive,message:n.message}),i.dirty()):"multipleOf"===n.kind?e.data%n.value!==BigInt(0)&&(t=this._getOrReturnCtx(e,t),xe(t,{code:ye.not_multiple_of,multipleOf:n.value,message:n.message}),i.dirty()):pe.assertNever(n);return{status:i.value,value:e.data}}gte(e,t){return this.setLimit("min",e,!0,Le.toString(t))}gt(e,t){return this.setLimit("min",e,!1,Le.toString(t))}lte(e,t){return this.setLimit("max",e,!0,Le.toString(t))}lt(e,t){return this.setLimit("max",e,!1,Le.toString(t))}setLimit(e,t,i,n){return new Ke({...this._def,checks:[...this._def.checks,{kind:e,value:t,inclusive:i,message:Le.toString(n)}]})}_addCheck(e){return new Ke({...this._def,checks:[...this._def.checks,e]})}positive(e){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!1,message:Le.toString(e)})}negative(e){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!1,message:Le.toString(e)})}nonpositive(e){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!0,message:Le.toString(e)})}nonnegative(e){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!0,message:Le.toString(e)})}multipleOf(e,t){return this._addCheck({kind:"multipleOf",value:e,message:Le.toString(t)})}get minValue(){let e=null;for(const t of this._def.checks)"min"===t.kind&&(null===e||t.value>e)&&(e=t.value);return e}get maxValue(){let e=null;for(const t of this._def.checks)"max"===t.kind&&(null===e||t.value<e)&&(e=t.value);return e}}Ke.create=e=>{var t;return new Ke({checks:[],typeName:Zt.ZodBigInt,coerce:null!==(t=null==e?void 0:e.coerce)&&void 0!==t&&t,...Ze(e)})};class Ge extends Ne{_parse(e){if(this._def.coerce&&(e.data=Boolean(e.data)),this._getType(e)!==fe.boolean){const t=this._getOrReturnCtx(e);return xe(t,{code:ye.invalid_type,expected:fe.boolean,received:t.parsedType}),Se}return Oe(e.data)}}Ge.create=e=>new Ge({typeName:Zt.ZodBoolean,coerce:(null==e?void 0:e.coerce)||!1,...Ze(e)});class He extends Ne{_parse(e){if(this._def.coerce&&(e.data=new Date(e.data)),this._getType(e)!==fe.date){const t=this._getOrReturnCtx(e);return xe(t,{code:ye.invalid_type,expected:fe.date,received:t.parsedType}),Se}if(isNaN(e.data.getTime()))return xe(this._getOrReturnCtx(e),{code:ye.invalid_date}),Se;const t=new je;let i;for(const n of this._def.checks)"min"===n.kind?e.data.getTime()<n.value&&(i=this._getOrReturnCtx(e,i),xe(i,{code:ye.too_small,message:n.message,inclusive:!0,exact:!1,minimum:n.value,type:"date"}),t.dirty()):"max"===n.kind?e.data.getTime()>n.value&&(i=this._getOrReturnCtx(e,i),xe(i,{code:ye.too_big,message:n.message,inclusive:!0,exact:!1,maximum:n.value,type:"date"}),t.dirty()):pe.assertNever(n);return{status:t.value,value:new Date(e.data.getTime())}}_addCheck(e){return new He({...this._def,checks:[...this._def.checks,e]})}min(e,t){return this._addCheck({kind:"min",value:e.getTime(),message:Le.toString(t)})}max(e,t){return this._addCheck({kind:"max",value:e.getTime(),message:Le.toString(t)})}get minDate(){let e=null;for(const t of this._def.checks)"min"===t.kind&&(null===e||t.value>e)&&(e=t.value);return null!=e?new Date(e):null}get maxDate(){let e=null;for(const t of this._def.checks)"max"===t.kind&&(null===e||t.value<e)&&(e=t.value);return null!=e?new Date(e):null}}He.create=e=>new He({checks:[],coerce:(null==e?void 0:e.coerce)||!1,typeName:Zt.ZodDate,...Ze(e)});class Qe extends Ne{_parse(e){if(this._getType(e)!==fe.symbol){const t=this._getOrReturnCtx(e);return xe(t,{code:ye.invalid_type,expected:fe.symbol,received:t.parsedType}),Se}return Oe(e.data)}}Qe.create=e=>new Qe({typeName:Zt.ZodSymbol,...Ze(e)});class Ye extends Ne{_parse(e){if(this._getType(e)!==fe.undefined){const t=this._getOrReturnCtx(e);return xe(t,{code:ye.invalid_type,expected:fe.undefined,received:t.parsedType}),Se}return Oe(e.data)}}Ye.create=e=>new Ye({typeName:Zt.ZodUndefined,...Ze(e)});class Xe extends Ne{_parse(e){if(this._getType(e)!==fe.null){const t=this._getOrReturnCtx(e);return xe(t,{code:ye.invalid_type,expected:fe.null,received:t.parsedType}),Se}return Oe(e.data)}}Xe.create=e=>new Xe({typeName:Zt.ZodNull,...Ze(e)});class et extends Ne{constructor(){super(...arguments),this._any=!0}_parse(e){return Oe(e.data)}}et.create=e=>new et({typeName:Zt.ZodAny,...Ze(e)});class tt extends Ne{constructor(){super(...arguments),this._unknown=!0}_parse(e){return Oe(e.data)}}tt.create=e=>new tt({typeName:Zt.ZodUnknown,...Ze(e)});class it extends Ne{_parse(e){const t=this._getOrReturnCtx(e);return xe(t,{code:ye.invalid_type,expected:fe.never,received:t.parsedType}),Se}}it.create=e=>new it({typeName:Zt.ZodNever,...Ze(e)});class nt extends Ne{_parse(e){if(this._getType(e)!==fe.undefined){const t=this._getOrReturnCtx(e);return xe(t,{code:ye.invalid_type,expected:fe.void,received:t.parsedType}),Se}return Oe(e.data)}}nt.create=e=>new nt({typeName:Zt.ZodVoid,...Ze(e)});class rt extends Ne{_parse(e){const{ctx:t,status:i}=this._processInputParams(e),n=this._def;if(t.parsedType!==fe.array)return xe(t,{code:ye.invalid_type,expected:fe.array,received:t.parsedType}),Se;if(null!==n.exactLength){const e=t.data.length>n.exactLength.value,r=t.data.length<n.exactLength.value;(e||r)&&(xe(t,{code:e?ye.too_big:ye.too_small,minimum:r?n.exactLength.value:void 0,maximum:e?n.exactLength.value:void 0,type:"array",inclusive:!0,exact:!0,message:n.exactLength.message}),i.dirty())}if(null!==n.minLength&&t.data.length<n.minLength.value&&(xe(t,{code:ye.too_small,minimum:n.minLength.value,type:"array",inclusive:!0,exact:!1,message:n.minLength.message}),i.dirty()),null!==n.maxLength&&t.data.length>n.maxLength.value&&(xe(t,{code:ye.too_big,maximum:n.maxLength.value,type:"array",inclusive:!0,exact:!1,message:n.maxLength.message}),i.dirty()),t.common.async)return Promise.all([...t.data].map(((e,i)=>n.type._parseAsync(new Ee(t,e,t.path,i))))).then((e=>je.mergeArray(i,e)));const r=[...t.data].map(((e,i)=>n.type._parseSync(new Ee(t,e,t.path,i))));return je.mergeArray(i,r)}get element(){return this._def.type}min(e,t){return new rt({...this._def,minLength:{value:e,message:Le.toString(t)}})}max(e,t){return new rt({...this._def,maxLength:{value:e,message:Le.toString(t)}})}length(e,t){return new rt({...this._def,exactLength:{value:e,message:Le.toString(t)}})}nonempty(e){return this.min(1,e)}}function st(e){if(e instanceof at){const t={};for(const i in e.shape){const n=e.shape[i];t[i]=jt.create(st(n))}return new at({...e._def,shape:()=>t})}return e instanceof rt?new rt({...e._def,type:st(e.element)}):e instanceof jt?jt.create(st(e.unwrap())):e instanceof St?St.create(st(e.unwrap())):e instanceof pt?pt.create(e.items.map((e=>st(e)))):e}rt.create=(e,t)=>new rt({type:e,minLength:null,maxLength:null,exactLength:null,typeName:Zt.ZodArray,...Ze(t)});class at extends Ne{constructor(){super(...arguments),this._cached=null,this.nonstrict=this.passthrough,this.augment=this.extend}_getCached(){if(null!==this._cached)return this._cached;const e=this._def.shape(),t=pe.objectKeys(e);return this._cached={shape:e,keys:t}}_parse(e){if(this._getType(e)!==fe.object){const t=this._getOrReturnCtx(e);return xe(t,{code:ye.invalid_type,expected:fe.object,received:t.parsedType}),Se}const{status:t,ctx:i}=this._processInputParams(e),{shape:n,keys:r}=this._getCached(),s=[];if(!(this._def.catchall instanceof it&&"strip"===this._def.unknownKeys))for(const e in i.data)r.includes(e)||s.push(e);const a=[];for(const e of r){const t=n[e],r=i.data[e];a.push({key:{status:"valid",value:e},value:t._parse(new Ee(i,r,i.path,e)),alwaysSet:e in i.data})}if(this._def.catchall instanceof it){const e=this._def.unknownKeys;if("passthrough"===e)for(const e of s)a.push({key:{status:"valid",value:e},value:{status:"valid",value:i.data[e]}});else if("strict"===e)s.length>0&&(xe(i,{code:ye.unrecognized_keys,keys:s}),t.dirty());else if("strip"!==e)throw new Error("Internal ZodObject error: invalid unknownKeys value.")}else{const e=this._def.catchall;for(const t of s){const n=i.data[t];a.push({key:{status:"valid",value:t},value:e._parse(new Ee(i,n,i.path,t)),alwaysSet:t in i.data})}}return i.common.async?Promise.resolve().then((async()=>{const e=[];for(const t of a){const i=await t.key;e.push({key:i,value:await t.value,alwaysSet:t.alwaysSet})}return e})).then((e=>je.mergeObjectSync(t,e))):je.mergeObjectSync(t,a)}get shape(){return this._def.shape()}strict(e){return Le.errToObj,new at({...this._def,unknownKeys:"strict",...void 0!==e?{errorMap:(t,i)=>{var n,r,s,a;const o=null!==(s=null===(r=(n=this._def).errorMap)||void 0===r?void 0:r.call(n,t,i).message)&&void 0!==s?s:i.defaultError;return"unrecognized_keys"===t.code?{message:null!==(a=Le.errToObj(e).message)&&void 0!==a?a:o}:{message:o}}}:{}})}strip(){return new at({...this._def,unknownKeys:"strip"})}passthrough(){return new at({...this._def,unknownKeys:"passthrough"})}extend(e){return new at({...this._def,shape:()=>({...this._def.shape(),...e})})}merge(e){return new at({unknownKeys:e._def.unknownKeys,catchall:e._def.catchall,shape:()=>({...this._def.shape(),...e._def.shape()}),typeName:Zt.ZodObject})}setKey(e,t){return this.augment({[e]:t})}catchall(e){return new at({...this._def,catchall:e})}pick(e){const t={};return pe.objectKeys(e).forEach((i=>{e[i]&&this.shape[i]&&(t[i]=this.shape[i])})),new at({...this._def,shape:()=>t})}omit(e){const t={};return pe.objectKeys(this.shape).forEach((i=>{e[i]||(t[i]=this.shape[i])})),new at({...this._def,shape:()=>t})}deepPartial(){return st(this)}partial(e){const t={};return pe.objectKeys(this.shape).forEach((i=>{const n=this.shape[i];e&&!e[i]?t[i]=n:t[i]=n.optional()})),new at({...this._def,shape:()=>t})}required(e){const t={};return pe.objectKeys(this.shape).forEach((i=>{if(e&&!e[i])t[i]=this.shape[i];else{let e=this.shape[i];for(;e instanceof jt;)e=e._def.innerType;t[i]=e}})),new at({...this._def,shape:()=>t})}keyof(){return vt(pe.objectKeys(this.shape))}}at.create=(e,t)=>new at({shape:()=>e,unknownKeys:"strip",catchall:it.create(),typeName:Zt.ZodObject,...Ze(t)}),at.strictCreate=(e,t)=>new at({shape:()=>e,unknownKeys:"strict",catchall:it.create(),typeName:Zt.ZodObject,...Ze(t)}),at.lazycreate=(e,t)=>new at({shape:e,unknownKeys:"strip",catchall:it.create(),typeName:Zt.ZodObject,...Ze(t)});class ot extends Ne{_parse(e){const{ctx:t}=this._processInputParams(e),i=this._def.options;if(t.common.async)return Promise.all(i.map((async e=>{const i={...t,common:{...t.common,issues:[]},parent:null};return{result:await e._parseAsync({data:t.data,path:t.path,parent:i}),ctx:i}}))).then((function(e){for(const t of e)if("valid"===t.result.status)return t.result;for(const i of e)if("dirty"===i.result.status)return t.common.issues.push(...i.ctx.common.issues),i.result;const i=e.map((e=>new be(e.ctx.common.issues)));return xe(t,{code:ye.invalid_union,unionErrors:i}),Se}));{let e;const n=[];for(const r of i){const i={...t,common:{...t.common,issues:[]},parent:null},s=r._parseSync({data:t.data,path:t.path,parent:i});if("valid"===s.status)return s;"dirty"!==s.status||e||(e={result:s,ctx:i}),i.common.issues.length&&n.push(i.common.issues)}if(e)return t.common.issues.push(...e.ctx.common.issues),e.result;const r=n.map((e=>new be(e)));return xe(t,{code:ye.invalid_union,unionErrors:r}),Se}}get options(){return this._def.options}}ot.create=(e,t)=>new ot({options:e,typeName:Zt.ZodUnion,...Ze(t)});const ct=e=>e instanceof yt?ct(e.schema):e instanceof xt?ct(e.innerType()):e instanceof bt?[e.value]:e instanceof wt?e.options:e instanceof _t?Object.keys(e.enum):e instanceof At?ct(e._def.innerType):e instanceof Ye?[void 0]:e instanceof Xe?[null]:null;class lt extends Ne{_parse(e){const{ctx:t}=this._processInputParams(e);if(t.parsedType!==fe.object)return xe(t,{code:ye.invalid_type,expected:fe.object,received:t.parsedType}),Se;const i=this.discriminator,n=t.data[i],r=this.optionsMap.get(n);return r?t.common.async?r._parseAsync({data:t.data,path:t.path,parent:t}):r._parseSync({data:t.data,path:t.path,parent:t}):(xe(t,{code:ye.invalid_union_discriminator,options:Array.from(this.optionsMap.keys()),path:[i]}),Se)}get discriminator(){return this._def.discriminator}get options(){return this._def.options}get optionsMap(){return this._def.optionsMap}static create(e,t,i){const n=new Map;for(const i of t){const t=ct(i.shape[e]);if(!t)throw new Error(`A discriminator value for key \`${e}\` could not be extracted from all schema options`);for(const r of t){if(n.has(r))throw new Error(`Discriminator property ${String(e)} has duplicate value ${String(r)}`);n.set(r,i)}}return new lt({typeName:Zt.ZodDiscriminatedUnion,discriminator:e,options:t,optionsMap:n,...Ze(i)})}}function dt(e,t){const i=ge(e),n=ge(t);if(e===t)return{valid:!0,data:e};if(i===fe.object&&n===fe.object){const i=pe.objectKeys(t),n=pe.objectKeys(e).filter((e=>-1!==i.indexOf(e))),r={...e,...t};for(const i of n){const n=dt(e[i],t[i]);if(!n.valid)return{valid:!1};r[i]=n.data}return{valid:!0,data:r}}if(i===fe.array&&n===fe.array){if(e.length!==t.length)return{valid:!1};const i=[];for(let n=0;n<e.length;n++){const r=dt(e[n],t[n]);if(!r.valid)return{valid:!1};i.push(r.data)}return{valid:!0,data:i}}return i===fe.date&&n===fe.date&&+e==+t?{valid:!0,data:e}:{valid:!1}}class ut extends Ne{_parse(e){const{status:t,ctx:i}=this._processInputParams(e),n=(e,n)=>{if(Te(e)||Te(n))return Se;const r=dt(e.value,n.value);return r.valid?((Ce(e)||Ce(n))&&t.dirty(),{status:t.value,value:r.data}):(xe(i,{code:ye.invalid_intersection_types}),Se)};return i.common.async?Promise.all([this._def.left._parseAsync({data:i.data,path:i.path,parent:i}),this._def.right._parseAsync({data:i.data,path:i.path,parent:i})]).then((([e,t])=>n(e,t))):n(this._def.left._parseSync({data:i.data,path:i.path,parent:i}),this._def.right._parseSync({data:i.data,path:i.path,parent:i}))}}ut.create=(e,t,i)=>new ut({left:e,right:t,typeName:Zt.ZodIntersection,...Ze(i)});class pt extends Ne{_parse(e){const{status:t,ctx:i}=this._processInputParams(e);if(i.parsedType!==fe.array)return xe(i,{code:ye.invalid_type,expected:fe.array,received:i.parsedType}),Se;if(i.data.length<this._def.items.length)return xe(i,{code:ye.too_small,minimum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),Se;!this._def.rest&&i.data.length>this._def.items.length&&(xe(i,{code:ye.too_big,maximum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),t.dirty());const n=[...i.data].map(((e,t)=>{const n=this._def.items[t]||this._def.rest;return n?n._parse(new Ee(i,e,i.path,t)):null})).filter((e=>!!e));return i.common.async?Promise.all(n).then((e=>je.mergeArray(t,e))):je.mergeArray(t,n)}get items(){return this._def.items}rest(e){return new pt({...this._def,rest:e})}}pt.create=(e,t)=>{if(!Array.isArray(e))throw new Error("You must pass an array of schemas to z.tuple([ ... ])");return new pt({items:e,typeName:Zt.ZodTuple,rest:null,...Ze(t)})};class mt extends Ne{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(e){const{status:t,ctx:i}=this._processInputParams(e);if(i.parsedType!==fe.object)return xe(i,{code:ye.invalid_type,expected:fe.object,received:i.parsedType}),Se;const n=[],r=this._def.keyType,s=this._def.valueType;for(const e in i.data)n.push({key:r._parse(new Ee(i,e,i.path,e)),value:s._parse(new Ee(i,i.data[e],i.path,e))});return i.common.async?je.mergeObjectAsync(t,n):je.mergeObjectSync(t,n)}get element(){return this._def.valueType}static create(e,t,i){return new mt(t instanceof Ne?{keyType:e,valueType:t,typeName:Zt.ZodRecord,...Ze(i)}:{keyType:ze.create(),valueType:e,typeName:Zt.ZodRecord,...Ze(t)})}}class ht extends Ne{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(e){const{status:t,ctx:i}=this._processInputParams(e);if(i.parsedType!==fe.map)return xe(i,{code:ye.invalid_type,expected:fe.map,received:i.parsedType}),Se;const n=this._def.keyType,r=this._def.valueType,s=[...i.data.entries()].map((([e,t],s)=>({key:n._parse(new Ee(i,e,i.path,[s,"key"])),value:r._parse(new Ee(i,t,i.path,[s,"value"]))})));if(i.common.async){const e=new Map;return Promise.resolve().then((async()=>{for(const i of s){const n=await i.key,r=await i.value;if("aborted"===n.status||"aborted"===r.status)return Se;"dirty"!==n.status&&"dirty"!==r.status||t.dirty(),e.set(n.value,r.value)}return{status:t.value,value:e}}))}{const e=new Map;for(const i of s){const n=i.key,r=i.value;if("aborted"===n.status||"aborted"===r.status)return Se;"dirty"!==n.status&&"dirty"!==r.status||t.dirty(),e.set(n.value,r.value)}return{status:t.value,value:e}}}}ht.create=(e,t,i)=>new ht({valueType:t,keyType:e,typeName:Zt.ZodMap,...Ze(i)});class ft extends Ne{_parse(e){const{status:t,ctx:i}=this._processInputParams(e);if(i.parsedType!==fe.set)return xe(i,{code:ye.invalid_type,expected:fe.set,received:i.parsedType}),Se;const n=this._def;null!==n.minSize&&i.data.size<n.minSize.value&&(xe(i,{code:ye.too_small,minimum:n.minSize.value,type:"set",inclusive:!0,exact:!1,message:n.minSize.message}),t.dirty()),null!==n.maxSize&&i.data.size>n.maxSize.value&&(xe(i,{code:ye.too_big,maximum:n.maxSize.value,type:"set",inclusive:!0,exact:!1,message:n.maxSize.message}),t.dirty());const r=this._def.valueType;function s(e){const i=new Set;for(const n of e){if("aborted"===n.status)return Se;"dirty"===n.status&&t.dirty(),i.add(n.value)}return{status:t.value,value:i}}const a=[...i.data.values()].map(((e,t)=>r._parse(new Ee(i,e,i.path,t))));return i.common.async?Promise.all(a).then((e=>s(e))):s(a)}min(e,t){return new ft({...this._def,minSize:{value:e,message:Le.toString(t)}})}max(e,t){return new ft({...this._def,maxSize:{value:e,message:Le.toString(t)}})}size(e,t){return this.min(e,t).max(e,t)}nonempty(e){return this.min(1,e)}}ft.create=(e,t)=>new ft({valueType:e,minSize:null,maxSize:null,typeName:Zt.ZodSet,...Ze(t)});class gt extends Ne{constructor(){super(...arguments),this.validate=this.implement}_parse(e){const{ctx:t}=this._processInputParams(e);if(t.parsedType!==fe.function)return xe(t,{code:ye.invalid_type,expected:fe.function,received:t.parsedType}),Se;function i(e,i){return ke({data:e,path:t.path,errorMaps:[t.common.contextualErrorMap,t.schemaErrorMap,_e(),ve].filter((e=>!!e)),issueData:{code:ye.invalid_arguments,argumentsError:i}})}function n(e,i){return ke({data:e,path:t.path,errorMaps:[t.common.contextualErrorMap,t.schemaErrorMap,_e(),ve].filter((e=>!!e)),issueData:{code:ye.invalid_return_type,returnTypeError:i}})}const r={errorMap:t.common.contextualErrorMap},s=t.data;if(this._def.returns instanceof kt){const e=this;return Oe((async function(...t){const a=new be([]),o=await e._def.args.parseAsync(t,r).catch((e=>{throw a.addIssue(i(t,e)),a})),c=await Reflect.apply(s,this,o);return await e._def.returns._def.type.parseAsync(c,r).catch((e=>{throw a.addIssue(n(c,e)),a}))}))}{const e=this;return Oe((function(...t){const a=e._def.args.safeParse(t,r);if(!a.success)throw new be([i(t,a.error)]);const o=Reflect.apply(s,this,a.data),c=e._def.returns.safeParse(o,r);if(!c.success)throw new be([n(o,c.error)]);return c.data}))}}parameters(){return this._def.args}returnType(){return this._def.returns}args(...e){return new gt({...this._def,args:pt.create(e).rest(tt.create())})}returns(e){return new gt({...this._def,returns:e})}implement(e){return this.parse(e)}strictImplement(e){return this.parse(e)}static create(e,t,i){return new gt({args:e||pt.create([]).rest(tt.create()),returns:t||tt.create(),typeName:Zt.ZodFunction,...Ze(i)})}}class yt extends Ne{get schema(){return this._def.getter()}_parse(e){const{ctx:t}=this._processInputParams(e);return this._def.getter()._parse({data:t.data,path:t.path,parent:t})}}yt.create=(e,t)=>new yt({getter:e,typeName:Zt.ZodLazy,...Ze(t)});class bt extends Ne{_parse(e){if(e.data!==this._def.value){const t=this._getOrReturnCtx(e);return xe(t,{received:t.data,code:ye.invalid_literal,expected:this._def.value}),Se}return{status:"valid",value:e.data}}get value(){return this._def.value}}function vt(e,t){return new wt({values:e,typeName:Zt.ZodEnum,...Ze(t)})}bt.create=(e,t)=>new bt({value:e,typeName:Zt.ZodLiteral,...Ze(t)});class wt extends Ne{_parse(e){if("string"!=typeof e.data){const t=this._getOrReturnCtx(e),i=this._def.values;return xe(t,{expected:pe.joinValues(i),received:t.parsedType,code:ye.invalid_type}),Se}if(-1===this._def.values.indexOf(e.data)){const t=this._getOrReturnCtx(e),i=this._def.values;return xe(t,{received:t.data,code:ye.invalid_enum_value,options:i}),Se}return Oe(e.data)}get options(){return this._def.values}get enum(){const e={};for(const t of this._def.values)e[t]=t;return e}get Values(){const e={};for(const t of this._def.values)e[t]=t;return e}get Enum(){const e={};for(const t of this._def.values)e[t]=t;return e}extract(e){return wt.create(e)}exclude(e){return wt.create(this.options.filter((t=>!e.includes(t))))}}wt.create=vt;class _t extends Ne{_parse(e){const t=pe.getValidEnumValues(this._def.values),i=this._getOrReturnCtx(e);if(i.parsedType!==fe.string&&i.parsedType!==fe.number){const e=pe.objectValues(t);return xe(i,{expected:pe.joinValues(e),received:i.parsedType,code:ye.invalid_type}),Se}if(-1===t.indexOf(e.data)){const e=pe.objectValues(t);return xe(i,{received:i.data,code:ye.invalid_enum_value,options:e}),Se}return Oe(e.data)}get enum(){return this._def.values}}_t.create=(e,t)=>new _t({values:e,typeName:Zt.ZodNativeEnum,...Ze(t)});class kt extends Ne{unwrap(){return this._def.type}_parse(e){const{ctx:t}=this._processInputParams(e);if(t.parsedType!==fe.promise&&!1===t.common.async)return xe(t,{code:ye.invalid_type,expected:fe.promise,received:t.parsedType}),Se;const i=t.parsedType===fe.promise?t.data:Promise.resolve(t.data);return Oe(i.then((e=>this._def.type.parseAsync(e,{path:t.path,errorMap:t.common.contextualErrorMap}))))}}kt.create=(e,t)=>new kt({type:e,typeName:Zt.ZodPromise,...Ze(t)});class xt extends Ne{innerType(){return this._def.schema}sourceType(){return this._def.schema._def.typeName===Zt.ZodEffects?this._def.schema.sourceType():this._def.schema}_parse(e){const{status:t,ctx:i}=this._processInputParams(e),n=this._def.effect||null,r={addIssue:e=>{xe(i,e),e.fatal?t.abort():t.dirty()},get path(){return i.path}};if(r.addIssue=r.addIssue.bind(r),"preprocess"===n.type){const e=n.transform(i.data,r);return i.common.issues.length?{status:"dirty",value:i.data}:i.common.async?Promise.resolve(e).then((e=>this._def.schema._parseAsync({data:e,path:i.path,parent:i}))):this._def.schema._parseSync({data:e,path:i.path,parent:i})}if("refinement"===n.type){const e=e=>{const t=n.refinement(e,r);if(i.common.async)return Promise.resolve(t);if(t instanceof Promise)throw new Error("Async refinement encountered during synchronous parse operation. Use .parseAsync instead.");return e};if(!1===i.common.async){const n=this._def.schema._parseSync({data:i.data,path:i.path,parent:i});return"aborted"===n.status?Se:("dirty"===n.status&&t.dirty(),e(n.value),{status:t.value,value:n.value})}return this._def.schema._parseAsync({data:i.data,path:i.path,parent:i}).then((i=>"aborted"===i.status?Se:("dirty"===i.status&&t.dirty(),e(i.value).then((()=>({status:t.value,value:i.value}))))))}if("transform"===n.type){if(!1===i.common.async){const e=this._def.schema._parseSync({data:i.data,path:i.path,parent:i});if(!Fe(e))return e;const s=n.transform(e.value,r);if(s instanceof Promise)throw new Error("Asynchronous transform encountered during synchronous parse operation. Use .parseAsync instead.");return{status:t.value,value:s}}return this._def.schema._parseAsync({data:i.data,path:i.path,parent:i}).then((e=>Fe(e)?Promise.resolve(n.transform(e.value,r)).then((e=>({status:t.value,value:e}))):e))}pe.assertNever(n)}}xt.create=(e,t,i)=>new xt({schema:e,typeName:Zt.ZodEffects,effect:t,...Ze(i)}),xt.createWithPreprocess=(e,t,i)=>new xt({schema:t,effect:{type:"preprocess",transform:e},typeName:Zt.ZodEffects,...Ze(i)});class jt extends Ne{_parse(e){return this._getType(e)===fe.undefined?Oe(void 0):this._def.innerType._parse(e)}unwrap(){return this._def.innerType}}jt.create=(e,t)=>new jt({innerType:e,typeName:Zt.ZodOptional,...Ze(t)});class St extends Ne{_parse(e){return this._getType(e)===fe.null?Oe(null):this._def.innerType._parse(e)}unwrap(){return this._def.innerType}}St.create=(e,t)=>new St({innerType:e,typeName:Zt.ZodNullable,...Ze(t)});class At extends Ne{_parse(e){const{ctx:t}=this._processInputParams(e);let i=t.data;return t.parsedType===fe.undefined&&(i=this._def.defaultValue()),this._def.innerType._parse({data:i,path:t.path,parent:t})}removeDefault(){return this._def.innerType}}At.create=(e,t)=>new At({innerType:e,typeName:Zt.ZodDefault,defaultValue:"function"==typeof t.default?t.default:()=>t.default,...Ze(t)});class Ot extends Ne{_parse(e){const{ctx:t}=this._processInputParams(e),i={...t,common:{...t.common,issues:[]}},n=this._def.innerType._parse({data:i.data,path:i.path,parent:{...i}});return Re(n)?n.then((e=>({status:"valid",value:"valid"===e.status?e.value:this._def.catchValue({get error(){return new be(i.common.issues)},input:i.data})}))):{status:"valid",value:"valid"===n.status?n.value:this._def.catchValue({get error(){return new be(i.common.issues)},input:i.data})}}removeCatch(){return this._def.innerType}}Ot.create=(e,t)=>new Ot({innerType:e,typeName:Zt.ZodCatch,catchValue:"function"==typeof t.catch?t.catch:()=>t.catch,...Ze(t)});class Tt extends Ne{_parse(e){if(this._getType(e)!==fe.nan){const t=this._getOrReturnCtx(e);return xe(t,{code:ye.invalid_type,expected:fe.nan,received:t.parsedType}),Se}return{status:"valid",value:e.data}}}Tt.create=e=>new Tt({typeName:Zt.ZodNaN,...Ze(e)});const Ct=Symbol("zod_brand");class Ft extends Ne{_parse(e){const{ctx:t}=this._processInputParams(e),i=t.data;return this._def.type._parse({data:i,path:t.path,parent:t})}unwrap(){return this._def.type}}class Rt extends Ne{_parse(e){const{status:t,ctx:i}=this._processInputParams(e);if(i.common.async)return(async()=>{const e=await this._def.in._parseAsync({data:i.data,path:i.path,parent:i});return"aborted"===e.status?Se:"dirty"===e.status?(t.dirty(),Ae(e.value)):this._def.out._parseAsync({data:e.value,path:i.path,parent:i})})();{const e=this._def.in._parseSync({data:i.data,path:i.path,parent:i});return"aborted"===e.status?Se:"dirty"===e.status?(t.dirty(),{status:"dirty",value:e.value}):this._def.out._parseSync({data:e.value,path:i.path,parent:i})}}static create(e,t){return new Rt({in:e,out:t,typeName:Zt.ZodPipeline})}}class Lt extends Ne{_parse(e){const t=this._def.innerType._parse(e);return Fe(t)&&(t.value=Object.freeze(t.value)),t}}Lt.create=(e,t)=>new Lt({innerType:e,typeName:Zt.ZodReadonly,...Ze(t)});const Et=(e,t={},i)=>e?et.create().superRefine(((n,r)=>{var s,a;if(!e(n)){const e="function"==typeof t?t(n):"string"==typeof t?{message:t}:t,o=null===(a=null!==(s=e.fatal)&&void 0!==s?s:i)||void 0===a||a,c="string"==typeof e?{message:e}:e;r.addIssue({code:"custom",...c,fatal:o})}})):et.create(),Pt={object:at.lazycreate};var Zt;!function(e){e.ZodString="ZodString",e.ZodNumber="ZodNumber",e.ZodNaN="ZodNaN",e.ZodBigInt="ZodBigInt",e.ZodBoolean="ZodBoolean",e.ZodDate="ZodDate",e.ZodSymbol="ZodSymbol",e.ZodUndefined="ZodUndefined",e.ZodNull="ZodNull",e.ZodAny="ZodAny",e.ZodUnknown="ZodUnknown",e.ZodNever="ZodNever",e.ZodVoid="ZodVoid",e.ZodArray="ZodArray",e.ZodObject="ZodObject",e.ZodUnion="ZodUnion",e.ZodDiscriminatedUnion="ZodDiscriminatedUnion",e.ZodIntersection="ZodIntersection",e.ZodTuple="ZodTuple",e.ZodRecord="ZodRecord",e.ZodMap="ZodMap",e.ZodSet="ZodSet",e.ZodFunction="ZodFunction",e.ZodLazy="ZodLazy",e.ZodLiteral="ZodLiteral",e.ZodEnum="ZodEnum",e.ZodEffects="ZodEffects",e.ZodNativeEnum="ZodNativeEnum",e.ZodOptional="ZodOptional",e.ZodNullable="ZodNullable",e.ZodDefault="ZodDefault",e.ZodCatch="ZodCatch",e.ZodPromise="ZodPromise",e.ZodBranded="ZodBranded",e.ZodPipeline="ZodPipeline",e.ZodReadonly="ZodReadonly"}(Zt||(Zt={}));const Nt=ze.create,It=Je.create,Mt=Tt.create,Dt=Ke.create,Ut=Ge.create,Wt=He.create,$t=Qe.create,qt=Ye.create,Bt=Xe.create,zt=et.create,Vt=tt.create,Jt=it.create,Kt=nt.create,Gt=rt.create,Ht=at.create,Qt=at.strictCreate,Yt=ot.create,Xt=lt.create,ei=ut.create,ti=pt.create,ii=mt.create,ni=ht.create,ri=ft.create,si=gt.create,ai=yt.create,oi=bt.create,ci=wt.create,li=_t.create,di=kt.create,ui=xt.create,pi=jt.create,mi=St.create,hi=xt.createWithPreprocess,fi=Rt.create,gi={string:e=>ze.create({...e,coerce:!0}),number:e=>Je.create({...e,coerce:!0}),boolean:e=>Ge.create({...e,coerce:!0}),bigint:e=>Ke.create({...e,coerce:!0}),date:e=>He.create({...e,coerce:!0})},yi=Se;var bi=Object.freeze({__proto__:null,defaultErrorMap:ve,setErrorMap:function(e){we=e},getErrorMap:_e,makeIssue:ke,EMPTY_PATH:[],addIssueToContext:xe,ParseStatus:je,INVALID:Se,DIRTY:Ae,OK:Oe,isAborted:Te,isDirty:Ce,isValid:Fe,isAsync:Re,get util(){return pe},get objectUtil(){return me},ZodParsedType:fe,getParsedType:ge,ZodType:Ne,ZodString:ze,ZodNumber:Je,ZodBigInt:Ke,ZodBoolean:Ge,ZodDate:He,ZodSymbol:Qe,ZodUndefined:Ye,ZodNull:Xe,ZodAny:et,ZodUnknown:tt,ZodNever:it,ZodVoid:nt,ZodArray:rt,ZodObject:at,ZodUnion:ot,ZodDiscriminatedUnion:lt,ZodIntersection:ut,ZodTuple:pt,ZodRecord:mt,ZodMap:ht,ZodSet:ft,ZodFunction:gt,ZodLazy:yt,ZodLiteral:bt,ZodEnum:wt,ZodNativeEnum:_t,ZodPromise:kt,ZodEffects:xt,ZodTransformer:xt,ZodOptional:jt,ZodNullable:St,ZodDefault:At,ZodCatch:Ot,ZodNaN:Tt,BRAND:Ct,ZodBranded:Ft,ZodPipeline:Rt,ZodReadonly:Lt,custom:Et,Schema:Ne,ZodSchema:Ne,late:Pt,get ZodFirstPartyTypeKind(){return Zt},coerce:gi,any:zt,array:Gt,bigint:Dt,boolean:Ut,date:Wt,discriminatedUnion:Xt,effect:ui,enum:ci,function:si,instanceof:(e,t={message:`Input not instance of ${e.name}`})=>Et((t=>t instanceof e),t),intersection:ei,lazy:ai,literal:oi,map:ni,nan:Mt,nativeEnum:li,never:Jt,null:Bt,nullable:mi,number:It,object:Ht,oboolean:()=>Ut().optional(),onumber:()=>It().optional(),optional:pi,ostring:()=>Nt().optional(),pipeline:fi,preprocess:hi,promise:di,record:ii,set:ri,strictObject:Qt,string:Nt,symbol:$t,transformer:ui,tuple:ti,undefined:qt,union:Yt,unknown:Vt,void:Kt,NEVER:yi,ZodIssueCode:ye,quotelessJson:e=>JSON.stringify(e,null,2).replace(/"([^"]+)":/g,"$1:"),ZodError:be});const vi=bi.string(),wi=bi.string().nullable(),_i=bi.number(),ki=bi.string().nullable(),xi=bi.string().nullable(),ji=bi.string().nullable(),Si=bi.number(),Ai=bi.string(),Oi=bi.string(),Ti=bi.union([Si,ji,xi,ki,Ai,_i,wi,vi,Oi]),Ci={ADMIN:9,USER:5,EXTERNAL:3,GUEST:0},Fi=bi.lazy((()=>Ki.extend({title:bi.string(),_url:bi.string(),level:bi.nativeEnum(Ci),dateCreation:bi.string(),dateModified:bi.string()}).catchall(Ti))),Ri=bi.lazy((()=>Fi.schema.extend({active:bi.number()}))),Li=e=>Ri.safeParse(e).success,Ei=Ri,Pi=e=>Ei.safeParse(e).success,Zi=bi.object({idInType:bi.number(),lat:bi.number(),lng:bi.number()}),Ni=e=>Zi.safeParse(e).success,Ii=bi.object({title:bi.string(),firstname:bi.string(),lastname:bi.string(),mail:bi.union([bi.string(),bi.undefined()]).optional(),description:bi.string().optional(),dateOfBirth:bi.string().optional(),phoneNumber:bi.string().optional(),language:bi.string().optional(),timeZone:bi.string().optional(),mobileNumber:bi.string().optional(),company:bi.string().optional(),country:bi.string().optional(),department:bi.string().optional(),function:bi.string().optional(),webSite:bi.string().optional(),image:bi.union([bi.string(),bi.undefined()]).optional(),userBanner:bi.union([bi.string(),bi.undefined()]).optional(),field1:bi.string().optional(),field2:bi.string().optional(),field3:bi.string().optional(),field4:bi.string().optional(),field5:bi.string().optional()}),Mi=Ii.required().extend({level:bi.string(),image:bi.string().optional(),businessManagementManager:Fi.array().optional(),businessNetworkingUserToCompanySrc:Fi.array().optional()}),Di=bi.object({user_field_edit_profil:bi.record(Ii.keyof(),bi.number()),user_field_editable:bi.record(Ii.keyof(),bi.number()),user_field_my_page:bi.record(Ii.keyof(),bi.number()),user_page_mandatory_fields:bi.object({firstname:bi.enum(["0","1"]),lastname:bi.enum(["0","1"]),pseudo:bi.enum(["0","1"])})}),Ui=bi.object({name:bi.string(),value:bi.union([bi.string(),bi.record(bi.string(),bi.any())])}),Wi=bi.enum(["popover"]),$i=bi.object({values:Mi,mobileEditableFields:Mi.keyof().array()}),qi=bi.object({mail:bi.union([bi.string(),bi.undefined()]),title:bi.string(),firstname:bi.string(),lastname:bi.string(),phoneNumber:bi.union([bi.string(),bi.undefined()]).optional(),company:bi.union([bi.string(),bi.undefined()]).optional(),function:bi.union([bi.string(),bi.undefined()]).optional(),uri:bi.union([bi.string(),bi.undefined()]).optional(),field1:bi.union([bi.string(),bi.undefined()]).optional(),field2:bi.union([bi.string(),bi.undefined()]).optional(),field3:bi.union([bi.string(),bi.undefined()]).optional(),field4:bi.union([bi.string(),bi.undefined()]).optional(),field5:bi.union([bi.string(),bi.undefined()]).optional()}),Bi=bi.object({userDirectoryShow:bi.union([bi.literal(""),bi.literal("1")]),contactDirectoryShow:bi.union([bi.literal("0"),bi.literal("1")]),businessContactShow:bi.boolean(),menu:bi.union([bi.literal("0"),bi.literal("1")]),cardFields:bi.string().array(),tableFields:bi.string().array(),viewFields:bi.string().array(),userGeoloc:bi.boolean().optional(),sort:bi.string(),cnt:bi.number().optional(),filters:bi.object({name:bi.string(),type:bi.string()}).array()}),zi=e=>Bi.safeParse(e).success,Vi=bi.object({create:bi.boolean(),read:bi.boolean(),publish:bi.boolean(),administrate:bi.boolean(),update:bi.boolean(),delete:bi.boolean(),comment:bi.boolean(),member:bi.boolean()}),Ji=e=>Vi.safeParse(e).success,Ki=bi.object({id:bi.number(),mainType:bi.string(),type:bi.string(),uri:bi.string(),dateCreation:bi.string().optional(),dateModified:bi.string().optional().nullable()}),Gi=Ki.extend({title:bi.string(),_url:bi.string()}),Hi=e=>Gi.safeParse(e).success,Qi=bi.lazy((()=>Gi.extend({description:bi.string().optional().nullable(),_user:Fi,_right:Vi}))),Yi=e=>Qi.safeParse(e).success;var Xi;!function(e){e[e.SPOT_MODERATE_IGNORE=0]="SPOT_MODERATE_IGNORE",e[e.SPOT_MODERATE_ACCEPT=1]="SPOT_MODERATE_ACCEPT",e[e.SPOT_MODERATE_PENDING=2]="SPOT_MODERATE_PENDING"}(Xi||(Xi={}));const en=bi.object({RF_Constant_levelName:bi.string(),RF_delete:bi.boolean(),RF_editing:bi.boolean(),RF_level:bi.number(),RF_levelName:bi.string(),RF_levelName_Trad:bi.string(),RF_parameters:bi.boolean(),RF_setAdmin:bi.boolean(),RF_spotit:bi.boolean(),RF_spotit_own:bi.boolean()}),tn=Gi.extend({dateCreation:bi.string(),dateModified:bi.string(),category:bi.number(),privacy:bi.number()}),nn=e=>en.safeParse(e).success;class rn extends i{list(e,t,i,n=[{name:"dateCreation",sort:"DESC"}]){return this.jApi.article.list({type:"aseiClearanceTicket",format:"raw-view",limit:t,page:e,orders:n,filters:i})}requestStatus(e,t,i){return this.network.post({o:"asei",f:"setStatus",uri:e,requestedStatus:t,audience:i})}getDedicatedGroups(){return this.network.post({o:"asei",f:"getDedicatedGroups"})}getConfiguration(){return this.network.post({o:"asei",f:"configuration"})}}class sn extends i{tenants(){return this.network.post({o:"drive",f:"getTenants"})}groups(e,t){return this.network.post({o:"drive",f:"getGroups",query:e,filter:t})}sites(){return this.network.post({o:"drive",f:"getSites"})}listAccount(e){return this.network.post({o:"drive",f:"listAccount",service:e})}isAccountLogged(e,t){return this.network.post({o:"drive",f:"isAccountLogged",service:e,id:t})}checkAccountToken(e){return this.network.post({o:"drive",f:"checkAccountToken",service:e})}documents(e,t){return this.network.post({o:"drive",f:"getDocuments",service:e,documentParams:t})}}class an extends i{GetUnclassifiedFiles(e){var t;return this.network.post({o:"objectListMediaLibrary",f:"GetUnclassifiedFiles",format:e.format,page:null!==(t=e.page)&&void 0!==t?t:1,limit:e.limit,nolimit:e.nolimit})}getAccess(){return this.network.post({o:"mediaLibrary",f:"access"})}getFoldersStatsList(e=[],t=[],i=1){return this.network.post({o:"objectListMediaLibrary",f:"FoldersStatsList",filters:e,orders:t,page:i})}getFilesStatsList(e=[],t=[],i=1){return this.network.post({o:"objectListMediaLibrary",f:"FilesStatsList",filters:e,orders:t,page:i})}getStats(){return this.network.post({o:"mediaLibrary",f:"moderatorStats"})}readFolder(e){return this.network.post({o:"mediaLibrary",f:"readFolder",uri:e})}readFile(e){return this.network.post({o:"mediaLibrary",f:"readFile",uri:e})}}class on extends i{getLogs({dateEnd:e,idLogMax:t}){return this.network.post({o:"jLand",f:"adminLogs",dateEnd:e,idLogMax:t})}getStats({map:e,dateStart:t,dateEnd:i}){return this.network.post({o:"jLand",f:"adminStats",map:e,dateStart:t,dateEnd:i})}getAllMapsAsAdmin(e="raw-list,licenses"){return this.network.post({o:"objectListJLand",f:"jLandList",format:e})}createMap(e,t="raw-list"){return this.network.maybePostToken(Object.assign(Object.assign({},e),{o:"article",f:"create",format:t,type:"jlandmap"}))}}class cn extends i{sendMessage(e,t){return this.network.post({o:"messenger",f:"newMessage",idDiscussion:t,msg:{description:e}})}getOrCreateDiscussion(e,t){const i=e<t?`${e}.${t}`:`${t}.${e}`;return this.network.post({o:"messenger",f:"getDiscussion",idDiscussion:i,type:"messengerUser",idUserTo:t})}}class ln extends i{getConfig(){return this.network.post({o:"search",f:"getConfig"})}proposition({query:e,format:t},i){return this.network.post({o:"search",f:"proposition",query:e,format:t||"little"},i)}searchQuery(e,t){const{keywords:i,category:n,facetCategories:r,filters:s,page:a,limit:o,sort:c,options:l,format:d}=e;return this.network.post({o:"search",f:"query",keywords:i,category:n,facetCategories:r,filters:s,page:a,limit:o,sort:c,options:l,format:B(d,null==t?void 0:t.formatExtension)},null==t?void 0:t.signal)}getLastQueries(){return this.network.post({o:"search",f:"getLastQueries"})}getAdminConfig(){return this.network.post({o:"search",f:"getAdminConfig"})}setAdminConfig(e){return this.network.post({o:"search",f:"setAdminConfig",config:e})}}var dn=function(e,t){var i={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(i[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var r=0;for(n=Object.getOwnPropertySymbols(e);r<n.length;r++)t.indexOf(n[r])<0&&Object.prototype.propertyIsEnumerable.call(e,n[r])&&(i[n[r]]=e[n[r]])}return i};class un extends i{list(){return this.network.post({o:"taxonomy",f:"list",format:"raw-little"}).then((e=>{if(Array.isArray(e.result))return e.result;throw"Bad response from backend"}))}create(e){var{format:t="raw-little"}=e,i=dn(e,["format"]);return this.network.post(Object.assign({o:"taxonomy",f:"create",format:t},i))}autocomplete(e,t){return this.network.post({o:"autocomplete",f:"taxonomy",q:t,idTaxonomy:e,idToUri:!1})}autocompleteList(e){var{format:t="autocomplete"}=e,i=dn(e,["format"]);return this.network.post(Object.assign({o:"objectListTaxonomy",f:"concept",format:t},i))}autocompleteHierarchy(e){return this.network.post(Object.assign({o:"objectListTaxonomyHierarchy",f:"concept"},e))}}class pn extends i{autocomplete(e){return this.network.post({o:"autocomplete",f:"user",q:e,idToUri:!1}).then((e=>e.result))}get(e,t="little",i){return this.network.post({o:"user",f:"get",uri:e,format:t},i)}updateImage(e,t="raw-little"){return this.network.postCSRF({o:"user",f:"updateImage",idFile:e,format:t})}updateBanner(e,t="raw-little"){return this.network.postCSRF({o:"user",f:"updateBanner",idFile:e,format:t})}updateMail(e,t){return this.network.postCSRF({o:"user",f:"editMail",mail:e,password:t})}userUpdateProfile(e){return this.network.postCSRF(Object.assign({o:"user",f:"updateProfile"},e))}configuration(){return this.network.post({o:"userDirectory",f:"configuration"})}fieldsConfiguration(){return this.network.post({o:"user",f:"fieldsConfiguration"})}userList(e,t){return this.network.post(Object.assign(Object.assign({o:"objectList",f:"JamespotUserList"},e),{format:B(e.format,null==t?void 0:t.formatExtension)}),null==t?void 0:t.signal)}userQueryList(e,t){return this.network.post(Object.assign(Object.assign({o:"objectList",f:"JamespotUserQueryList"},e),{format:B(e.format,null==t?void 0:t.formatExtension)}))}userMap(e){return this.network.post(Object.assign({o:"objectListJamespot",f:"userMap"},e))}userBusinessContactQueryList(e){return this.network.post(Object.assign({o:"businessContact",f:"queryList"},e))}userCreateBusinessContact(e){const t=Object.assign(Object.assign({},e),{pseudo:e.title,firstName:e.firstname,lastName:e.lastname,champ1:e.field1,champ2:e.field2,champ3:e.field3,champ4:e.field4,champ5:e.field5}),i=Object.assign(Object.assign({},t),{type:"businessContactCard",publishTo:"networkPublic/1"});return this.jApi.article.create(i)}userUpdateBusinessContact(e){const t=Object.assign(Object.assign({},e),{pseudo:e.title,firstName:e.firstname,lastName:e.lastname,champ1:e.field1,champ2:e.field2,champ3:e.field3,champ4:e.field4,champ5:e.field5}),i=Object.assign(Object.assign({},t),{uri:e.uri,publishTo:"networkPublic/1"});return this.jApi.article.update(i)}userDeleteBusinessContact(e){return this.jApi.article.delete(e)}userAddContact(e){return this.network.post({o:"user",f:"addContact",idUser:e})}userRemoveContact(e){return this.network.post({o:"user",f:"removeContact",idUser:e})}signIn(e,t){return this.network.post({o:"user",f:"signIn",mail:e,password:t})}getFields(e,t){return this.network.post({o:"user",f:"getFields",idUser:e,fieldsType:t})}}class mn extends i{getFiles(e){return this.network.post(Object.assign({o:"onlyOffice",f:"getFiles"},e))}getFile(e,t){return this.network.post({o:"onlyOffice",f:"getFile",idFile:e,hash:t})}getTemplates(e){return this.network.post({o:"onlyOffice",f:"getTemplates"},e)}deleteFile(e,t){return this.network.postCSRF({o:"onlyOffice",f:"deleteFile",idFile:e,withParent:t})}createFile(e,t,i){return this.network.postCSRF({o:"onlyOffice",f:"createFile",title:e,type:t,publishTo:i})}updateFile(e,t){return this.network.postCSRF({o:"onlyOffice",f:"updateFile",idFile:e,title:t})}createVersion(e){return this.network.post({o:"onlyOffice",f:"createVersion",idFile:e})}setAccessRequest(e,t,i,n){return this.network.postCSRF({o:"onlyOffice",f:"setAccessRequest",uri:e,idUser:t,requestAccessValue:i,requestResponseMessage:n})}getAccessRequest(e,t){return this.network.post({o:"onlyOffice",f:"getAccessRequest",format:"raw-little",uri:e,idUser:t})}askAccess(e,t,i){return this.network.postCSRF({o:"onlyOffice",f:"askAccess",uri:e,askAccess:t,askMessage:i})}}class hn extends i{createChannel(e,t="raw-list"){return this.network.maybePostToken(Object.assign(Object.assign({},e),{o:"article",f:"create",format:t,type:"tvDisplayChannel"}))}getChannel(e){return this.network.post(Object.assign(Object.assign({},e),{o:"tvDisplay",f:"getChannel"}))}getConfigureChannel(e){return this.network.post(Object.assign(Object.assign({},e),{o:"tvDisplay",f:"getConfigureChannel"}))}}class fn extends i{contentObjectLinks(e){return this.network.post({o:"shared",f:"contentObjectLinks",format:"raw-little",uri:e})}contentSetObjectAccessRule(e,t,i){return this.network.postCSRF({o:"shared",f:"contentSetObjectAccessRule",format:"raw-little",uri:e,rule:t,hash:i})}}var gn=function(e,t,i,n){return new(i||(i=Promise))((function(r,s){function a(e){try{c(n.next(e))}catch(e){s(e)}}function o(e){try{c(n.throw(e))}catch(e){s(e)}}function c(e){var t;e.done?r(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(a,o)}c((n=n.apply(e,t||[])).next())}))};class yn extends i{SaveAnimationConfiguration(e){return gn(this,void 0,void 0,(function*(){return this.network.post({o:"animations",f:"saveConfiguration",animation:e})}))}DeleteAnimation(){return gn(this,void 0,void 0,(function*(){return this.network.post({o:"animations",f:"deleteAnimation"})}))}GetCurrentAnimation(){return gn(this,void 0,void 0,(function*(){return this.network.post({o:"animations",f:"getConfiguration"})}))}GetCurrentAnimationApp(){return gn(this,void 0,void 0,(function*(){return this.network.post({o:"animations",f:"getConfigurationApp"})}))}ToggleAnimationActive(){return gn(this,void 0,void 0,(function*(){return this.network.post({o:"animations",f:"toggleAnimationActive"})}))}GetAnimationActive(){return gn(this,void 0,void 0,(function*(){return this.network.post({o:"animations",f:"getAnimationActive"})}))}}class bn extends i{GetStatus(){return e=this,t=void 0,n=function*(){return this.network.post({o:"accessibility",f:"getStatus"})},new((i=void 0)||(i=Promise))((function(r,s){function a(e){try{c(n.next(e))}catch(e){s(e)}}function o(e){try{c(n.throw(e))}catch(e){s(e)}}function c(e){var t;e.done?r(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(a,o)}c((n=n.apply(e,t||[])).next())}));var e,t,i,n}}class vn extends i{getObject(e){return this.network.post({o:"object",f:"getObject",uri:e})}setAccess(e,t,i,n){return this.network.post({o:"object",f:"setAccess",uri:e,access:t,message:i,generalAccessRule:n})}getAccess(e){return this.network.post({o:"object",f:"getAccess",uri:e})}getAccessHash(e){return this.network.post({o:"object",f:"getAccessHash",uri:e})}}class wn extends i{getFileBanks(e){return this.network.post({o:"file-sync",f:"getFileBanks"},e)}saveFileBanks(e){return this.network.post({o:"file-sync",f:"saveFileBanks",fileBanks:e})}getUserQuota(e){return this.network.post({o:"file-sync",f:"getUserQuota"},e)}getAdminSpots(e,t){return this.network.post(Object.assign({o:"objectList",f:"fileSyncAdminSpots"},e),t)}}class _n extends i{getUsers(e,t){return this.network.post(Object.assign(Object.assign({o:"customAction",f:"getUsers"},e),{format:null!=t?t:"raw-list"}))}add(e,t){return this.network.post(Object.assign(Object.assign({o:"customAction",f:"add"},e),{format:null!=t?t:"raw-little"}))}remove(e,t){return this.network.post(Object.assign(Object.assign({o:"customAction",f:"remove"},e),{format:null!=t?t:"raw-little"}))}}class kn extends i{textEnhancement({text:e,capacity:t}){return this.network.post({o:"jia",f:"textEnhancement",text:e,capacity:t})}}class xn extends i{responseUserList(e,t,i){return this.network.post({o:"widget",f:"responseUserList",uri:e,uniqid:t,page:i})}removeWidget({id:e,type:t,uniqid:i}){return this.network.post({o:"widget",f:"removeWidget",id:e,type:t,uniqid:i})}checkListRespond({id:e,type:t,idUser:i,uniqid:n,index:r}){return this.network.post({o:"widget",f:"checkListRespond",id:e,type:t,uniqid:n,idUser:i,index:r})}updateWidget({id:e,uniqid:t,content:i,title:n,type:r}){return this.network.post({o:"widget",f:"updateWidget",id:e,uniqid:t,content:i,title:n,type:r})}}class jn extends i{getThumbnailUrl(e){return this.network.post({o:"magicPad",f:"getThumbnailUrl",uri:e})}}class Sn{constructor(e){this.version="1.0",this.network=e,this.admin={license:new r(this),store:new s(this),utils:new a(this)},this.accessibility=new bn(this),this.application=new o(this),this.article=new Q(this),this.asei=new rn(this),this.assetReservation=new X(this),this.audience=new ee(this),this.bbb=new te(this),this.bookmark=new ie(this),this.businessNetworking=new ne(this),this.community=new re(this),this.datasource=new se(this),this.diapazone=new ae(this),this.drive=new sn(this),this.faq=new le(this),this.file=new ce(this),this.filebank=new de(this),this.fileSync=new wn(this),this.global=new ue(this),this.group=new he(this),this.jia=new kn(this),this.jland=new on(this),this.magicPad=new jn(this),this.mediaLibrary=new an(this),this.messenger=new cn(this),this.object=new vn(this),this.search=new ln(this),this.share=new fn(this),this.socialAction=new _n(this),this.taxonomy=new un(this),this.tvDisplay=new hn(this),this.user=new pn(this),this.wedoc=new mn(this),this.widget=new xn(this),this.animations=new yn(this)}}class An{getBackendUrl(){return e=this,t=void 0,n=function*(){const e=window.location;return`${e.protocol}//${e.host}`},new((i=void 0)||(i=Promise))((function(r,s){function a(e){try{c(n.next(e))}catch(e){s(e)}}function o(e){try{c(n.throw(e))}catch(e){s(e)}}function c(e){var t;e.done?r(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(a,o)}c((n=n.apply(e,t||[])).next())}));var e,t,i,n}fetch(e,t){return window.fetch(e,t)}}const On=bi.object({countActiveUsersWithoutLicense:bi.number().optional(),countLicensesAssigned:bi.number(),countLicensesNotAssigned:bi.number()}),Tn=bi.object({href:bi.string(),target:bi.string()}),Cn=bi.object({name:bi.string(),sort:bi.union([bi.literal("ASC"),bi.literal("DESC")])}),Fn=bi.union([Fi,tn]),Rn=bi.union([bi.boolean(),bi.string(),bi.number(),bi.array(bi.string()),bi.object({srcId:bi.union([bi.number(),bi.string()]),srcType:bi.string()}),bi.object({targetId:bi.union([bi.number(),bi.string()]),targetType:bi.string()}),bi.object({start:bi.string(),end:bi.string()})]),Ln=bi.union([bi.literal("<"),bi.literal(">"),bi.literal("<="),bi.literal(">="),bi.literal("!="),bi.literal("<>"),bi.literal("like"),bi.literal("between"),bi.literal("is"),bi.literal("is not"),bi.literal("in"),bi.literal("link"),bi.literal("match"),bi.literal("equal")]),En=bi.union([bi.literal("<"),bi.literal(">"),bi.literal("<="),bi.literal(">="),bi.literal("!="),bi.literal("<>"),bi.literal("+"),bi.literal("-"),bi.literal("like"),bi.literal("between"),bi.literal("is"),bi.literal("is not"),bi.literal("in"),bi.literal("link"),bi.literal("match"),bi.literal("equal")]),Pn=bi.object({name:bi.string(),value:Rn,operator:Ln.optional(),method:En.optional(),or:bi.boolean().optional(),isNull:bi.boolean().optional(),isNotNull:bi.boolean().optional()}),Zn=Cn.array(),Nn=bi.array(Pn);var In;!function(e){e.LITTLE="raw-little",e.LIST="raw-list",e.VIEW="raw-view",e.USER_API="user-api",e.MOBILE="mobile"}(In||(In={}));const Mn=bi.nativeEnum(In).transform((e=>`${e}`)),Dn=bi.union([Mn,bi.undefined()]),Un=bi.array(bi.union([bi.literal("bookmark"),bi.literal("contact"),bi.literal("licenses"),bi.literal("quizFieldDefinitions"),bi.literal("quizResponseRecord"),bi.literal("search"),bi.literal("socialEventRecord"),bi.literal("surveyDateRecord")])),Wn=bi.object({attrName:bi.string(),token:bi.string(),file:bi.instanceof(File).nullable().optional(),url:bi.string().optional()}),$n=bi.object({width:bi.number(),height:bi.number()}),qn=bi.object({x:bi.number(),y:bi.number(),w:bi.number(),h:bi.number(),rotation:bi.number(),killSize:bi.boolean().optional()}),Bn=Gi.extend({dateCreation:bi.string(),dateModified:bi.string().nullable(),mimetype:bi.string(),path:bi.string().optional(),size:bi.number()}),zn=e=>Bn.parse(e),Vn=Bn.extend({_extend:bi.object({crop:qn})}),Jn=bi.object({name:bi.string(),filename:bi.string(),dateModified:bi.string(),mimetype:bi.string()}),Kn=bi.object({idUser:bi.string(),dateDownload:bi.string(),Pseudo:bi.string(),type:bi.string()}),Gn=bi.object({id:bi.string(),uri:bi.string(),shortUri:bi.string(),title:bi.string(),name:bi.string(),mainType:bi.string(),type:bi.string(),label:bi.string(),cssClass:bi.string(),cssColor:bi.string(),class:bi.string()}),Hn=Gn.extend({title:bi.string()}),Qn=Hn.extend({Pseudo:bi.string()}),Yn=Hn.extend({idspot:bi.string()}),Xn=bi.union([Hn,Qn,Yn]),er=bi.enum(["left","right","center","justify"]),tr=bi.enum(["top","bottom","center","left","right"]),ir=bi.enum(["auto","contain","cover"]),nr=bi.enum(["sm","md","lg"]),rr=bi.enum(["contained","outlined"]),sr=bi.enum(["link","anchor","popup"]),ar=bi.object({x:bi.number(),y:bi.number()});var or;!function(e){e.ArticleButton="widget-article-button",e.ArticleGallery="widget-article-gallery",e.ArticleTitle="widget-article-title",e.ArticleText="widget-article-text",e.ArticleImage="widget-article-image",e.ArticleAttachment="widget-article-attachment",e.Api="widget-api",e.ArticleSlider="widget-article-slider",e.CheckList="widget-check-list",e.DatasourceTable="widget-datasource-table"}(or||(or={}));const cr=bi.nativeEnum(or),lr=bi.lazy((()=>bi.union([ts,ns,ss,os,ls,us,Xr,ms,fs,Lr]))),dr=bi.lazy((()=>bi.object({[or.ArticleButton]:ts,[or.ArticleGallery]:ns,[or.ArticleTitle]:ss,[or.ArticleText]:os,[or.ArticleImage]:ls,[or.ArticleAttachment]:us,[or.Api]:Xr,[or.ArticleSlider]:ms,[or.CheckList]:fs,[or.DatasourceTable]:Lr}))),ur=bi.lazy((()=>bi.object({[or.ArticleButton]:$r,[or.ArticleGallery]:Pr,[or.ArticleTitle]:Zr,[or.ArticleText]:Nr,[or.ArticleImage]:qr,[or.ArticleAttachment]:Br,[or.Api]:Ir,[or.ArticleSlider]:Vr,[or.CheckList]:Kr,[or.DatasourceTable]:Rr}))),pr=bi.object({layers:bi.string().array().optional()}),mr=e=>bi.object({title:bi.string(),widget:pr.and(null!=e?e:lr)}),hr=bi.object({css:bi.record(bi.string(),bi.string()).optional(),widgets:mr().array().optional()}),fr=bi.enum(["default","vertical"]),gr=bi.lazy((()=>Ss.schema.extend({articleWidgets:mr().array(),articleWidgetDisplayMode:fr.nullable().or(bi.undefined())}))),yr=bi.object({uniqid:bi.string(),title:bi.string(),locked:bi.boolean(),visible:bi.boolean(),widgets:mr().array(),position:ar.optional()}),br=bi.enum(["edit","view","preview"]),vr=bi.object({type:bi.literal("text")}),wr=bi.object({label:bi.string(),value:bi.string()}),_r=bi.object({type:bi.literal("select"),options:wr.array()}),kr=bi.object({type:bi.literal("date")}),xr=bi.union([vr,_r,kr]),jr=bi.enum(["text","uri","file","select","url","transient","date","email","number","title"]),Sr=bi.enum(["date","date-time","date-time-sec","time","time-sec"]),Ar=bi.enum(["fr-FR","en-EN","filesize"]),Or=bi.object({name:bi.string().optional(),isVisible:bi.boolean().optional(),textEllipsis:bi.boolean().optional(),label:bi.string().optional(),dateFormat:Sr.optional(),numberFormat:Ar.optional()}),Tr=Or.array(),Cr=bi.object({name:bi.string(),label:bi.string(),sortable:bi.boolean().optional(),type:jr,widget:xr}),Fr=bi.object({limit:bi.number().optional(),tableColumnsData:Or.array().optional(),tableHeadColor:bi.string().optional(),tableHeadTextColor:bi.string().optional(),tableHeadIconColor:bi.string().optional(),tableRowColor:bi.string().optional(),tableRowTextColor:bi.string().optional(),tableBorderRadius:bi.number().optional(),tableSizedColumns:bi.boolean().optional(),tableSizedColumnsWidth:bi.number().optional()}),Rr=Fr.extend({uri:bi.string().optional()}),Lr=bi.lazy((()=>bi.object({name:bi.literal(or.DatasourceTable),uniqid:bi.string(),content:Rr}))),Er=e=>Yr(e,Lr),Pr=bi.object({gap:bi.string().optional(),column:bi.string().optional(),files:Bn.array().optional()}),Zr=bi.object({text:bi.string().optional(),textAlign:er.optional(),heading:bi.string().optional(),color:bi.string().optional(),backgroundColor:bi.string().optional()}),Nr=bi.object({text:bi.string().optional(),color:bi.string().optional(),fontSize:bi.string().optional(),lineHeight:bi.string().optional(),linkColor:bi.string().optional()}),Ir=bi.object({url:bi.string().optional(),keys:bi.array(bi.string()).optional(),order:bi.string().optional(),orderBy:bi.string().optional()}),Mr=bi.object({text:bi.string().optional(),color:bi.string().optional(),backgroundColor:bi.string().optional(),borderRadius:bi.string().optional(),fontSize:bi.string().optional(),buttonSize:nr.optional(),variant:rr.optional(),url:bi.string().optional(),target:bi.string().optional()}),Dr=bi.object({url:bi.string(),target:bi.string()}),Ur=bi.object({uniqid:bi.string()}),Wr=bi.object({title:bi.string(),widgets:mr().array()}),$r=Mr.extend({openingType:sr.optional(),openingTypeLink:Dr.optional(),openingTypeAnchor:Ur.optional(),openingTypePopup:Wr.optional()}),qr=bi.object({file:Bn.optional(),useFilter:bi.boolean().optional()}),Br=bi.object({files:Bn.array().optional(),fileDisplay:bi.enum(["list","gallery"]).optional()}),zr=bi.object({title:bi.string(),text:bi.string(),titleHeading:bi.enum(["h1","h2","h3","h4","h5","h6","p","span"]).optional(),textColor:bi.string().optional(),opacityFilter:bi.number().optional(),opacityColor:bi.string().optional(),file:Bn.optional()}),Vr=bi.object({slides:zr.array().optional(),maxWidth:bi.number().optional(),loop:bi.boolean().optional(),useDots:bi.boolean().optional(),startAt:bi.number().optional()}),Jr=bi.object({title:bi.string(),value:bi.boolean().optional(),links:Tn.array().optional(),id:bi.number().optional(),user:bi.object({id:bi.number(),type:bi.literal("user"),mainType:bi.literal("user")}).optional()}),Kr=bi.object({arr:Jr.array().optional()}),Gr=bi.object({widgets:mr().array().optional()}).and(bi.union([Nr,qr,Zr,$r,Pr,Br,Ir,Vr,Kr,Rr])),Hr=bi.object({busy:bi.union([bi.boolean(),bi.undefined()]).optional(),loading:bi.union([bi.boolean(),bi.undefined()]).optional(),initialized:bi.union([bi.boolean(),bi.undefined()]).optional(),mounted:bi.union([bi.boolean(),bi.undefined()]).optional(),hover:bi.union([bi.boolean(),bi.undefined()]).optional(),empty:bi.boolean().optional()}),Qr=bi.object({width:bi.number().or(bi.undefined()).optional(),inplace:bi.boolean(),isComponentVisible:bi.boolean().optional(),mode:br,onClick:bi.function().returns(bi.void()).optional(),onChange:bi.function().args(Gr,bi.boolean()).returns(bi.void()),onStateChange:bi.function().args(Hr).returns(bi.void())}),Yr=(e,t)=>t.safeParse(e).success,Xr=bi.object({name:bi.literal(or.Api),uniqid:bi.string(),content:Ir}),es=e=>Yr(e,Xr),ts=bi.lazy((()=>bi.object({name:bi.literal(or.ArticleButton),uniqid:bi.string(),content:$r}))),is=e=>Yr(e,ts),ns=bi.object({name:bi.literal(or.ArticleGallery),uniqid:bi.string(),content:Pr}),rs=e=>Yr(e,ns),ss=bi.object({name:bi.literal(or.ArticleTitle),uniqid:bi.string(),content:Zr}),as=e=>Yr(e,ss),os=bi.object({name:bi.literal(or.ArticleText),uniqid:bi.string(),content:Nr}),cs=e=>Yr(e,os),ls=bi.object({name:bi.literal(or.ArticleImage),uniqid:bi.string(),content:qr}),ds=e=>Yr(e,ls),us=bi.object({name:bi.literal(or.ArticleAttachment),uniqid:bi.string(),content:Br}),ps=e=>Yr(e,us),ms=bi.object({name:bi.literal(or.ArticleSlider),uniqid:bi.string(),content:Vr}),hs=e=>Yr(e,ms),fs=bi.object({name:bi.literal(or.CheckList),uniqid:bi.string(),content:Kr.and(hr)}),gs=e=>Yr(e,fs),ys=bi.object({text:bi.string(),value:bi.boolean().optional(),links:Tn.array().optional(),uri:bi.string().optional(),mimetype:bi.string().optional(),id:bi.number().optional(),user:Fi.optional()}),bs=bi.object({arr:ys.array().optional()}),vs=bi.object({name:bi.literal("widget-check-list"),uniqid:bi.string(),content:bs,title:bi.string()}),ws=bi.object({label:bi.string(),description:bi.string(),name:cr,img:bi.string(),available:bi.boolean(),panel:bi.object({useWrapper:bi.boolean(),useEditor:bi.boolean(),useWidgets:bi.boolean()})}),_s=bi.object({title:bi.string().optional(),view:bi.any().optional()}),ks=bi.object({token:bi.string().or(bi.undefined()).optional(),ids:bi.record(bi.string(),mr()),layers:bi.record(bi.string(),yr),states:bi.record(bi.string(),Hr),modal:_s.or(bi.undefined()),editableMap:bi.record(bi.string(),bi.object({index:bi.number(),uniqid:bi.string()})),currentEditableIndex:bi.number(),currentEditableWidgetId:bi.string().or(bi.undefined()),widgetObject:bi.record(bi.string(),Gi.partial())}),xs=bi.object({widgets:ks}),js=bi.lazy((()=>gr.schema.extend({articleWidgetsCover:bi.number().or(bi.undefined()),_audience:Xn.array()}))),Ss=bi.lazy((()=>Gi.extend({dateCreation:bi.string(),dateModified:bi.string()}))),As=Ss.schema.extend({description:bi.string().nullable().optional(),_user:Fi,_right:Vi,_audience:Fn.array(),image:$n.optional(),articleWidgets:mr().array().optional()}),Os=As.extend({_attachedFiles:Bn.array()}),Ts=Os.extend({processContext:bi.null(),uiObjectLink:Gi.array().optional()}),Cs=e=>Os.extend({idDraft:bi.number(),form:e}),Fs=bi.object({type:bi.string().optional(),format:Dn.optional(),formatExtend:Un.optional(),query:bi.string().optional(),limit:bi.number().optional(),page:bi.number().optional(),orders:Zn.optional(),filters:Nn.optional()}),Rs=bi.object({uri:bi.string().optional(),idArticle:bi.number().optional(),format:Dn.optional()}),Ls=bi.object({title:bi.string().optional(),description:bi.string().optional().nullable(),type:bi.string().optional(),publishTo:bi.string().optional(),idSpot:bi.array(bi.string()).optional()}),Es=bi.object({id:bi.number(),type:bi.string(),dateCreation:bi.string(),dateModified:bi.string(),title:bi.string(),uri:bi.string()}),Ps=bi.object({attachment:bi.boolean().optional(),idArticle:bi.number(),limits:bi.object({max:bi.number(),start:bi.number()}).optional()}),Zs=bi.object({token:bi.string(),content:bi.string(),idArticle:bi.number(),sendAlert:bi.boolean(),alertAuthor:bi.boolean(),widgets:mr().array().optional()}),Ns=bi.object({token:bi.string().optional(),description:bi.string().optional(),idComment:bi.number(),widgets:mr().array().optional()}),Is=bi.object({idUser:bi.string(),dateRead:bi.string(),Pseudo:bi.string(),type:bi.string()}),Ms=bi.object({token:bi.string(),fullname:bi.string()}),Ds=bi.object({redirectUrl:bi.string()}),Us=bi.object({token:bi.string()}),Ws=bi.object({dateStart:bi.string(),title:bi.string()}),$s=e=>bi.object({isActive:bi.boolean()}).and(e),qs=bi.enum(["drive_microsoft_graph","drive_dropbox","drive_google"]),Bs=$s(bi.object({drives:bi.record(qs,bi.boolean())})),zs=$s(bi.object({label:bi.string()})),Vs=$s(bi.object({orderBy:bi.string(),order:bi.enum(["ASC","DESC"])})),Js=$s(bi.object({sendAlert:bi.boolean()})),Ks=$s(bi.object({})),Gs=$s(bi.object({create:bi.boolean(),autorize:bi.array(bi.enum(["message","comment","board","article"]).optional())})),Hs=$s(bi.object({label:bi.string(),hasLicense:bi.boolean()})),Qs=bi.object({MagicPadHook:Hs}).partial(),Ys=bi.object({DriveHook:Bs,calendarHook:zs,FileBankHook:Vs,spotRssFeed:Ks,WidgetHook:Gs,AdminAdvancedHook:Js}).partial().and(Qs),Xs=e=>Ys.and(bi.record(bi.string(),bi.any())).parse(e),ea=bi.object({kind:bi.string(),page:bi.number(),limit:bi.number(),filters:Pn.array().optional(),orders:Cn.array().optional()}),ta=e=>bi.object({license:bi.union([bi.literal("1"),bi.literal("0")]),user:e}),ia=bi.object({id:bi.number(),idFolder:bi.number().optional(),fileName:bi.string(),nbViews:bi.number(),nbDistinctViews:bi.number(),nbDownloads:bi.number()}),na=bi.object({id:bi.number(),folderName:bi.string(),nb:bi.number(),nbDistinct:bi.number()}),ra=bi.object({nbFolders:bi.number(),nbFiles:bi.number()}),sa="accept",aa="deny",oa=new M(new An),ca=new Sn(oa);window.JamespotUserApi=ca;const la=ca,da=Sn;module.exports=t})();
|
|
2
2
|
//# sourceMappingURL=jamespot-user-api.js.map
|