@object-ui/console 3.1.5 → 3.3.1

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.
Files changed (121) hide show
  1. package/README.md +16 -0
  2. package/dist/assets/AdapterProvider-Cd4HYb7q.js +1 -0
  3. package/dist/assets/AdvancedChartImpl-AY6sVw1n.js +7 -0
  4. package/dist/assets/AppManagementPage-6l5ZKnv5.js +1 -0
  5. package/dist/assets/ChartImpl-DiKY5voi.js +1 -0
  6. package/dist/assets/DashboardView-BnX2k5Kx.js +1 -0
  7. package/dist/assets/KanbanEnhanced-BKCx2XIr.js +1 -0
  8. package/dist/assets/KanbanImpl-e9jzV-UD.js +1 -0
  9. package/dist/assets/MarkdownImpl-B-r7jSIS.js +1 -0
  10. package/dist/assets/MetadataDetailPage--3o8VI1T.js +1 -0
  11. package/dist/assets/MetadataFormDialog-Cy7k0Y55.js +1 -0
  12. package/dist/assets/MetadataInspector-DVtCDQtx.js +1 -0
  13. package/dist/assets/MetadataManagerPage-CYfvXG6X.js +1 -0
  14. package/dist/assets/MetadataProvider-Dvc9BxbC.js +1 -0
  15. package/dist/assets/PageView-CUDEz8Xo.js +2 -0
  16. package/dist/assets/ProfilePage-B0BXoAus.js +1 -0
  17. package/dist/assets/RecordDetailView-CYgcTNQp.js +1 -0
  18. package/dist/assets/ReportView-ovWyjJsZ.js +1 -0
  19. package/dist/assets/SearchResultsPage-B-NchFoJ.js +1 -0
  20. package/dist/assets/SystemHubPage-D8S1hN1a.js +1 -0
  21. package/dist/assets/data-adapter-v22lWuhc.js +39 -0
  22. package/dist/assets/framework-BW6KsEI0.js +2 -0
  23. package/dist/assets/getIcon-N5xWCMJy.js +1 -0
  24. package/dist/assets/index-DATdOX6r.js +59 -0
  25. package/dist/assets/index-nwlbpqhl.css +2 -0
  26. package/dist/assets/infrastructure-94fpO8jL.js +3 -0
  27. package/dist/assets/maplibre-gl-BR3qC6SX.js +748 -0
  28. package/dist/assets/plugins-core-B5ROGaJH.css +1 -0
  29. package/dist/assets/plugins-core-Ccvbi6db.js +105 -0
  30. package/dist/assets/plugins-views-CbLIJkBs.js +62 -0
  31. package/dist/assets/rolldown-runtime-S-ySWqyJ.js +1 -0
  32. package/dist/assets/{skeletons-DcGqw3b1.js → skeletons-CIQE_YYE.js} +1 -1
  33. package/dist/assets/src-BGoL_8qF.js +1 -0
  34. package/dist/assets/ui-layout-CYz0tyDf.js +3 -0
  35. package/dist/assets/vendor-charts-D1AP0-EV.js +33 -0
  36. package/dist/assets/vendor-icons-CrSf7tAH.js +1 -0
  37. package/dist/assets/vendor-objectstack-Dhrq31KF.js +1 -0
  38. package/dist/assets/{vendor-react-BwtAzZZ3.js → vendor-react-ryfytPb-.js} +2 -2
  39. package/dist/assets/vendor-zod-Dfb8LXKF.js +64 -0
  40. package/dist/index.html +26 -15
  41. package/package.json +48 -64
  42. package/plugin.js +2 -2
  43. package/plugin.ts +2 -2
  44. package/dist/assets/AddressField-BLYuFwUv.js +0 -1
  45. package/dist/assets/AdvancedChartImpl-Dvg6YIfN.js +0 -7
  46. package/dist/assets/AppManagementPage-C5q5QBar.js +0 -1
  47. package/dist/assets/AuditLogPage-BpLFTD-b.js +0 -1
  48. package/dist/assets/AuthPageLayout-DDjJTsQ6.js +0 -1
  49. package/dist/assets/AutoNumberField-DLmi_0fk.js +0 -1
  50. package/dist/assets/AvatarField-BfoEDA_D.js +0 -1
  51. package/dist/assets/BooleanField-W3_x7RAZ.js +0 -1
  52. package/dist/assets/ChartImpl-Cwo6IWnY.js +0 -1
  53. package/dist/assets/CodeField-BWFqblAU.js +0 -1
  54. package/dist/assets/ColorField-Y8WM1wXE.js +0 -1
  55. package/dist/assets/CreateAppPage-A-VfItcx.js +0 -1
  56. package/dist/assets/CurrencyField-BeuE1bRa.js +0 -1
  57. package/dist/assets/DashboardDesignPage-N8NL-jkM.js +0 -1
  58. package/dist/assets/DashboardView-Dy0d2kFj.js +0 -1
  59. package/dist/assets/DateField-2Lf9jstN.js +0 -1
  60. package/dist/assets/DateTimeField-BkMuhOZJ.js +0 -1
  61. package/dist/assets/EditAppPage-B6HL4COW.js +0 -1
  62. package/dist/assets/EmailField-CP_O7tmo.js +0 -1
  63. package/dist/assets/FileField-CcczwlRk.js +0 -1
  64. package/dist/assets/ForgotPasswordPage-Slo6CHvD.js +0 -1
  65. package/dist/assets/FormulaField-DLdg1ImO.js +0 -1
  66. package/dist/assets/GeolocationField-DqeMjnyo.js +0 -1
  67. package/dist/assets/GridField-DaWMYyuc.js +0 -1
  68. package/dist/assets/ImageField-DAn05d1y.js +0 -1
  69. package/dist/assets/KanbanEnhanced-Dj7Qccu2.js +0 -1
  70. package/dist/assets/KanbanImpl-D9BbG_RT.js +0 -1
  71. package/dist/assets/LocationField-DYHVF_gq.js +0 -1
  72. package/dist/assets/LoginPage-D2CqpSi0.js +0 -1
  73. package/dist/assets/LookupField-BF9vCmht.js +0 -1
  74. package/dist/assets/MarkdownImpl-B0Iew7iJ.js +0 -29
  75. package/dist/assets/MasterDetailField-Dw4RRQ5W.js +0 -1
  76. package/dist/assets/NumberField-BKuVHBrN.js +0 -1
  77. package/dist/assets/ObjectField-z00gmFEc.js +0 -1
  78. package/dist/assets/OrgManagementPage-BqtqRi_6.js +0 -1
  79. package/dist/assets/PageDesignPage-BzIL8o0u.js +0 -1
  80. package/dist/assets/PageView-eCi7zkJr.js +0 -2
  81. package/dist/assets/PasswordField-B_rXL4g9.js +0 -1
  82. package/dist/assets/PercentField-Bn_SIbNe.js +0 -1
  83. package/dist/assets/PermissionManagementPage-BmI-0QXt.js +0 -1
  84. package/dist/assets/PhoneField-DuheMaUR.js +0 -1
  85. package/dist/assets/ProfilePage-CUo-xIgl.js +0 -1
  86. package/dist/assets/QRCodeField-IPS2Rpmi.js +0 -1
  87. package/dist/assets/RatingField-M6qZlpA4.js +0 -1
  88. package/dist/assets/RecordDetailView-CFVPmfrM.js +0 -1
  89. package/dist/assets/RegisterPage-D7PJIabW.js +0 -1
  90. package/dist/assets/ReportView-DNOPIpWM.js +0 -1
  91. package/dist/assets/RichTextField-CDGy9V9x.js +0 -1
  92. package/dist/assets/RoleManagementPage-DwtqyfDW.js +0 -1
  93. package/dist/assets/SearchResultsPage-BxzOkRnL.js +0 -1
  94. package/dist/assets/SelectField-F6UDlyvf.js +0 -1
  95. package/dist/assets/SignatureField-CHN7xBII.js +0 -1
  96. package/dist/assets/SliderField-BOfEMQyU.js +0 -1
  97. package/dist/assets/SummaryField-CZ8KzmBZ.js +0 -1
  98. package/dist/assets/SystemHubPage-RFiJSMgW.js +0 -1
  99. package/dist/assets/TextAreaField-1E39zZ_x.js +0 -1
  100. package/dist/assets/TextField-CwuU0Crc.js +0 -1
  101. package/dist/assets/TimeField-CEWXxhLE.js +0 -1
  102. package/dist/assets/UrlField-BtUImn9B.js +0 -1
  103. package/dist/assets/UserField-DSSEoy5L.js +0 -1
  104. package/dist/assets/UserManagementPage-BBS1vYGa.js +0 -1
  105. package/dist/assets/VectorField-BjfQeTZT.js +0 -1
  106. package/dist/assets/data-adapter-wZ81OFjZ.js +0 -39
  107. package/dist/assets/framework-DJlDX9E6.js +0 -1
  108. package/dist/assets/index-D9-L0QBO.css +0 -2
  109. package/dist/assets/index-DDpLaQOV.js +0 -8
  110. package/dist/assets/infrastructure-C6Ph6Ug0.js +0 -3
  111. package/dist/assets/maplibre-gl-DsUGuDud.js +0 -756
  112. package/dist/assets/plugins-core-Cfhp_BXE.css +0 -2
  113. package/dist/assets/plugins-core-PiAAytWV.js +0 -136
  114. package/dist/assets/plugins-views-CE0VP3vl.js +0 -62
  115. package/dist/assets/rolldown-runtime-Dw2cE7zH.js +0 -1
  116. package/dist/assets/src-oeWLmiqa.js +0 -1
  117. package/dist/assets/systemObjects-5--4zaiX.js +0 -1
  118. package/dist/assets/ui-layout-DdDX0gzI.js +0 -3
  119. package/dist/assets/vendor-charts-Bl5l0H2K.js +0 -3
  120. package/dist/assets/vendor-objectstack-BtztJIHv.js +0 -1
  121. package/dist/mockServiceWorker.js +0 -349
@@ -0,0 +1,64 @@
1
+ var e;function t(e,t,n){function r(n,r){if(n._zod||Object.defineProperty(n,`_zod`,{value:{def:r,constr:o,traits:new Set},enumerable:!1}),n._zod.traits.has(e))return;n._zod.traits.add(e),t(n,r);let i=o.prototype,a=Object.keys(i);for(let e=0;e<a.length;e++){let t=a[e];t in n||(n[t]=i[t].bind(n))}}let i=n?.Parent??Object;class a extends i{}Object.defineProperty(a,`name`,{value:e});function o(e){var t;let i=n?.Parent?new a:this;r(i,e),(t=i._zod).deferred??(t.deferred=[]);for(let e of i._zod.deferred)e();return i}return Object.defineProperty(o,`init`,{value:r}),Object.defineProperty(o,Symbol.hasInstance,{value:t=>n?.Parent&&t instanceof n.Parent?!0:t?._zod?.traits?.has(e)}),Object.defineProperty(o,`name`,{value:e}),o}var n=class extends Error{constructor(){super(`Encountered Promise during synchronous parse. Use .parseAsync() instead.`)}},r=class extends Error{constructor(e){super(`Encountered unidirectional transform during encode: ${e}`),this.name=`ZodEncodeError`}};(e=globalThis).__zod_globalConfig??(e.__zod_globalConfig={});var i=globalThis.__zod_globalConfig;function a(e){return e&&Object.assign(i,e),i}function o(e){let t=Object.values(e).filter(e=>typeof e==`number`);return Object.entries(e).filter(([e,n])=>t.indexOf(+e)===-1).map(([e,t])=>t)}function s(e,t){return typeof t==`bigint`?t.toString():t}function c(e){return{get value(){{let t=e();return Object.defineProperty(this,`value`,{value:t}),t}throw Error(`cached value already set`)}}}function l(e){return e==null}function u(e){let t=+!!e.startsWith(`^`),n=e.endsWith(`$`)?e.length-1:e.length;return e.slice(t,n)}function d(e,t){let n=e/t,r=Math.round(n),i=2**-52*Math.max(Math.abs(n),1);return Math.abs(n-r)<i?0:n-r}var ee=Symbol(`evaluating`);function f(e,t,n){let r;Object.defineProperty(e,t,{get(){if(r!==ee)return r===void 0&&(r=ee,r=n()),r},set(n){Object.defineProperty(e,t,{value:n})},configurable:!0})}function p(e,t,n){Object.defineProperty(e,t,{value:n,writable:!0,enumerable:!0,configurable:!0})}function m(...e){let t={};for(let n of e)Object.assign(t,Object.getOwnPropertyDescriptors(n));return Object.defineProperties({},t)}function te(e){return JSON.stringify(e)}function ne(e){return e.toLowerCase().trim().replace(/[^\w\s-]/g,``).replace(/[\s_-]+/g,`-`).replace(/^-+|-+$/g,``)}var re=`captureStackTrace`in Error?Error.captureStackTrace:(...e)=>{};function ie(e){return typeof e==`object`&&!!e&&!Array.isArray(e)}var ae=c(()=>{if(i.jitless||typeof navigator<`u`&&navigator?.userAgent?.includes(`Cloudflare`))return!1;try{return Function(``),!0}catch{return!1}});function h(e){if(ie(e)===!1)return!1;let t=e.constructor;if(t===void 0||typeof t!=`function`)return!0;let n=t.prototype;return!(ie(n)===!1||Object.prototype.hasOwnProperty.call(n,`isPrototypeOf`)===!1)}function oe(e){return h(e)?{...e}:Array.isArray(e)?[...e]:e instanceof Map?new Map(e):e instanceof Set?new Set(e):e}var se=new Set([`string`,`number`,`symbol`]);function g(e){return e.replace(/[.*+?^${}()|[\]\\]/g,`\\$&`)}function _(e,t,n){let r=new e._zod.constr(t??e._zod.def);return(!t||n?.parent)&&(r._zod.parent=e),r}function v(e){let t=e;if(!t)return{};if(typeof t==`string`)return{error:()=>t};if(t?.message!==void 0){if(t?.error!==void 0)throw Error("Cannot specify both `message` and `error` params");t.error=t.message}return delete t.message,typeof t.error==`string`?{...t,error:()=>t.error}:t}function ce(e){return Object.keys(e).filter(t=>e[t]._zod.optin===`optional`&&e[t]._zod.optout===`optional`)}var le={safeint:[-(2**53-1),2**53-1],int32:[-2147483648,2147483647],uint32:[0,4294967295],float32:[-34028234663852886e22,34028234663852886e22],float64:[-Number.MAX_VALUE,Number.MAX_VALUE]};function ue(e,t){let n=e._zod.def,r=n.checks;if(r&&r.length>0)throw Error(`.pick() cannot be used on object schemas containing refinements`);return _(e,m(e._zod.def,{get shape(){let e={};for(let r in t){if(!(r in n.shape))throw Error(`Unrecognized key: "${r}"`);t[r]&&(e[r]=n.shape[r])}return p(this,`shape`,e),e},checks:[]}))}function de(e,t){let n=e._zod.def,r=n.checks;if(r&&r.length>0)throw Error(`.omit() cannot be used on object schemas containing refinements`);return _(e,m(e._zod.def,{get shape(){let r={...e._zod.def.shape};for(let e in t){if(!(e in n.shape))throw Error(`Unrecognized key: "${e}"`);t[e]&&delete r[e]}return p(this,`shape`,r),r},checks:[]}))}function fe(e,t){if(!h(t))throw Error(`Invalid input to extend: expected a plain object`);let n=e._zod.def.checks;if(n&&n.length>0){let n=e._zod.def.shape;for(let e in t)if(Object.getOwnPropertyDescriptor(n,e)!==void 0)throw Error("Cannot overwrite keys on object schemas containing refinements. Use `.safeExtend()` instead.")}return _(e,m(e._zod.def,{get shape(){let n={...e._zod.def.shape,...t};return p(this,`shape`,n),n}}))}function pe(e,t){if(!h(t))throw Error(`Invalid input to safeExtend: expected a plain object`);return _(e,m(e._zod.def,{get shape(){let n={...e._zod.def.shape,...t};return p(this,`shape`,n),n}}))}function me(e,t){if(e._zod.def.checks?.length)throw Error(`.merge() cannot be used on object schemas containing refinements. Use .safeExtend() instead.`);return _(e,m(e._zod.def,{get shape(){let n={...e._zod.def.shape,...t._zod.def.shape};return p(this,`shape`,n),n},get catchall(){return t._zod.def.catchall},checks:t._zod.def.checks??[]}))}function he(e,t,n){let r=t._zod.def.checks;if(r&&r.length>0)throw Error(`.partial() cannot be used on object schemas containing refinements`);return _(t,m(t._zod.def,{get shape(){let r=t._zod.def.shape,i={...r};if(n)for(let t in n){if(!(t in r))throw Error(`Unrecognized key: "${t}"`);n[t]&&(i[t]=e?new e({type:`optional`,innerType:r[t]}):r[t])}else for(let t in r)i[t]=e?new e({type:`optional`,innerType:r[t]}):r[t];return p(this,`shape`,i),i},checks:[]}))}function ge(e,t,n){return _(t,m(t._zod.def,{get shape(){let r=t._zod.def.shape,i={...r};if(n)for(let t in n){if(!(t in i))throw Error(`Unrecognized key: "${t}"`);n[t]&&(i[t]=new e({type:`nonoptional`,innerType:r[t]}))}else for(let t in r)i[t]=new e({type:`nonoptional`,innerType:r[t]});return p(this,`shape`,i),i}}))}function _e(e,t=0){if(e.aborted===!0)return!0;for(let n=t;n<e.issues.length;n++)if(e.issues[n]?.continue!==!0)return!0;return!1}function ve(e,t=0){if(e.aborted===!0)return!0;for(let n=t;n<e.issues.length;n++)if(e.issues[n]?.continue===!1)return!0;return!1}function y(e,t){return t.map(t=>{var n;return(n=t).path??(n.path=[]),t.path.unshift(e),t})}function ye(e){return typeof e==`string`?e:e?.message}function b(e,t,n){let r=e.message?e.message:ye(e.inst?._zod.def?.error?.(e))??ye(t?.error?.(e))??ye(n.customError?.(e))??ye(n.localeError?.(e))??`Invalid input`,{inst:i,continue:a,input:o,...s}=e;return s.path??=[],s.message=r,t?.reportInput&&(s.input=o),s}function be(e){return Array.isArray(e)?`array`:typeof e==`string`?`string`:`unknown`}function xe(...e){let[t,n,r]=e;return typeof t==`string`?{message:t,code:`custom`,input:n,inst:r}:{...t}}var Se=(e,t)=>{e.name=`$ZodError`,Object.defineProperty(e,`_zod`,{value:e._zod,enumerable:!1}),Object.defineProperty(e,`issues`,{value:t,enumerable:!1}),e.message=JSON.stringify(t,s,2),Object.defineProperty(e,`toString`,{value:()=>e.message,enumerable:!1})},Ce=t(`$ZodError`,Se),we=t(`$ZodError`,Se,{Parent:Error});function Te(e,t=e=>e.message){let n={},r=[];for(let i of e.issues)i.path.length>0?(n[i.path[0]]=n[i.path[0]]||[],n[i.path[0]].push(t(i))):r.push(t(i));return{formErrors:r,fieldErrors:n}}function Ee(e,t=e=>e.message){let n={_errors:[]},r=(e,i=[])=>{for(let a of e.issues)if(a.code===`invalid_union`&&a.errors.length)a.errors.map(e=>r({issues:e},[...i,...a.path]));else if(a.code===`invalid_key`)r({issues:a.issues},[...i,...a.path]);else if(a.code===`invalid_element`)r({issues:a.issues},[...i,...a.path]);else{let e=[...i,...a.path];if(e.length===0)n._errors.push(t(a));else{let r=n,i=0;for(;i<e.length;){let n=e[i];i===e.length-1?(r[n]=r[n]||{_errors:[]},r[n]._errors.push(t(a))):r[n]=r[n]||{_errors:[]},r=r[n],i++}}}};return r(e),n}var De=e=>(t,r,i,o)=>{let s=i?{...i,async:!1}:{async:!1},c=t._zod.run({value:r,issues:[]},s);if(c instanceof Promise)throw new n;if(c.issues.length){let t=new(o?.Err??e)(c.issues.map(e=>b(e,s,a())));throw re(t,o?.callee),t}return c.value},Oe=e=>async(t,n,r,i)=>{let o=r?{...r,async:!0}:{async:!0},s=t._zod.run({value:n,issues:[]},o);if(s instanceof Promise&&(s=await s),s.issues.length){let t=new(i?.Err??e)(s.issues.map(e=>b(e,o,a())));throw re(t,i?.callee),t}return s.value},ke=e=>(t,r,i)=>{let o=i?{...i,async:!1}:{async:!1},s=t._zod.run({value:r,issues:[]},o);if(s instanceof Promise)throw new n;return s.issues.length?{success:!1,error:new(e??Ce)(s.issues.map(e=>b(e,o,a())))}:{success:!0,data:s.value}},Ae=ke(we),je=e=>async(t,n,r)=>{let i=r?{...r,async:!0}:{async:!0},o=t._zod.run({value:n,issues:[]},i);return o instanceof Promise&&(o=await o),o.issues.length?{success:!1,error:new e(o.issues.map(e=>b(e,i,a())))}:{success:!0,data:o.value}},Me=je(we),Ne=e=>(t,n,r)=>{let i=r?{...r,direction:`backward`}:{direction:`backward`};return De(e)(t,n,i)},Pe=e=>(t,n,r)=>De(e)(t,n,r),Fe=e=>async(t,n,r)=>{let i=r?{...r,direction:`backward`}:{direction:`backward`};return Oe(e)(t,n,i)},Ie=e=>async(t,n,r)=>Oe(e)(t,n,r),Le=e=>(t,n,r)=>{let i=r?{...r,direction:`backward`}:{direction:`backward`};return ke(e)(t,n,i)},Re=e=>(t,n,r)=>ke(e)(t,n,r),ze=e=>async(t,n,r)=>{let i=r?{...r,direction:`backward`}:{direction:`backward`};return je(e)(t,n,i)},Be=e=>async(t,n,r)=>je(e)(t,n,r),Ve=/^[cC][0-9a-z]{6,}$/,He=/^[0-9a-z]+$/,Ue=/^[0-9A-HJKMNP-TV-Za-hjkmnp-tv-z]{26}$/,We=/^[0-9a-vA-V]{20}$/,Ge=/^[A-Za-z0-9]{27}$/,Ke=/^[a-zA-Z0-9_-]{21}$/,qe=/^P(?:(\d+W)|(?!.*W)(?=\d|T\d)(\d+Y)?(\d+M)?(\d+D)?(T(?=\d)(\d+H)?(\d+M)?(\d+([.,]\d+)?S)?)?)$/,Je=/^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$/,Ye=e=>e?RegExp(`^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-${e}[0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12})$`):/^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$/,Xe=/^(?!\.)(?!.*\.\.)([A-Za-z0-9_'+\-\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\-]*\.)+[A-Za-z]{2,}$/,Ze=`^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$`;function Qe(){return new RegExp(Ze,`u`)}var $e=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/,et=/^(([0-9a-fA-F]{1,4}:){7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:))$/,tt=/^((25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\/([0-9]|[1-2][0-9]|3[0-2])$/,nt=/^(([0-9a-fA-F]{1,4}:){7}[0-9a-fA-F]{1,4}|::|([0-9a-fA-F]{1,4})?::([0-9a-fA-F]{1,4}:?){0,6})\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/,rt=/^$|^(?:[0-9a-zA-Z+/]{4})*(?:(?:[0-9a-zA-Z+/]{2}==)|(?:[0-9a-zA-Z+/]{3}=))?$/,it=/^[A-Za-z0-9_-]*$/,at=/^https?$/,ot=/^\+[1-9]\d{6,14}$/,st=`(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))`,ct=RegExp(`^${st}$`);function lt(e){let t=`(?:[01]\\d|2[0-3]):[0-5]\\d`;return typeof e.precision==`number`?e.precision===-1?`${t}`:e.precision===0?`${t}:[0-5]\\d`:`${t}:[0-5]\\d\\.\\d{${e.precision}}`:`${t}(?::[0-5]\\d(?:\\.\\d+)?)?`}function ut(e){return RegExp(`^${lt(e)}$`)}function dt(e){let t=lt({precision:e.precision}),n=[`Z`];e.local&&n.push(``),e.offset&&n.push(`([+-](?:[01]\\d|2[0-3]):[0-5]\\d)`);let r=`${t}(?:${n.join(`|`)})`;return RegExp(`^${st}T(?:${r})$`)}var ft=e=>{let t=e?`[\\s\\S]{${e?.minimum??0},${e?.maximum??``}}`:`[\\s\\S]*`;return RegExp(`^${t}$`)},pt=/^-?\d+$/,mt=/^-?\d+(?:\.\d+)?$/,ht=/^(?:true|false)$/i,gt=/^null$/i,_t=/^[^A-Z]*$/,vt=/^[^a-z]*$/,x=t(`$ZodCheck`,(e,t)=>{var n;e._zod??={},e._zod.def=t,(n=e._zod).onattach??(n.onattach=[])}),yt={number:`number`,bigint:`bigint`,object:`date`},bt=t(`$ZodCheckLessThan`,(e,t)=>{x.init(e,t);let n=yt[typeof t.value];e._zod.onattach.push(e=>{let n=e._zod.bag,r=(t.inclusive?n.maximum:n.exclusiveMaximum)??1/0;t.value<r&&(t.inclusive?n.maximum=t.value:n.exclusiveMaximum=t.value)}),e._zod.check=r=>{(t.inclusive?r.value<=t.value:r.value<t.value)||r.issues.push({origin:n,code:`too_big`,maximum:typeof t.value==`object`?t.value.getTime():t.value,input:r.value,inclusive:t.inclusive,inst:e,continue:!t.abort})}}),xt=t(`$ZodCheckGreaterThan`,(e,t)=>{x.init(e,t);let n=yt[typeof t.value];e._zod.onattach.push(e=>{let n=e._zod.bag,r=(t.inclusive?n.minimum:n.exclusiveMinimum)??-1/0;t.value>r&&(t.inclusive?n.minimum=t.value:n.exclusiveMinimum=t.value)}),e._zod.check=r=>{(t.inclusive?r.value>=t.value:r.value>t.value)||r.issues.push({origin:n,code:`too_small`,minimum:typeof t.value==`object`?t.value.getTime():t.value,input:r.value,inclusive:t.inclusive,inst:e,continue:!t.abort})}}),St=t(`$ZodCheckMultipleOf`,(e,t)=>{x.init(e,t),e._zod.onattach.push(e=>{var n;(n=e._zod.bag).multipleOf??(n.multipleOf=t.value)}),e._zod.check=n=>{if(typeof n.value!=typeof t.value)throw Error(`Cannot mix number and bigint in multiple_of check.`);(typeof n.value==`bigint`?n.value%t.value===BigInt(0):d(n.value,t.value)===0)||n.issues.push({origin:typeof n.value,code:`not_multiple_of`,divisor:t.value,input:n.value,inst:e,continue:!t.abort})}}),Ct=t(`$ZodCheckNumberFormat`,(e,t)=>{x.init(e,t),t.format=t.format||`float64`;let n=t.format?.includes(`int`),r=n?`int`:`number`,[i,a]=le[t.format];e._zod.onattach.push(e=>{let r=e._zod.bag;r.format=t.format,r.minimum=i,r.maximum=a,n&&(r.pattern=pt)}),e._zod.check=o=>{let s=o.value;if(n){if(!Number.isInteger(s)){o.issues.push({expected:r,format:t.format,code:`invalid_type`,continue:!1,input:s,inst:e});return}if(!Number.isSafeInteger(s)){s>0?o.issues.push({input:s,code:`too_big`,maximum:2**53-1,note:`Integers must be within the safe integer range.`,inst:e,origin:r,inclusive:!0,continue:!t.abort}):o.issues.push({input:s,code:`too_small`,minimum:-(2**53-1),note:`Integers must be within the safe integer range.`,inst:e,origin:r,inclusive:!0,continue:!t.abort});return}}s<i&&o.issues.push({origin:`number`,input:s,code:`too_small`,minimum:i,inclusive:!0,inst:e,continue:!t.abort}),s>a&&o.issues.push({origin:`number`,input:s,code:`too_big`,maximum:a,inclusive:!0,inst:e,continue:!t.abort})}}),wt=t(`$ZodCheckMaxLength`,(e,t)=>{var n;x.init(e,t),(n=e._zod.def).when??(n.when=e=>{let t=e.value;return!l(t)&&t.length!==void 0}),e._zod.onattach.push(e=>{let n=e._zod.bag.maximum??1/0;t.maximum<n&&(e._zod.bag.maximum=t.maximum)}),e._zod.check=n=>{let r=n.value;if(r.length<=t.maximum)return;let i=be(r);n.issues.push({origin:i,code:`too_big`,maximum:t.maximum,inclusive:!0,input:r,inst:e,continue:!t.abort})}}),Tt=t(`$ZodCheckMinLength`,(e,t)=>{var n;x.init(e,t),(n=e._zod.def).when??(n.when=e=>{let t=e.value;return!l(t)&&t.length!==void 0}),e._zod.onattach.push(e=>{let n=e._zod.bag.minimum??-1/0;t.minimum>n&&(e._zod.bag.minimum=t.minimum)}),e._zod.check=n=>{let r=n.value;if(r.length>=t.minimum)return;let i=be(r);n.issues.push({origin:i,code:`too_small`,minimum:t.minimum,inclusive:!0,input:r,inst:e,continue:!t.abort})}}),Et=t(`$ZodCheckLengthEquals`,(e,t)=>{var n;x.init(e,t),(n=e._zod.def).when??(n.when=e=>{let t=e.value;return!l(t)&&t.length!==void 0}),e._zod.onattach.push(e=>{let n=e._zod.bag;n.minimum=t.length,n.maximum=t.length,n.length=t.length}),e._zod.check=n=>{let r=n.value,i=r.length;if(i===t.length)return;let a=be(r),o=i>t.length;n.issues.push({origin:a,...o?{code:`too_big`,maximum:t.length}:{code:`too_small`,minimum:t.length},inclusive:!0,exact:!0,input:n.value,inst:e,continue:!t.abort})}}),Dt=t(`$ZodCheckStringFormat`,(e,t)=>{var n,r;x.init(e,t),e._zod.onattach.push(e=>{let n=e._zod.bag;n.format=t.format,t.pattern&&(n.patterns??=new Set,n.patterns.add(t.pattern))}),t.pattern?(n=e._zod).check??(n.check=n=>{t.pattern.lastIndex=0,!t.pattern.test(n.value)&&n.issues.push({origin:`string`,code:`invalid_format`,format:t.format,input:n.value,...t.pattern?{pattern:t.pattern.toString()}:{},inst:e,continue:!t.abort})}):(r=e._zod).check??(r.check=()=>{})}),Ot=t(`$ZodCheckRegex`,(e,t)=>{Dt.init(e,t),e._zod.check=n=>{t.pattern.lastIndex=0,!t.pattern.test(n.value)&&n.issues.push({origin:`string`,code:`invalid_format`,format:`regex`,input:n.value,pattern:t.pattern.toString(),inst:e,continue:!t.abort})}}),kt=t(`$ZodCheckLowerCase`,(e,t)=>{t.pattern??=_t,Dt.init(e,t)}),At=t(`$ZodCheckUpperCase`,(e,t)=>{t.pattern??=vt,Dt.init(e,t)}),jt=t(`$ZodCheckIncludes`,(e,t)=>{x.init(e,t);let n=g(t.includes),r=new RegExp(typeof t.position==`number`?`^.{${t.position}}${n}`:n);t.pattern=r,e._zod.onattach.push(e=>{let t=e._zod.bag;t.patterns??=new Set,t.patterns.add(r)}),e._zod.check=n=>{n.value.includes(t.includes,t.position)||n.issues.push({origin:`string`,code:`invalid_format`,format:`includes`,includes:t.includes,input:n.value,inst:e,continue:!t.abort})}}),Mt=t(`$ZodCheckStartsWith`,(e,t)=>{x.init(e,t);let n=RegExp(`^${g(t.prefix)}.*`);t.pattern??=n,e._zod.onattach.push(e=>{let t=e._zod.bag;t.patterns??=new Set,t.patterns.add(n)}),e._zod.check=n=>{n.value.startsWith(t.prefix)||n.issues.push({origin:`string`,code:`invalid_format`,format:`starts_with`,prefix:t.prefix,input:n.value,inst:e,continue:!t.abort})}}),Nt=t(`$ZodCheckEndsWith`,(e,t)=>{x.init(e,t);let n=RegExp(`.*${g(t.suffix)}$`);t.pattern??=n,e._zod.onattach.push(e=>{let t=e._zod.bag;t.patterns??=new Set,t.patterns.add(n)}),e._zod.check=n=>{n.value.endsWith(t.suffix)||n.issues.push({origin:`string`,code:`invalid_format`,format:`ends_with`,suffix:t.suffix,input:n.value,inst:e,continue:!t.abort})}}),Pt=t(`$ZodCheckOverwrite`,(e,t)=>{x.init(e,t),e._zod.check=e=>{e.value=t.tx(e.value)}}),Ft=class{constructor(e=[]){this.content=[],this.indent=0,this&&(this.args=e)}indented(e){this.indent+=1,e(this),--this.indent}write(e){if(typeof e==`function`){e(this,{execution:`sync`}),e(this,{execution:`async`});return}let t=e.split(`
2
+ `).filter(e=>e),n=Math.min(...t.map(e=>e.length-e.trimStart().length)),r=t.map(e=>e.slice(n)).map(e=>` `.repeat(this.indent*2)+e);for(let e of r)this.content.push(e)}compile(){let e=Function,t=this?.args,n=[...(this?.content??[``]).map(e=>` ${e}`)];return new e(...t,n.join(`
3
+ `))}},It={major:4,minor:4,patch:3},S=t(`$ZodType`,(e,t)=>{var r;e??={},e._zod.def=t,e._zod.bag=e._zod.bag||{},e._zod.version=It;let i=[...e._zod.def.checks??[]];e._zod.traits.has(`$ZodCheck`)&&i.unshift(e);for(let t of i)for(let n of t._zod.onattach)n(e);if(i.length===0)(r=e._zod).deferred??(r.deferred=[]),e._zod.deferred?.push(()=>{e._zod.run=e._zod.parse});else{let t=(e,t,r)=>{let i=_e(e),a;for(let o of t){if(o._zod.def.when){if(ve(e)||!o._zod.def.when(e))continue}else if(i)continue;let t=e.issues.length,s=o._zod.check(e);if(s instanceof Promise&&r?.async===!1)throw new n;if(a||s instanceof Promise)a=(a??Promise.resolve()).then(async()=>{await s,e.issues.length!==t&&(i||=_e(e,t))});else{if(e.issues.length===t)continue;i||=_e(e,t)}}return a?a.then(()=>e):e},r=(r,a,o)=>{if(_e(r))return r.aborted=!0,r;let s=t(a,i,o);if(s instanceof Promise){if(o.async===!1)throw new n;return s.then(t=>e._zod.parse(t,o))}return e._zod.parse(s,o)};e._zod.run=(a,o)=>{if(o.skipChecks)return e._zod.parse(a,o);if(o.direction===`backward`){let t=e._zod.parse({value:a.value,issues:[]},{...o,skipChecks:!0});return t instanceof Promise?t.then(e=>r(e,a,o)):r(t,a,o)}let s=e._zod.parse(a,o);if(s instanceof Promise){if(o.async===!1)throw new n;return s.then(e=>t(e,i,o))}return t(s,i,o)}}f(e,`~standard`,()=>({validate:t=>{try{let n=Ae(e,t);return n.success?{value:n.data}:{issues:n.error?.issues}}catch{return Me(e,t).then(e=>e.success?{value:e.data}:{issues:e.error?.issues})}},vendor:`zod`,version:1}))}),Lt=t(`$ZodString`,(e,t)=>{S.init(e,t),e._zod.pattern=[...e?._zod.bag?.patterns??[]].pop()??ft(e._zod.bag),e._zod.parse=(n,r)=>{if(t.coerce)try{n.value=String(n.value)}catch{}return typeof n.value==`string`||n.issues.push({expected:`string`,code:`invalid_type`,input:n.value,inst:e}),n}}),C=t(`$ZodStringFormat`,(e,t)=>{Dt.init(e,t),Lt.init(e,t)}),Rt=t(`$ZodGUID`,(e,t)=>{t.pattern??=Je,C.init(e,t)}),zt=t(`$ZodUUID`,(e,t)=>{if(t.version){let e={v1:1,v2:2,v3:3,v4:4,v5:5,v6:6,v7:7,v8:8}[t.version];if(e===void 0)throw Error(`Invalid UUID version: "${t.version}"`);t.pattern??=Ye(e)}else t.pattern??=Ye();C.init(e,t)}),Bt=t(`$ZodEmail`,(e,t)=>{t.pattern??=Xe,C.init(e,t)}),Vt=t(`$ZodURL`,(e,t)=>{C.init(e,t),e._zod.check=n=>{try{let r=n.value.trim();if(!t.normalize&&t.protocol?.source===at.source&&!/^https?:\/\//i.test(r)){n.issues.push({code:`invalid_format`,format:`url`,note:`Invalid URL format`,input:n.value,inst:e,continue:!t.abort});return}let i=new URL(r);t.hostname&&(t.hostname.lastIndex=0,t.hostname.test(i.hostname)||n.issues.push({code:`invalid_format`,format:`url`,note:`Invalid hostname`,pattern:t.hostname.source,input:n.value,inst:e,continue:!t.abort})),t.protocol&&(t.protocol.lastIndex=0,t.protocol.test(i.protocol.endsWith(`:`)?i.protocol.slice(0,-1):i.protocol)||n.issues.push({code:`invalid_format`,format:`url`,note:`Invalid protocol`,pattern:t.protocol.source,input:n.value,inst:e,continue:!t.abort})),t.normalize?n.value=i.href:n.value=r;return}catch{n.issues.push({code:`invalid_format`,format:`url`,input:n.value,inst:e,continue:!t.abort})}}}),Ht=t(`$ZodEmoji`,(e,t)=>{t.pattern??=Qe(),C.init(e,t)}),Ut=t(`$ZodNanoID`,(e,t)=>{t.pattern??=Ke,C.init(e,t)}),Wt=t(`$ZodCUID`,(e,t)=>{t.pattern??=Ve,C.init(e,t)}),Gt=t(`$ZodCUID2`,(e,t)=>{t.pattern??=He,C.init(e,t)}),Kt=t(`$ZodULID`,(e,t)=>{t.pattern??=Ue,C.init(e,t)}),qt=t(`$ZodXID`,(e,t)=>{t.pattern??=We,C.init(e,t)}),Jt=t(`$ZodKSUID`,(e,t)=>{t.pattern??=Ge,C.init(e,t)}),Yt=t(`$ZodISODateTime`,(e,t)=>{t.pattern??=dt(t),C.init(e,t)}),Xt=t(`$ZodISODate`,(e,t)=>{t.pattern??=ct,C.init(e,t)}),Zt=t(`$ZodISOTime`,(e,t)=>{t.pattern??=ut(t),C.init(e,t)}),Qt=t(`$ZodISODuration`,(e,t)=>{t.pattern??=qe,C.init(e,t)}),$t=t(`$ZodIPv4`,(e,t)=>{t.pattern??=$e,C.init(e,t),e._zod.bag.format=`ipv4`}),en=t(`$ZodIPv6`,(e,t)=>{t.pattern??=et,C.init(e,t),e._zod.bag.format=`ipv6`,e._zod.check=n=>{try{new URL(`http://[${n.value}]`)}catch{n.issues.push({code:`invalid_format`,format:`ipv6`,input:n.value,inst:e,continue:!t.abort})}}}),tn=t(`$ZodCIDRv4`,(e,t)=>{t.pattern??=tt,C.init(e,t)}),nn=t(`$ZodCIDRv6`,(e,t)=>{t.pattern??=nt,C.init(e,t),e._zod.check=n=>{let r=n.value.split(`/`);try{if(r.length!==2)throw Error();let[e,t]=r;if(!t)throw Error();let n=Number(t);if(`${n}`!==t||n<0||n>128)throw Error();new URL(`http://[${e}]`)}catch{n.issues.push({code:`invalid_format`,format:`cidrv6`,input:n.value,inst:e,continue:!t.abort})}}});function rn(e){if(e===``)return!0;if(/\s/.test(e)||e.length%4!=0)return!1;try{return atob(e),!0}catch{return!1}}var an=t(`$ZodBase64`,(e,t)=>{t.pattern??=rt,C.init(e,t),e._zod.bag.contentEncoding=`base64`,e._zod.check=n=>{rn(n.value)||n.issues.push({code:`invalid_format`,format:`base64`,input:n.value,inst:e,continue:!t.abort})}});function on(e){if(!it.test(e))return!1;let t=e.replace(/[-_]/g,e=>e===`-`?`+`:`/`);return rn(t.padEnd(Math.ceil(t.length/4)*4,`=`))}var sn=t(`$ZodBase64URL`,(e,t)=>{t.pattern??=it,C.init(e,t),e._zod.bag.contentEncoding=`base64url`,e._zod.check=n=>{on(n.value)||n.issues.push({code:`invalid_format`,format:`base64url`,input:n.value,inst:e,continue:!t.abort})}}),cn=t(`$ZodE164`,(e,t)=>{t.pattern??=ot,C.init(e,t)});function ln(e,t=null){try{let n=e.split(`.`);if(n.length!==3)return!1;let[r]=n;if(!r)return!1;let i=JSON.parse(atob(r));return!(`typ`in i&&i?.typ!==`JWT`||!i.alg||t&&(!(`alg`in i)||i.alg!==t))}catch{return!1}}var un=t(`$ZodJWT`,(e,t)=>{C.init(e,t),e._zod.check=n=>{ln(n.value,t.alg)||n.issues.push({code:`invalid_format`,format:`jwt`,input:n.value,inst:e,continue:!t.abort})}}),dn=t(`$ZodNumber`,(e,t)=>{S.init(e,t),e._zod.pattern=e._zod.bag.pattern??mt,e._zod.parse=(n,r)=>{if(t.coerce)try{n.value=Number(n.value)}catch{}let i=n.value;if(typeof i==`number`&&!Number.isNaN(i)&&Number.isFinite(i))return n;let a=typeof i==`number`?Number.isNaN(i)?`NaN`:Number.isFinite(i)?void 0:`Infinity`:void 0;return n.issues.push({expected:`number`,code:`invalid_type`,input:i,inst:e,...a?{received:a}:{}}),n}}),fn=t(`$ZodNumberFormat`,(e,t)=>{Ct.init(e,t),dn.init(e,t)}),pn=t(`$ZodBoolean`,(e,t)=>{S.init(e,t),e._zod.pattern=ht,e._zod.parse=(n,r)=>{if(t.coerce)try{n.value=!!n.value}catch{}let i=n.value;return typeof i==`boolean`||n.issues.push({expected:`boolean`,code:`invalid_type`,input:i,inst:e}),n}}),mn=t(`$ZodNull`,(e,t)=>{S.init(e,t),e._zod.pattern=gt,e._zod.values=new Set([null]),e._zod.parse=(t,n)=>{let r=t.value;return r===null||t.issues.push({expected:`null`,code:`invalid_type`,input:r,inst:e}),t}}),hn=t(`$ZodUnknown`,(e,t)=>{S.init(e,t),e._zod.parse=e=>e}),gn=t(`$ZodNever`,(e,t)=>{S.init(e,t),e._zod.parse=(t,n)=>(t.issues.push({expected:`never`,code:`invalid_type`,input:t.value,inst:e}),t)});function _n(e,t,n){e.issues.length&&t.issues.push(...y(n,e.issues)),t.value[n]=e.value}var vn=t(`$ZodArray`,(e,t)=>{S.init(e,t),e._zod.parse=(n,r)=>{let i=n.value;if(!Array.isArray(i))return n.issues.push({expected:`array`,code:`invalid_type`,input:i,inst:e}),n;n.value=Array(i.length);let a=[];for(let e=0;e<i.length;e++){let o=i[e],s=t.element._zod.run({value:o,issues:[]},r);s instanceof Promise?a.push(s.then(t=>_n(t,n,e))):_n(s,n,e)}return a.length?Promise.all(a).then(()=>n):n}});function yn(e,t,n,r,i,a){let o=n in r;if(e.issues.length){if(i&&a&&!o)return;t.issues.push(...y(n,e.issues))}if(!o&&!i){e.issues.length||t.issues.push({code:`invalid_type`,expected:`nonoptional`,input:void 0,path:[n]});return}e.value===void 0?o&&(t.value[n]=void 0):t.value[n]=e.value}function bn(e){let t=Object.keys(e.shape);for(let n of t)if(!e.shape?.[n]?._zod?.traits?.has(`$ZodType`))throw Error(`Invalid element at key "${n}": expected a Zod schema`);let n=ce(e.shape);return{...e,keys:t,keySet:new Set(t),numKeys:t.length,optionalKeys:new Set(n)}}function xn(e,t,n,r,i,a){let o=[],s=i.keySet,c=i.catchall._zod,l=c.def.type,u=c.optin===`optional`,d=c.optout===`optional`;for(let i in t){if(i===`__proto__`||s.has(i))continue;if(l===`never`){o.push(i);continue}let a=c.run({value:t[i],issues:[]},r);a instanceof Promise?e.push(a.then(e=>yn(e,n,i,t,u,d))):yn(a,n,i,t,u,d)}return o.length&&n.issues.push({code:`unrecognized_keys`,keys:o,input:t,inst:a}),e.length?Promise.all(e).then(()=>n):n}var Sn=t(`$ZodObject`,(e,t)=>{if(S.init(e,t),!Object.getOwnPropertyDescriptor(t,`shape`)?.get){let e=t.shape;Object.defineProperty(t,`shape`,{get:()=>{let n={...e};return Object.defineProperty(t,`shape`,{value:n}),n}})}let n=c(()=>bn(t));f(e._zod,`propValues`,()=>{let e=t.shape,n={};for(let t in e){let r=e[t]._zod;if(r.values){n[t]??(n[t]=new Set);for(let e of r.values)n[t].add(e)}}return n});let r=ie,i=t.catchall,a;e._zod.parse=(t,o)=>{a??=n.value;let s=t.value;if(!r(s))return t.issues.push({expected:`object`,code:`invalid_type`,input:s,inst:e}),t;t.value={};let c=[],l=a.shape;for(let e of a.keys){let n=l[e],r=n._zod.optin===`optional`,i=n._zod.optout===`optional`,a=n._zod.run({value:s[e],issues:[]},o);a instanceof Promise?c.push(a.then(n=>yn(n,t,e,s,r,i))):yn(a,t,e,s,r,i)}return i?xn(c,s,t,o,n.value,e):c.length?Promise.all(c).then(()=>t):t}}),Cn=t(`$ZodObjectJIT`,(e,t)=>{Sn.init(e,t);let n=e._zod.parse,r=c(()=>bn(t)),a=e=>{let t=new Ft([`shape`,`payload`,`ctx`]),n=r.value,i=e=>{let t=te(e);return`shape[${t}]._zod.run({ value: input[${t}], issues: [] }, ctx)`};t.write(`const input = payload.value;`);let a=Object.create(null),o=0;for(let e of n.keys)a[e]=`key_${o++}`;t.write(`const newResult = {};`);for(let r of n.keys){let n=a[r],o=te(r),s=e[r],c=s?._zod?.optin===`optional`,l=s?._zod?.optout===`optional`;t.write(`const ${n} = ${i(r)};`),c&&l?t.write(`
4
+ if (${n}.issues.length) {
5
+ if (${o} in input) {
6
+ payload.issues = payload.issues.concat(${n}.issues.map(iss => ({
7
+ ...iss,
8
+ path: iss.path ? [${o}, ...iss.path] : [${o}]
9
+ })));
10
+ }
11
+ }
12
+
13
+ if (${n}.value === undefined) {
14
+ if (${o} in input) {
15
+ newResult[${o}] = undefined;
16
+ }
17
+ } else {
18
+ newResult[${o}] = ${n}.value;
19
+ }
20
+
21
+ `):c?t.write(`
22
+ if (${n}.issues.length) {
23
+ payload.issues = payload.issues.concat(${n}.issues.map(iss => ({
24
+ ...iss,
25
+ path: iss.path ? [${o}, ...iss.path] : [${o}]
26
+ })));
27
+ }
28
+
29
+ if (${n}.value === undefined) {
30
+ if (${o} in input) {
31
+ newResult[${o}] = undefined;
32
+ }
33
+ } else {
34
+ newResult[${o}] = ${n}.value;
35
+ }
36
+
37
+ `):t.write(`
38
+ const ${n}_present = ${o} in input;
39
+ if (${n}.issues.length) {
40
+ payload.issues = payload.issues.concat(${n}.issues.map(iss => ({
41
+ ...iss,
42
+ path: iss.path ? [${o}, ...iss.path] : [${o}]
43
+ })));
44
+ }
45
+ if (!${n}_present && !${n}.issues.length) {
46
+ payload.issues.push({
47
+ code: "invalid_type",
48
+ expected: "nonoptional",
49
+ input: undefined,
50
+ path: [${o}]
51
+ });
52
+ }
53
+
54
+ if (${n}_present) {
55
+ if (${n}.value === undefined) {
56
+ newResult[${o}] = undefined;
57
+ } else {
58
+ newResult[${o}] = ${n}.value;
59
+ }
60
+ }
61
+
62
+ `)}t.write(`payload.value = newResult;`),t.write(`return payload;`);let s=t.compile();return(t,n)=>s(e,t,n)},o,s=ie,l=!i.jitless,u=l&&ae.value,d=t.catchall,ee;e._zod.parse=(i,c)=>{ee??=r.value;let f=i.value;return s(f)?l&&u&&c?.async===!1&&c.jitless!==!0?(o||=a(t.shape),i=o(i,c),d?xn([],f,i,c,ee,e):i):n(i,c):(i.issues.push({expected:`object`,code:`invalid_type`,input:f,inst:e}),i)}});function wn(e,t,n,r){for(let n of e)if(n.issues.length===0)return t.value=n.value,t;let i=e.filter(e=>!_e(e));return i.length===1?(t.value=i[0].value,i[0]):(t.issues.push({code:`invalid_union`,input:t.value,inst:n,errors:e.map(e=>e.issues.map(e=>b(e,r,a())))}),t)}var Tn=t(`$ZodUnion`,(e,t)=>{S.init(e,t),f(e._zod,`optin`,()=>t.options.some(e=>e._zod.optin===`optional`)?`optional`:void 0),f(e._zod,`optout`,()=>t.options.some(e=>e._zod.optout===`optional`)?`optional`:void 0),f(e._zod,`values`,()=>{if(t.options.every(e=>e._zod.values))return new Set(t.options.flatMap(e=>Array.from(e._zod.values)))}),f(e._zod,`pattern`,()=>{if(t.options.every(e=>e._zod.pattern)){let e=t.options.map(e=>e._zod.pattern);return RegExp(`^(${e.map(e=>u(e.source)).join(`|`)})$`)}});let n=t.options.length===1?t.options[0]._zod.run:null;e._zod.parse=(r,i)=>{if(n)return n(r,i);let a=!1,o=[];for(let e of t.options){let t=e._zod.run({value:r.value,issues:[]},i);if(t instanceof Promise)o.push(t),a=!0;else{if(t.issues.length===0)return t;o.push(t)}}return a?Promise.all(o).then(t=>wn(t,r,e,i)):wn(o,r,e,i)}}),En=t(`$ZodDiscriminatedUnion`,(e,t)=>{t.inclusive=!1,Tn.init(e,t);let n=e._zod.parse;f(e._zod,`propValues`,()=>{let e={};for(let n of t.options){let r=n._zod.propValues;if(!r||Object.keys(r).length===0)throw Error(`Invalid discriminated union option at index "${t.options.indexOf(n)}"`);for(let[t,n]of Object.entries(r)){e[t]||(e[t]=new Set);for(let r of n)e[t].add(r)}}return e});let r=c(()=>{let e=t.options,n=new Map;for(let r of e){let e=r._zod.propValues?.[t.discriminator];if(!e||e.size===0)throw Error(`Invalid discriminated union option at index "${t.options.indexOf(r)}"`);for(let t of e){if(n.has(t))throw Error(`Duplicate discriminator value "${String(t)}"`);n.set(t,r)}}return n});e._zod.parse=(i,a)=>{let o=i.value;if(!ie(o))return i.issues.push({code:`invalid_type`,expected:`object`,input:o,inst:e}),i;let s=r.value.get(o?.[t.discriminator]);return s?s._zod.run(i,a):t.unionFallback||a.direction===`backward`?n(i,a):(i.issues.push({code:`invalid_union`,errors:[],note:`No matching discriminator`,discriminator:t.discriminator,options:Array.from(r.value.keys()),input:o,path:[t.discriminator],inst:e}),i)}}),Dn=t(`$ZodIntersection`,(e,t)=>{S.init(e,t),e._zod.parse=(e,n)=>{let r=e.value,i=t.left._zod.run({value:r,issues:[]},n),a=t.right._zod.run({value:r,issues:[]},n);return i instanceof Promise||a instanceof Promise?Promise.all([i,a]).then(([t,n])=>kn(e,t,n)):kn(e,i,a)}});function On(e,t){if(e===t||e instanceof Date&&t instanceof Date&&+e==+t)return{valid:!0,data:e};if(h(e)&&h(t)){let n=Object.keys(t),r=Object.keys(e).filter(e=>n.indexOf(e)!==-1),i={...e,...t};for(let n of r){let r=On(e[n],t[n]);if(!r.valid)return{valid:!1,mergeErrorPath:[n,...r.mergeErrorPath]};i[n]=r.data}return{valid:!0,data:i}}if(Array.isArray(e)&&Array.isArray(t)){if(e.length!==t.length)return{valid:!1,mergeErrorPath:[]};let n=[];for(let r=0;r<e.length;r++){let i=e[r],a=t[r],o=On(i,a);if(!o.valid)return{valid:!1,mergeErrorPath:[r,...o.mergeErrorPath]};n.push(o.data)}return{valid:!0,data:n}}return{valid:!1,mergeErrorPath:[]}}function kn(e,t,n){let r=new Map,i;for(let n of t.issues)if(n.code===`unrecognized_keys`){i??=n;for(let e of n.keys)r.has(e)||r.set(e,{}),r.get(e).l=!0}else e.issues.push(n);for(let t of n.issues)if(t.code===`unrecognized_keys`)for(let e of t.keys)r.has(e)||r.set(e,{}),r.get(e).r=!0;else e.issues.push(t);let a=[...r].filter(([,e])=>e.l&&e.r).map(([e])=>e);if(a.length&&i&&e.issues.push({...i,keys:a}),_e(e))return e;let o=On(t.value,n.value);if(!o.valid)throw Error(`Unmergable intersection. Error path: ${JSON.stringify(o.mergeErrorPath)}`);return e.value=o.data,e}var An=t(`$ZodTuple`,(e,t)=>{S.init(e,t);let n=t.items;e._zod.parse=(r,i)=>{let a=r.value;if(!Array.isArray(a))return r.issues.push({input:a,inst:e,expected:`tuple`,code:`invalid_type`}),r;r.value=[];let o=[],s=jn(n,`optin`),c=jn(n,`optout`);if(!t.rest){if(a.length<s)return r.issues.push({code:`too_small`,minimum:s,inclusive:!0,input:a,inst:e,origin:`array`}),r;a.length>n.length&&r.issues.push({code:`too_big`,maximum:n.length,inclusive:!0,input:a,inst:e,origin:`array`})}let l=Array(n.length);for(let e=0;e<n.length;e++){let t=n[e]._zod.run({value:a[e],issues:[]},i);t instanceof Promise?o.push(t.then(t=>{l[e]=t})):l[e]=t}if(t.rest){let e=n.length-1,s=a.slice(n.length);for(let n of s){e++;let a=t.rest._zod.run({value:n,issues:[]},i);a instanceof Promise?o.push(a.then(t=>Mn(t,r,e))):Mn(a,r,e)}}return o.length?Promise.all(o).then(()=>Nn(l,r,n,a,c)):Nn(l,r,n,a,c)}});function jn(e,t){for(let n=e.length-1;n>=0;n--)if(e[n]._zod[t]!==`optional`)return n+1;return 0}function Mn(e,t,n){e.issues.length&&t.issues.push(...y(n,e.issues)),t.value[n]=e.value}function Nn(e,t,n,r,i){for(let a=0;a<n.length;a++){let n=e[a],o=a<r.length;if(n.issues.length){if(!o&&a>=i){t.value.length=a;break}t.issues.push(...y(a,n.issues))}t.value[a]=n.value}for(let e=t.value.length-1;e>=r.length&&n[e]._zod.optout===`optional`&&t.value[e]===void 0;e--)t.value.length=e;return t}var Pn=t(`$ZodRecord`,(e,t)=>{S.init(e,t),e._zod.parse=(n,r)=>{let i=n.value;if(!h(i))return n.issues.push({expected:`record`,code:`invalid_type`,input:i,inst:e}),n;let o=[],s=t.keyType._zod.values;if(s){n.value={};let c=new Set;for(let l of s)if(typeof l==`string`||typeof l==`number`||typeof l==`symbol`){c.add(typeof l==`number`?l.toString():l);let s=t.keyType._zod.run({value:l,issues:[]},r);if(s instanceof Promise)throw Error(`Async schemas not supported in object keys currently`);if(s.issues.length){n.issues.push({code:`invalid_key`,origin:`record`,issues:s.issues.map(e=>b(e,r,a())),input:l,path:[l],inst:e});continue}let u=s.value,d=t.valueType._zod.run({value:i[l],issues:[]},r);d instanceof Promise?o.push(d.then(e=>{e.issues.length&&n.issues.push(...y(l,e.issues)),n.value[u]=e.value})):(d.issues.length&&n.issues.push(...y(l,d.issues)),n.value[u]=d.value)}let l;for(let e in i)c.has(e)||(l??=[],l.push(e));l&&l.length>0&&n.issues.push({code:`unrecognized_keys`,input:i,inst:e,keys:l})}else{n.value={};for(let s of Reflect.ownKeys(i)){if(s===`__proto__`||!Object.prototype.propertyIsEnumerable.call(i,s))continue;let c=t.keyType._zod.run({value:s,issues:[]},r);if(c instanceof Promise)throw Error(`Async schemas not supported in object keys currently`);if(typeof s==`string`&&mt.test(s)&&c.issues.length){let e=t.keyType._zod.run({value:Number(s),issues:[]},r);if(e instanceof Promise)throw Error(`Async schemas not supported in object keys currently`);e.issues.length===0&&(c=e)}if(c.issues.length){t.mode===`loose`?n.value[s]=i[s]:n.issues.push({code:`invalid_key`,origin:`record`,issues:c.issues.map(e=>b(e,r,a())),input:s,path:[s],inst:e});continue}let l=t.valueType._zod.run({value:i[s],issues:[]},r);l instanceof Promise?o.push(l.then(e=>{e.issues.length&&n.issues.push(...y(s,e.issues)),n.value[c.value]=e.value})):(l.issues.length&&n.issues.push(...y(s,l.issues)),n.value[c.value]=l.value)}}return o.length?Promise.all(o).then(()=>n):n}}),Fn=t(`$ZodEnum`,(e,t)=>{S.init(e,t);let n=o(t.entries),r=new Set(n);e._zod.values=r,e._zod.pattern=RegExp(`^(${n.filter(e=>se.has(typeof e)).map(e=>typeof e==`string`?g(e):e.toString()).join(`|`)})$`),e._zod.parse=(t,i)=>{let a=t.value;return r.has(a)||t.issues.push({code:`invalid_value`,values:n,input:a,inst:e}),t}}),In=t(`$ZodLiteral`,(e,t)=>{if(S.init(e,t),t.values.length===0)throw Error(`Cannot create literal schema with no valid values`);let n=new Set(t.values);e._zod.values=n,e._zod.pattern=RegExp(`^(${t.values.map(e=>typeof e==`string`?g(e):e?g(e.toString()):String(e)).join(`|`)})$`),e._zod.parse=(r,i)=>{let a=r.value;return n.has(a)||r.issues.push({code:`invalid_value`,values:t.values,input:a,inst:e}),r}}),Ln=t(`$ZodTransform`,(e,t)=>{S.init(e,t),e._zod.optin=`optional`,e._zod.parse=(i,a)=>{if(a.direction===`backward`)throw new r(e.constructor.name);let o=t.transform(i.value,i);if(a.async)return(o instanceof Promise?o:Promise.resolve(o)).then(e=>(i.value=e,i.fallback=!0,i));if(o instanceof Promise)throw new n;return i.value=o,i.fallback=!0,i}});function Rn(e,t){return t===void 0&&(e.issues.length||e.fallback)?{issues:[],value:void 0}:e}var zn=t(`$ZodOptional`,(e,t)=>{S.init(e,t),e._zod.optin=`optional`,e._zod.optout=`optional`,f(e._zod,`values`,()=>t.innerType._zod.values?new Set([...t.innerType._zod.values,void 0]):void 0),f(e._zod,`pattern`,()=>{let e=t.innerType._zod.pattern;return e?RegExp(`^(${u(e.source)})?$`):void 0}),e._zod.parse=(e,n)=>{if(t.innerType._zod.optin===`optional`){let r=e.value,i=t.innerType._zod.run(e,n);return i instanceof Promise?i.then(e=>Rn(e,r)):Rn(i,r)}return e.value===void 0?e:t.innerType._zod.run(e,n)}}),Bn=t(`$ZodExactOptional`,(e,t)=>{zn.init(e,t),f(e._zod,`values`,()=>t.innerType._zod.values),f(e._zod,`pattern`,()=>t.innerType._zod.pattern),e._zod.parse=(e,n)=>t.innerType._zod.run(e,n)}),Vn=t(`$ZodNullable`,(e,t)=>{S.init(e,t),f(e._zod,`optin`,()=>t.innerType._zod.optin),f(e._zod,`optout`,()=>t.innerType._zod.optout),f(e._zod,`pattern`,()=>{let e=t.innerType._zod.pattern;return e?RegExp(`^(${u(e.source)}|null)$`):void 0}),f(e._zod,`values`,()=>t.innerType._zod.values?new Set([...t.innerType._zod.values,null]):void 0),e._zod.parse=(e,n)=>e.value===null?e:t.innerType._zod.run(e,n)}),Hn=t(`$ZodDefault`,(e,t)=>{S.init(e,t),e._zod.optin=`optional`,f(e._zod,`values`,()=>t.innerType._zod.values),e._zod.parse=(e,n)=>{if(n.direction===`backward`)return t.innerType._zod.run(e,n);if(e.value===void 0)return e.value=t.defaultValue,e;let r=t.innerType._zod.run(e,n);return r instanceof Promise?r.then(e=>Un(e,t)):Un(r,t)}});function Un(e,t){return e.value===void 0&&(e.value=t.defaultValue),e}var Wn=t(`$ZodPrefault`,(e,t)=>{S.init(e,t),e._zod.optin=`optional`,f(e._zod,`values`,()=>t.innerType._zod.values),e._zod.parse=(e,n)=>(n.direction===`backward`||e.value===void 0&&(e.value=t.defaultValue),t.innerType._zod.run(e,n))}),Gn=t(`$ZodNonOptional`,(e,t)=>{S.init(e,t),f(e._zod,`values`,()=>{let e=t.innerType._zod.values;return e?new Set([...e].filter(e=>e!==void 0)):void 0}),e._zod.parse=(n,r)=>{let i=t.innerType._zod.run(n,r);return i instanceof Promise?i.then(t=>Kn(t,e)):Kn(i,e)}});function Kn(e,t){return!e.issues.length&&e.value===void 0&&e.issues.push({code:`invalid_type`,expected:`nonoptional`,input:e.value,inst:t}),e}var qn=t(`$ZodCatch`,(e,t)=>{S.init(e,t),e._zod.optin=`optional`,f(e._zod,`optout`,()=>t.innerType._zod.optout),f(e._zod,`values`,()=>t.innerType._zod.values),e._zod.parse=(e,n)=>{if(n.direction===`backward`)return t.innerType._zod.run(e,n);let r=t.innerType._zod.run(e,n);return r instanceof Promise?r.then(r=>(e.value=r.value,r.issues.length&&(e.value=t.catchValue({...e,error:{issues:r.issues.map(e=>b(e,n,a()))},input:e.value}),e.issues=[],e.fallback=!0),e)):(e.value=r.value,r.issues.length&&(e.value=t.catchValue({...e,error:{issues:r.issues.map(e=>b(e,n,a()))},input:e.value}),e.issues=[],e.fallback=!0),e)}}),Jn=t(`$ZodPipe`,(e,t)=>{S.init(e,t),f(e._zod,`values`,()=>t.in._zod.values),f(e._zod,`optin`,()=>t.in._zod.optin),f(e._zod,`optout`,()=>t.out._zod.optout),f(e._zod,`propValues`,()=>t.in._zod.propValues),e._zod.parse=(e,n)=>{if(n.direction===`backward`){let r=t.out._zod.run(e,n);return r instanceof Promise?r.then(e=>Yn(e,t.in,n)):Yn(r,t.in,n)}let r=t.in._zod.run(e,n);return r instanceof Promise?r.then(e=>Yn(e,t.out,n)):Yn(r,t.out,n)}});function Yn(e,t,n){return e.issues.length?(e.aborted=!0,e):t._zod.run({value:e.value,issues:e.issues,fallback:e.fallback},n)}var Xn=t(`$ZodReadonly`,(e,t)=>{S.init(e,t),f(e._zod,`propValues`,()=>t.innerType._zod.propValues),f(e._zod,`values`,()=>t.innerType._zod.values),f(e._zod,`optin`,()=>t.innerType?._zod?.optin),f(e._zod,`optout`,()=>t.innerType?._zod?.optout),e._zod.parse=(e,n)=>{if(n.direction===`backward`)return t.innerType._zod.run(e,n);let r=t.innerType._zod.run(e,n);return r instanceof Promise?r.then(Zn):Zn(r)}});function Zn(e){return e.value=Object.freeze(e.value),e}var Qn=t(`$ZodLazy`,(e,t)=>{S.init(e,t),f(e._zod,`innerType`,()=>{let e=t;return e._cachedInner||=t.getter(),e._cachedInner}),f(e._zod,`pattern`,()=>e._zod.innerType?._zod?.pattern),f(e._zod,`propValues`,()=>e._zod.innerType?._zod?.propValues),f(e._zod,`optin`,()=>e._zod.innerType?._zod?.optin??void 0),f(e._zod,`optout`,()=>e._zod.innerType?._zod?.optout??void 0),e._zod.parse=(t,n)=>e._zod.innerType._zod.run(t,n)}),$n=t(`$ZodCustom`,(e,t)=>{x.init(e,t),S.init(e,t),e._zod.parse=(e,t)=>e,e._zod.check=n=>{let r=n.value,i=t.fn(r);if(i instanceof Promise)return i.then(t=>er(t,n,r,e));er(i,n,r,e)}});function er(e,t,n,r){if(!e){let e={code:`custom`,input:n,inst:r,path:[...r._zod.def.path??[]],continue:!r._zod.def.abort};r._zod.def.params&&(e.params=r._zod.def.params),t.issues.push(xe(e))}}var tr,nr=class{constructor(){this._map=new WeakMap,this._idmap=new Map}add(e,...t){let n=t[0];return this._map.set(e,n),n&&typeof n==`object`&&`id`in n&&this._idmap.set(n.id,e),this}clear(){return this._map=new WeakMap,this._idmap=new Map,this}remove(e){let t=this._map.get(e);return t&&typeof t==`object`&&`id`in t&&this._idmap.delete(t.id),this._map.delete(e),this}get(e){let t=e._zod.parent;if(t){let n={...this.get(t)??{}};delete n.id;let r={...n,...this._map.get(e)};return Object.keys(r).length?r:void 0}return this._map.get(e)}has(e){return this._map.has(e)}};function rr(){return new nr}(tr=globalThis).__zod_globalRegistry??(tr.__zod_globalRegistry=rr());var ir=globalThis.__zod_globalRegistry;function ar(e,t){return new e({type:`string`,...v(t)})}function or(e,t){return new e({type:`string`,format:`email`,check:`string_format`,abort:!1,...v(t)})}function sr(e,t){return new e({type:`string`,format:`guid`,check:`string_format`,abort:!1,...v(t)})}function cr(e,t){return new e({type:`string`,format:`uuid`,check:`string_format`,abort:!1,...v(t)})}function lr(e,t){return new e({type:`string`,format:`uuid`,check:`string_format`,abort:!1,version:`v4`,...v(t)})}function ur(e,t){return new e({type:`string`,format:`uuid`,check:`string_format`,abort:!1,version:`v6`,...v(t)})}function dr(e,t){return new e({type:`string`,format:`uuid`,check:`string_format`,abort:!1,version:`v7`,...v(t)})}function fr(e,t){return new e({type:`string`,format:`url`,check:`string_format`,abort:!1,...v(t)})}function pr(e,t){return new e({type:`string`,format:`emoji`,check:`string_format`,abort:!1,...v(t)})}function mr(e,t){return new e({type:`string`,format:`nanoid`,check:`string_format`,abort:!1,...v(t)})}function hr(e,t){return new e({type:`string`,format:`cuid`,check:`string_format`,abort:!1,...v(t)})}function gr(e,t){return new e({type:`string`,format:`cuid2`,check:`string_format`,abort:!1,...v(t)})}function _r(e,t){return new e({type:`string`,format:`ulid`,check:`string_format`,abort:!1,...v(t)})}function vr(e,t){return new e({type:`string`,format:`xid`,check:`string_format`,abort:!1,...v(t)})}function yr(e,t){return new e({type:`string`,format:`ksuid`,check:`string_format`,abort:!1,...v(t)})}function br(e,t){return new e({type:`string`,format:`ipv4`,check:`string_format`,abort:!1,...v(t)})}function xr(e,t){return new e({type:`string`,format:`ipv6`,check:`string_format`,abort:!1,...v(t)})}function Sr(e,t){return new e({type:`string`,format:`cidrv4`,check:`string_format`,abort:!1,...v(t)})}function Cr(e,t){return new e({type:`string`,format:`cidrv6`,check:`string_format`,abort:!1,...v(t)})}function wr(e,t){return new e({type:`string`,format:`base64`,check:`string_format`,abort:!1,...v(t)})}function Tr(e,t){return new e({type:`string`,format:`base64url`,check:`string_format`,abort:!1,...v(t)})}function Er(e,t){return new e({type:`string`,format:`e164`,check:`string_format`,abort:!1,...v(t)})}function Dr(e,t){return new e({type:`string`,format:`jwt`,check:`string_format`,abort:!1,...v(t)})}function Or(e,t){return new e({type:`string`,format:`datetime`,check:`string_format`,offset:!1,local:!1,precision:null,...v(t)})}function kr(e,t){return new e({type:`string`,format:`date`,check:`string_format`,...v(t)})}function Ar(e,t){return new e({type:`string`,format:`time`,check:`string_format`,precision:null,...v(t)})}function jr(e,t){return new e({type:`string`,format:`duration`,check:`string_format`,...v(t)})}function Mr(e,t){return new e({type:`number`,checks:[],...v(t)})}function Nr(e,t){return new e({type:`number`,check:`number_format`,abort:!1,format:`safeint`,...v(t)})}function Pr(e,t){return new e({type:`boolean`,...v(t)})}function Fr(e,t){return new e({type:`null`,...v(t)})}function Ir(e){return new e({type:`unknown`})}function Lr(e,t){return new e({type:`never`,...v(t)})}function Rr(e,t){return new bt({check:`less_than`,...v(t),value:e,inclusive:!1})}function zr(e,t){return new bt({check:`less_than`,...v(t),value:e,inclusive:!0})}function Br(e,t){return new xt({check:`greater_than`,...v(t),value:e,inclusive:!1})}function Vr(e,t){return new xt({check:`greater_than`,...v(t),value:e,inclusive:!0})}function Hr(e,t){return new St({check:`multiple_of`,...v(t),value:e})}function Ur(e,t){return new wt({check:`max_length`,...v(t),maximum:e})}function Wr(e,t){return new Tt({check:`min_length`,...v(t),minimum:e})}function Gr(e,t){return new Et({check:`length_equals`,...v(t),length:e})}function Kr(e,t){return new Ot({check:`string_format`,format:`regex`,...v(t),pattern:e})}function qr(e){return new kt({check:`string_format`,format:`lowercase`,...v(e)})}function Jr(e){return new At({check:`string_format`,format:`uppercase`,...v(e)})}function Yr(e,t){return new jt({check:`string_format`,format:`includes`,...v(t),includes:e})}function Xr(e,t){return new Mt({check:`string_format`,format:`starts_with`,...v(t),prefix:e})}function Zr(e,t){return new Nt({check:`string_format`,format:`ends_with`,...v(t),suffix:e})}function w(e){return new Pt({check:`overwrite`,tx:e})}function Qr(e){return w(t=>t.normalize(e))}function $r(){return w(e=>e.trim())}function ei(){return w(e=>e.toLowerCase())}function ti(){return w(e=>e.toUpperCase())}function ni(){return w(e=>ne(e))}function ri(e,t,n){return new e({type:`array`,element:t,...v(n)})}function ii(e,t,n){let r=v(n);return r.abort??=!0,new e({type:`custom`,check:`custom`,fn:t,...r})}function ai(e,t,n){return new e({type:`custom`,check:`custom`,fn:t,...v(n)})}function oi(e,t){let n=si(t=>(t.addIssue=e=>{if(typeof e==`string`)t.issues.push(xe(e,t.value,n._zod.def));else{let r=e;r.fatal&&(r.continue=!1),r.code??=`custom`,r.input??=t.value,r.inst??=n,r.continue??=!n._zod.def.abort,t.issues.push(xe(r))}},e(t.value,t)),t);return n}function si(e,t){let n=new x({check:`custom`,...v(t)});return n._zod.check=e,n}function ci(e){let t=e?.target??`draft-2020-12`;return t===`draft-4`&&(t=`draft-04`),t===`draft-7`&&(t=`draft-07`),{processors:e.processors??{},metadataRegistry:e?.metadata??ir,target:t,unrepresentable:e?.unrepresentable??`throw`,override:e?.override??(()=>{}),io:e?.io??`output`,counter:0,seen:new Map,cycles:e?.cycles??`ref`,reused:e?.reused??`inline`,external:e?.external??void 0}}function T(e,t,n={path:[],schemaPath:[]}){var r;let i=e._zod.def,a=t.seen.get(e);if(a)return a.count++,n.schemaPath.includes(e)&&(a.cycle=n.path),a.schema;let o={schema:{},count:1,cycle:void 0,path:n.path};t.seen.set(e,o);let s=e._zod.toJSONSchema?.();if(s)o.schema=s;else{let r={...n,schemaPath:[...n.schemaPath,e],path:n.path};if(e._zod.processJSONSchema)e._zod.processJSONSchema(t,o.schema,r);else{let n=o.schema,a=t.processors[i.type];if(!a)throw Error(`[toJSONSchema]: Non-representable type encountered: ${i.type}`);a(e,t,n,r)}let a=e._zod.parent;a&&(o.ref||=a,T(a,t,r),t.seen.get(a).isParent=!0)}let c=t.metadataRegistry.get(e);return c&&Object.assign(o.schema,c),t.io===`input`&&E(e)&&(delete o.schema.examples,delete o.schema.default),t.io===`input`&&`_prefault`in o.schema&&((r=o.schema).default??(r.default=o.schema._prefault)),delete o.schema._prefault,t.seen.get(e).schema}function li(e,t){let n=e.seen.get(t);if(!n)throw Error(`Unprocessed schema. This is a bug in Zod.`);let r=new Map;for(let t of e.seen.entries()){let n=e.metadataRegistry.get(t[0])?.id;if(n){let e=r.get(n);if(e&&e!==t[0])throw Error(`Duplicate schema id "${n}" detected during JSON Schema conversion. Two different schemas cannot share the same id when converted together.`);r.set(n,t[0])}}let i=t=>{let r=e.target===`draft-2020-12`?`$defs`:`definitions`;if(e.external){let n=e.external.registry.get(t[0])?.id,i=e.external.uri??(e=>e);if(n)return{ref:i(n)};let a=t[1].defId??t[1].schema.id??`schema${e.counter++}`;return t[1].defId=a,{defId:a,ref:`${i(`__shared`)}#/${r}/${a}`}}if(t[1]===n)return{ref:`#`};let i=`#/${r}/`,a=t[1].schema.id??`__schema${e.counter++}`;return{defId:a,ref:i+a}},a=e=>{if(e[1].schema.$ref)return;let t=e[1],{ref:n,defId:r}=i(e);t.def={...t.schema},r&&(t.defId=r);let a=t.schema;for(let e in a)delete a[e];a.$ref=n};if(e.cycles===`throw`)for(let t of e.seen.entries()){let e=t[1];if(e.cycle)throw Error(`Cycle detected: #/${e.cycle?.join(`/`)}/<root>
63
+
64
+ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.`)}for(let n of e.seen.entries()){let r=n[1];if(t===n[0]){a(n);continue}if(e.external){let r=e.external.registry.get(n[0])?.id;if(t!==n[0]&&r){a(n);continue}}if(e.metadataRegistry.get(n[0])?.id){a(n);continue}if(r.cycle){a(n);continue}if(r.count>1&&e.reused===`ref`){a(n);continue}}}function ui(e,t){let n=e.seen.get(t);if(!n)throw Error(`Unprocessed schema. This is a bug in Zod.`);let r=t=>{let n=e.seen.get(t);if(n.ref===null)return;let i=n.def??n.schema,a={...i},o=n.ref;if(n.ref=null,o){r(o);let n=e.seen.get(o),s=n.schema;if(s.$ref&&(e.target===`draft-07`||e.target===`draft-04`||e.target===`openapi-3.0`)?(i.allOf=i.allOf??[],i.allOf.push(s)):Object.assign(i,s),Object.assign(i,a),t._zod.parent===o)for(let e in i)e===`$ref`||e===`allOf`||e in a||delete i[e];if(s.$ref&&n.def)for(let e in i)e===`$ref`||e===`allOf`||e in n.def&&JSON.stringify(i[e])===JSON.stringify(n.def[e])&&delete i[e]}let s=t._zod.parent;if(s&&s!==o){r(s);let t=e.seen.get(s);if(t?.schema.$ref&&(i.$ref=t.schema.$ref,t.def))for(let e in i)e===`$ref`||e===`allOf`||e in t.def&&JSON.stringify(i[e])===JSON.stringify(t.def[e])&&delete i[e]}e.override({zodSchema:t,jsonSchema:i,path:n.path??[]})};for(let t of[...e.seen.entries()].reverse())r(t[0]);let i={};if(e.target===`draft-2020-12`?i.$schema=`https://json-schema.org/draft/2020-12/schema`:e.target===`draft-07`?i.$schema=`http://json-schema.org/draft-07/schema#`:e.target===`draft-04`?i.$schema=`http://json-schema.org/draft-04/schema#`:e.target,e.external?.uri){let n=e.external.registry.get(t)?.id;if(!n)throw Error("Schema is missing an `id` property");i.$id=e.external.uri(n)}Object.assign(i,n.def??n.schema);let a=e.metadataRegistry.get(t)?.id;a!==void 0&&i.id===a&&delete i.id;let o=e.external?.defs??{};for(let t of e.seen.entries()){let e=t[1];e.def&&e.defId&&(e.def.id===e.defId&&delete e.def.id,o[e.defId]=e.def)}e.external||Object.keys(o).length>0&&(e.target===`draft-2020-12`?i.$defs=o:i.definitions=o);try{let n=JSON.parse(JSON.stringify(i));return Object.defineProperty(n,`~standard`,{value:{...t[`~standard`],jsonSchema:{input:fi(t,`input`,e.processors),output:fi(t,`output`,e.processors)}},enumerable:!1,writable:!1}),n}catch{throw Error(`Error converting schema to JSON.`)}}function E(e,t){let n=t??{seen:new Set};if(n.seen.has(e))return!1;n.seen.add(e);let r=e._zod.def;if(r.type===`transform`)return!0;if(r.type===`array`)return E(r.element,n);if(r.type===`set`)return E(r.valueType,n);if(r.type===`lazy`)return E(r.getter(),n);if(r.type===`promise`||r.type===`optional`||r.type===`nonoptional`||r.type===`nullable`||r.type===`readonly`||r.type===`default`||r.type===`prefault`)return E(r.innerType,n);if(r.type===`intersection`)return E(r.left,n)||E(r.right,n);if(r.type===`record`||r.type===`map`)return E(r.keyType,n)||E(r.valueType,n);if(r.type===`pipe`)return e._zod.traits.has(`$ZodCodec`)?!0:E(r.in,n)||E(r.out,n);if(r.type===`object`){for(let e in r.shape)if(E(r.shape[e],n))return!0;return!1}if(r.type===`union`){for(let e of r.options)if(E(e,n))return!0;return!1}if(r.type===`tuple`){for(let e of r.items)if(E(e,n))return!0;return!!(r.rest&&E(r.rest,n))}return!1}var di=(e,t={})=>n=>{let r=ci({...n,processors:t});return T(e,r),li(r,e),ui(r,e)},fi=(e,t,n={})=>r=>{let{libraryOptions:i,target:a}=r??{},o=ci({...i??{},target:a,io:t,processors:n});return T(e,o),li(o,e),ui(o,e)},pi={guid:`uuid`,url:`uri`,datetime:`date-time`,json_string:`json-string`,regex:``},mi=(e,t,n,r)=>{let i=n;i.type=`string`;let{minimum:a,maximum:o,format:s,patterns:c,contentEncoding:l}=e._zod.bag;if(typeof a==`number`&&(i.minLength=a),typeof o==`number`&&(i.maxLength=o),s&&(i.format=pi[s]??s,i.format===``&&delete i.format,s===`time`&&delete i.format),l&&(i.contentEncoding=l),c&&c.size>0){let e=[...c];e.length===1?i.pattern=e[0].source:e.length>1&&(i.allOf=[...e.map(e=>({...t.target===`draft-07`||t.target===`draft-04`||t.target===`openapi-3.0`?{type:`string`}:{},pattern:e.source}))])}},hi=(e,t,n,r)=>{let i=n,{minimum:a,maximum:o,format:s,multipleOf:c,exclusiveMaximum:l,exclusiveMinimum:u}=e._zod.bag;typeof s==`string`&&s.includes(`int`)?i.type=`integer`:i.type=`number`;let d=typeof u==`number`&&u>=(a??-1/0),ee=typeof l==`number`&&l<=(o??1/0),f=t.target===`draft-04`||t.target===`openapi-3.0`;d?f?(i.minimum=u,i.exclusiveMinimum=!0):i.exclusiveMinimum=u:typeof a==`number`&&(i.minimum=a),ee?f?(i.maximum=l,i.exclusiveMaximum=!0):i.exclusiveMaximum=l:typeof o==`number`&&(i.maximum=o),typeof c==`number`&&(i.multipleOf=c)},gi=(e,t,n,r)=>{n.type=`boolean`},_i=(e,t,n,r)=>{if(t.unrepresentable===`throw`)throw Error(`BigInt cannot be represented in JSON Schema`)},vi=(e,t,n,r)=>{if(t.unrepresentable===`throw`)throw Error(`Symbols cannot be represented in JSON Schema`)},yi=(e,t,n,r)=>{t.target===`openapi-3.0`?(n.type=`string`,n.nullable=!0,n.enum=[null]):n.type=`null`},bi=(e,t,n,r)=>{if(t.unrepresentable===`throw`)throw Error(`Undefined cannot be represented in JSON Schema`)},xi=(e,t,n,r)=>{if(t.unrepresentable===`throw`)throw Error(`Void cannot be represented in JSON Schema`)},Si=(e,t,n,r)=>{n.not={}},Ci=(e,t,n,r)=>{},wi=(e,t,n,r)=>{},Ti=(e,t,n,r)=>{if(t.unrepresentable===`throw`)throw Error(`Date cannot be represented in JSON Schema`)},Ei=(e,t,n,r)=>{let i=e._zod.def,a=o(i.entries);a.every(e=>typeof e==`number`)&&(n.type=`number`),a.every(e=>typeof e==`string`)&&(n.type=`string`),n.enum=a},Di=(e,t,n,r)=>{let i=e._zod.def,a=[];for(let e of i.values)if(e===void 0){if(t.unrepresentable===`throw`)throw Error("Literal `undefined` cannot be represented in JSON Schema")}else if(typeof e==`bigint`){if(t.unrepresentable===`throw`)throw Error(`BigInt literals cannot be represented in JSON Schema`);a.push(Number(e))}else a.push(e);if(a.length!==0)if(a.length===1){let e=a[0];n.type=e===null?`null`:typeof e,t.target===`draft-04`||t.target===`openapi-3.0`?n.enum=[e]:n.const=e}else a.every(e=>typeof e==`number`)&&(n.type=`number`),a.every(e=>typeof e==`string`)&&(n.type=`string`),a.every(e=>typeof e==`boolean`)&&(n.type=`boolean`),a.every(e=>e===null)&&(n.type=`null`),n.enum=a},Oi=(e,t,n,r)=>{if(t.unrepresentable===`throw`)throw Error(`NaN cannot be represented in JSON Schema`)},ki=(e,t,n,r)=>{let i=n,a=e._zod.pattern;if(!a)throw Error(`Pattern not found in template literal`);i.type=`string`,i.pattern=a.source},Ai=(e,t,n,r)=>{let i=n,a={type:`string`,format:`binary`,contentEncoding:`binary`},{minimum:o,maximum:s,mime:c}=e._zod.bag;o!==void 0&&(a.minLength=o),s!==void 0&&(a.maxLength=s),c?c.length===1?(a.contentMediaType=c[0],Object.assign(i,a)):(Object.assign(i,a),i.anyOf=c.map(e=>({contentMediaType:e}))):Object.assign(i,a)},ji=(e,t,n,r)=>{n.type=`boolean`},Mi=(e,t,n,r)=>{if(t.unrepresentable===`throw`)throw Error(`Custom types cannot be represented in JSON Schema`)},Ni=(e,t,n,r)=>{if(t.unrepresentable===`throw`)throw Error(`Function types cannot be represented in JSON Schema`)},Pi=(e,t,n,r)=>{if(t.unrepresentable===`throw`)throw Error(`Transforms cannot be represented in JSON Schema`)},Fi=(e,t,n,r)=>{if(t.unrepresentable===`throw`)throw Error(`Map cannot be represented in JSON Schema`)},Ii=(e,t,n,r)=>{if(t.unrepresentable===`throw`)throw Error(`Set cannot be represented in JSON Schema`)},Li=(e,t,n,r)=>{let i=n,a=e._zod.def,{minimum:o,maximum:s}=e._zod.bag;typeof o==`number`&&(i.minItems=o),typeof s==`number`&&(i.maxItems=s),i.type=`array`,i.items=T(a.element,t,{...r,path:[...r.path,`items`]})},Ri=(e,t,n,r)=>{let i=n,a=e._zod.def;i.type=`object`,i.properties={};let o=a.shape;for(let e in o)i.properties[e]=T(o[e],t,{...r,path:[...r.path,`properties`,e]});let s=new Set(Object.keys(o)),c=new Set([...s].filter(e=>{let n=a.shape[e]._zod;return t.io===`input`?n.optin===void 0:n.optout===void 0}));c.size>0&&(i.required=Array.from(c)),a.catchall?._zod.def.type===`never`?i.additionalProperties=!1:a.catchall?a.catchall&&(i.additionalProperties=T(a.catchall,t,{...r,path:[...r.path,`additionalProperties`]})):t.io===`output`&&(i.additionalProperties=!1)},zi=(e,t,n,r)=>{let i=e._zod.def,a=i.inclusive===!1,o=i.options.map((e,n)=>T(e,t,{...r,path:[...r.path,a?`oneOf`:`anyOf`,n]}));a?n.oneOf=o:n.anyOf=o},Bi=(e,t,n,r)=>{let i=e._zod.def,a=T(i.left,t,{...r,path:[...r.path,`allOf`,0]}),o=T(i.right,t,{...r,path:[...r.path,`allOf`,1]}),s=e=>`allOf`in e&&Object.keys(e).length===1;n.allOf=[...s(a)?a.allOf:[a],...s(o)?o.allOf:[o]]},Vi=(e,t,n,r)=>{let i=n,a=e._zod.def;i.type=`array`;let o=t.target===`draft-2020-12`?`prefixItems`:`items`,s=t.target===`draft-2020-12`||t.target===`openapi-3.0`?`items`:`additionalItems`,c=a.items.map((e,n)=>T(e,t,{...r,path:[...r.path,o,n]})),l=a.rest?T(a.rest,t,{...r,path:[...r.path,s,...t.target===`openapi-3.0`?[a.items.length]:[]]}):null;t.target===`draft-2020-12`?(i.prefixItems=c,l&&(i.items=l)):t.target===`openapi-3.0`?(i.items={anyOf:c},l&&i.items.anyOf.push(l),i.minItems=c.length,l||(i.maxItems=c.length)):(i.items=c,l&&(i.additionalItems=l));let{minimum:u,maximum:d}=e._zod.bag;typeof u==`number`&&(i.minItems=u),typeof d==`number`&&(i.maxItems=d)},Hi=(e,t,n,r)=>{let i=n,a=e._zod.def;i.type=`object`;let o=a.keyType,s=o._zod.bag?.patterns;if(a.mode===`loose`&&s&&s.size>0){let e=T(a.valueType,t,{...r,path:[...r.path,`patternProperties`,`*`]});i.patternProperties={};for(let t of s)i.patternProperties[t.source]=e}else (t.target===`draft-07`||t.target===`draft-2020-12`)&&(i.propertyNames=T(a.keyType,t,{...r,path:[...r.path,`propertyNames`]})),i.additionalProperties=T(a.valueType,t,{...r,path:[...r.path,`additionalProperties`]});let c=o._zod.values;if(c){let e=[...c].filter(e=>typeof e==`string`||typeof e==`number`);e.length>0&&(i.required=e)}},Ui=(e,t,n,r)=>{let i=e._zod.def,a=T(i.innerType,t,r),o=t.seen.get(e);t.target===`openapi-3.0`?(o.ref=i.innerType,n.nullable=!0):n.anyOf=[a,{type:`null`}]},Wi=(e,t,n,r)=>{let i=e._zod.def;T(i.innerType,t,r);let a=t.seen.get(e);a.ref=i.innerType},Gi=(e,t,n,r)=>{let i=e._zod.def;T(i.innerType,t,r);let a=t.seen.get(e);a.ref=i.innerType,n.default=JSON.parse(JSON.stringify(i.defaultValue))},Ki=(e,t,n,r)=>{let i=e._zod.def;T(i.innerType,t,r);let a=t.seen.get(e);a.ref=i.innerType,t.io===`input`&&(n._prefault=JSON.parse(JSON.stringify(i.defaultValue)))},qi=(e,t,n,r)=>{let i=e._zod.def;T(i.innerType,t,r);let a=t.seen.get(e);a.ref=i.innerType;let o;try{o=i.catchValue(void 0)}catch{throw Error(`Dynamic catch values are not supported in JSON Schema`)}n.default=o},Ji=(e,t,n,r)=>{let i=e._zod.def,a=i.in._zod.traits.has(`$ZodTransform`),o=t.io===`input`?a?i.out:i.in:i.out;T(o,t,r);let s=t.seen.get(e);s.ref=o},Yi=(e,t,n,r)=>{let i=e._zod.def;T(i.innerType,t,r);let a=t.seen.get(e);a.ref=i.innerType,n.readOnly=!0},Xi=(e,t,n,r)=>{let i=e._zod.def;T(i.innerType,t,r);let a=t.seen.get(e);a.ref=i.innerType},Zi=(e,t,n,r)=>{let i=e._zod.def;T(i.innerType,t,r);let a=t.seen.get(e);a.ref=i.innerType},Qi=(e,t,n,r)=>{let i=e._zod.innerType;T(i,t,r);let a=t.seen.get(e);a.ref=i},$i={string:mi,number:hi,boolean:gi,bigint:_i,symbol:vi,null:yi,undefined:bi,void:xi,never:Si,any:Ci,unknown:wi,date:Ti,enum:Ei,literal:Di,nan:Oi,template_literal:ki,file:Ai,success:ji,custom:Mi,function:Ni,transform:Pi,map:Fi,set:Ii,array:Li,object:Ri,union:zi,intersection:Bi,tuple:Vi,record:Hi,nullable:Ui,nonoptional:Wi,default:Gi,prefault:Ki,catch:qi,pipe:Ji,readonly:Yi,promise:Xi,optional:Zi,lazy:Qi};function ea(e,t){if(`_idmap`in e){let n=e,r=ci({...t,processors:$i}),i={};for(let e of n._idmap.entries()){let[t,n]=e;T(n,r)}let a={};r.external={registry:n,uri:t?.uri,defs:i};for(let e of n._idmap.entries()){let[t,n]=e;li(r,n),a[t]=ui(r,n)}return Object.keys(i).length>0&&(a.__shared={[r.target===`draft-2020-12`?`$defs`:`definitions`]:i}),{schemas:a}}let n=ci({...t,processors:$i});return T(e,n),li(n,e),ui(n,e)}var ta=t(`ZodISODateTime`,(e,t)=>{Yt.init(e,t),k.init(e,t)});function na(e){return Or(ta,e)}var ra=t(`ZodISODate`,(e,t)=>{Xt.init(e,t),k.init(e,t)});function ia(e){return kr(ra,e)}var aa=t(`ZodISOTime`,(e,t)=>{Zt.init(e,t),k.init(e,t)});function oa(e){return Ar(aa,e)}var sa=t(`ZodISODuration`,(e,t)=>{Qt.init(e,t),k.init(e,t)});function ca(e){return jr(sa,e)}var D=t(`ZodError`,(e,t)=>{Ce.init(e,t),e.name=`ZodError`,Object.defineProperties(e,{format:{value:t=>Ee(e,t)},flatten:{value:t=>Te(e,t)},addIssue:{value:t=>{e.issues.push(t),e.message=JSON.stringify(e.issues,s,2)}},addIssues:{value:t=>{e.issues.push(...t),e.message=JSON.stringify(e.issues,s,2)}},isEmpty:{get(){return e.issues.length===0}}})},{Parent:Error}),la=De(D),ua=Oe(D),da=ke(D),fa=je(D),pa=Ne(D),ma=Pe(D),ha=Fe(D),ga=Ie(D),_a=Le(D),va=Re(D),ya=ze(D),ba=Be(D),xa=new WeakMap;function Sa(e,t,n){let r=Object.getPrototypeOf(e),i=xa.get(r);if(i||(i=new Set,xa.set(r,i)),!i.has(t)){i.add(t);for(let e in n){let t=n[e];Object.defineProperty(r,e,{configurable:!0,enumerable:!1,get(){let n=t.bind(this);return Object.defineProperty(this,e,{configurable:!0,writable:!0,enumerable:!0,value:n}),n},set(t){Object.defineProperty(this,e,{configurable:!0,writable:!0,enumerable:!0,value:t})}})}}}var O=t(`ZodType`,(e,t)=>(S.init(e,t),Object.assign(e[`~standard`],{jsonSchema:{input:fi(e,`input`),output:fi(e,`output`)}}),e.toJSONSchema=di(e,{}),e.def=t,e.type=t.type,Object.defineProperty(e,`_def`,{value:t}),e.parse=(t,n)=>la(e,t,n,{callee:e.parse}),e.safeParse=(t,n)=>da(e,t,n),e.parseAsync=async(t,n)=>ua(e,t,n,{callee:e.parseAsync}),e.safeParseAsync=async(t,n)=>fa(e,t,n),e.spa=e.safeParseAsync,e.encode=(t,n)=>pa(e,t,n),e.decode=(t,n)=>ma(e,t,n),e.encodeAsync=async(t,n)=>ha(e,t,n),e.decodeAsync=async(t,n)=>ga(e,t,n),e.safeEncode=(t,n)=>_a(e,t,n),e.safeDecode=(t,n)=>va(e,t,n),e.safeEncodeAsync=async(t,n)=>ya(e,t,n),e.safeDecodeAsync=async(t,n)=>ba(e,t,n),Sa(e,`ZodType`,{check(...e){let t=this.def;return this.clone(m(t,{checks:[...t.checks??[],...e.map(e=>typeof e==`function`?{_zod:{check:e,def:{check:`custom`},onattach:[]}}:e)]}),{parent:!0})},with(...e){return this.check(...e)},clone(e,t){return _(this,e,t)},brand(){return this},register(e,t){return e.add(this,t),this},refine(e,t){return this.check(qo(e,t))},superRefine(e,t){return this.check(Jo(e,t))},overwrite(e){return this.check(w(e))},optional(){return Eo(this)},exactOptional(){return Oo(this)},nullable(){return Ao(this)},nullish(){return Eo(Ao(this))},nonoptional(e){return Io(this,e)},array(){return io(this)},or(e){return lo([this,e])},and(e){return mo(this,e)},transform(e){return Bo(this,wo(e))},default(e){return Mo(this,e)},prefault(e){return Po(this,e)},catch(e){return Ro(this,e)},pipe(e){return Bo(this,e)},readonly(){return Ho(this)},describe(e){let t=this.clone();return ir.add(t,{description:e}),t},meta(...e){if(e.length===0)return ir.get(this);let t=this.clone();return ir.add(t,e[0]),t},isOptional(){return this.safeParse(void 0).success},isNullable(){return this.safeParse(null).success},apply(e){return e(this)}}),Object.defineProperty(e,`description`,{get(){return ir.get(e)?.description},configurable:!0}),e)),Ca=t(`_ZodString`,(e,t)=>{Lt.init(e,t),O.init(e,t),e._zod.processJSONSchema=(t,n,r)=>mi(e,t,n,r);let n=e._zod.bag;e.format=n.format??null,e.minLength=n.minimum??null,e.maxLength=n.maximum??null,Sa(e,`_ZodString`,{regex(...e){return this.check(Kr(...e))},includes(...e){return this.check(Yr(...e))},startsWith(...e){return this.check(Xr(...e))},endsWith(...e){return this.check(Zr(...e))},min(...e){return this.check(Wr(...e))},max(...e){return this.check(Ur(...e))},length(...e){return this.check(Gr(...e))},nonempty(...e){return this.check(Wr(1,...e))},lowercase(e){return this.check(qr(e))},uppercase(e){return this.check(Jr(e))},trim(){return this.check($r())},normalize(...e){return this.check(Qr(...e))},toLowerCase(){return this.check(ei())},toUpperCase(){return this.check(ti())},slugify(){return this.check(ni())}})}),wa=t(`ZodString`,(e,t)=>{Lt.init(e,t),Ca.init(e,t),e.email=t=>e.check(or(Ea,t)),e.url=t=>e.check(fr(ka,t)),e.jwt=t=>e.check(Dr(Wa,t)),e.emoji=t=>e.check(pr(Aa,t)),e.guid=t=>e.check(sr(Da,t)),e.uuid=t=>e.check(cr(Oa,t)),e.uuidv4=t=>e.check(lr(Oa,t)),e.uuidv6=t=>e.check(ur(Oa,t)),e.uuidv7=t=>e.check(dr(Oa,t)),e.nanoid=t=>e.check(mr(ja,t)),e.guid=t=>e.check(sr(Da,t)),e.cuid=t=>e.check(hr(Ma,t)),e.cuid2=t=>e.check(gr(Na,t)),e.ulid=t=>e.check(_r(Pa,t)),e.base64=t=>e.check(wr(Va,t)),e.base64url=t=>e.check(Tr(Ha,t)),e.xid=t=>e.check(vr(Fa,t)),e.ksuid=t=>e.check(yr(Ia,t)),e.ipv4=t=>e.check(br(La,t)),e.ipv6=t=>e.check(xr(Ra,t)),e.cidrv4=t=>e.check(Sr(za,t)),e.cidrv6=t=>e.check(Cr(Ba,t)),e.e164=t=>e.check(Er(Ua,t)),e.datetime=t=>e.check(na(t)),e.date=t=>e.check(ia(t)),e.time=t=>e.check(oa(t)),e.duration=t=>e.check(ca(t))});function Ta(e){return ar(wa,e)}var k=t(`ZodStringFormat`,(e,t)=>{C.init(e,t),Ca.init(e,t)}),Ea=t(`ZodEmail`,(e,t)=>{Bt.init(e,t),k.init(e,t)}),Da=t(`ZodGUID`,(e,t)=>{Rt.init(e,t),k.init(e,t)}),Oa=t(`ZodUUID`,(e,t)=>{zt.init(e,t),k.init(e,t)}),ka=t(`ZodURL`,(e,t)=>{Vt.init(e,t),k.init(e,t)}),Aa=t(`ZodEmoji`,(e,t)=>{Ht.init(e,t),k.init(e,t)}),ja=t(`ZodNanoID`,(e,t)=>{Ut.init(e,t),k.init(e,t)}),Ma=t(`ZodCUID`,(e,t)=>{Wt.init(e,t),k.init(e,t)}),Na=t(`ZodCUID2`,(e,t)=>{Gt.init(e,t),k.init(e,t)}),Pa=t(`ZodULID`,(e,t)=>{Kt.init(e,t),k.init(e,t)}),Fa=t(`ZodXID`,(e,t)=>{qt.init(e,t),k.init(e,t)}),Ia=t(`ZodKSUID`,(e,t)=>{Jt.init(e,t),k.init(e,t)}),La=t(`ZodIPv4`,(e,t)=>{$t.init(e,t),k.init(e,t)}),Ra=t(`ZodIPv6`,(e,t)=>{en.init(e,t),k.init(e,t)}),za=t(`ZodCIDRv4`,(e,t)=>{tn.init(e,t),k.init(e,t)}),Ba=t(`ZodCIDRv6`,(e,t)=>{nn.init(e,t),k.init(e,t)}),Va=t(`ZodBase64`,(e,t)=>{an.init(e,t),k.init(e,t)}),Ha=t(`ZodBase64URL`,(e,t)=>{sn.init(e,t),k.init(e,t)}),Ua=t(`ZodE164`,(e,t)=>{cn.init(e,t),k.init(e,t)}),Wa=t(`ZodJWT`,(e,t)=>{un.init(e,t),k.init(e,t)}),Ga=t(`ZodNumber`,(e,t)=>{dn.init(e,t),O.init(e,t),e._zod.processJSONSchema=(t,n,r)=>hi(e,t,n,r),Sa(e,`ZodNumber`,{gt(e,t){return this.check(Br(e,t))},gte(e,t){return this.check(Vr(e,t))},min(e,t){return this.check(Vr(e,t))},lt(e,t){return this.check(Rr(e,t))},lte(e,t){return this.check(zr(e,t))},max(e,t){return this.check(zr(e,t))},int(e){return this.check(Ja(e))},safe(e){return this.check(Ja(e))},positive(e){return this.check(Br(0,e))},nonnegative(e){return this.check(Vr(0,e))},negative(e){return this.check(Rr(0,e))},nonpositive(e){return this.check(zr(0,e))},multipleOf(e,t){return this.check(Hr(e,t))},step(e,t){return this.check(Hr(e,t))},finite(){return this}});let n=e._zod.bag;e.minValue=Math.max(n.minimum??-1/0,n.exclusiveMinimum??-1/0)??null,e.maxValue=Math.min(n.maximum??1/0,n.exclusiveMaximum??1/0)??null,e.isInt=(n.format??``).includes(`int`)||Number.isSafeInteger(n.multipleOf??.5),e.isFinite=!0,e.format=n.format??null});function Ka(e){return Mr(Ga,e)}var qa=t(`ZodNumberFormat`,(e,t)=>{fn.init(e,t),Ga.init(e,t)});function Ja(e){return Nr(qa,e)}var Ya=t(`ZodBoolean`,(e,t)=>{pn.init(e,t),O.init(e,t),e._zod.processJSONSchema=(t,n,r)=>gi(e,t,n,r)});function Xa(e){return Pr(Ya,e)}var Za=t(`ZodNull`,(e,t)=>{mn.init(e,t),O.init(e,t),e._zod.processJSONSchema=(t,n,r)=>yi(e,t,n,r)});function Qa(e){return Fr(Za,e)}var $a=t(`ZodUnknown`,(e,t)=>{hn.init(e,t),O.init(e,t),e._zod.processJSONSchema=(e,t,n)=>void 0});function eo(){return Ir($a)}var to=t(`ZodNever`,(e,t)=>{gn.init(e,t),O.init(e,t),e._zod.processJSONSchema=(t,n,r)=>Si(e,t,n,r)});function no(e){return Lr(to,e)}var ro=t(`ZodArray`,(e,t)=>{vn.init(e,t),O.init(e,t),e._zod.processJSONSchema=(t,n,r)=>Li(e,t,n,r),e.element=t.element,Sa(e,`ZodArray`,{min(e,t){return this.check(Wr(e,t))},nonempty(e){return this.check(Wr(1,e))},max(e,t){return this.check(Ur(e,t))},length(e,t){return this.check(Gr(e,t))},unwrap(){return this.element}})});function io(e,t){return ri(ro,e,t)}var ao=t(`ZodObject`,(e,t)=>{Cn.init(e,t),O.init(e,t),e._zod.processJSONSchema=(t,n,r)=>Ri(e,t,n,r),f(e,`shape`,()=>t.shape),Sa(e,`ZodObject`,{keyof(){return bo(Object.keys(this._zod.def.shape))},catchall(e){return this.clone({...this._zod.def,catchall:e})},passthrough(){return this.clone({...this._zod.def,catchall:eo()})},loose(){return this.clone({...this._zod.def,catchall:eo()})},strict(){return this.clone({...this._zod.def,catchall:no()})},strip(){return this.clone({...this._zod.def,catchall:void 0})},extend(e){return fe(this,e)},safeExtend(e){return pe(this,e)},merge(e){return me(this,e)},pick(e){return ue(this,e)},omit(e){return de(this,e)},partial(...e){return he(To,this,e[0])},required(...e){return ge(Fo,this,e[0])}})});function oo(e,t){return new ao({type:`object`,shape:e??{},...v(t)})}function so(e,t){return new ao({type:`object`,shape:e,catchall:no(),...v(t)})}var co=t(`ZodUnion`,(e,t)=>{Tn.init(e,t),O.init(e,t),e._zod.processJSONSchema=(t,n,r)=>zi(e,t,n,r),e.options=t.options});function lo(e,t){return new co({type:`union`,options:e,...v(t)})}var uo=t(`ZodDiscriminatedUnion`,(e,t)=>{co.init(e,t),En.init(e,t)});function fo(e,t,n){return new uo({type:`union`,options:t,discriminator:e,...v(n)})}var po=t(`ZodIntersection`,(e,t)=>{Dn.init(e,t),O.init(e,t),e._zod.processJSONSchema=(t,n,r)=>Bi(e,t,n,r)});function mo(e,t){return new po({type:`intersection`,left:e,right:t})}var ho=t(`ZodTuple`,(e,t)=>{An.init(e,t),O.init(e,t),e._zod.processJSONSchema=(t,n,r)=>Vi(e,t,n,r),e.rest=t=>e.clone({...e._zod.def,rest:t})});function go(e,t,n){let r=t instanceof S;return new ho({type:`tuple`,items:e,rest:r?t:null,...v(r?n:t)})}var _o=t(`ZodRecord`,(e,t)=>{Pn.init(e,t),O.init(e,t),e._zod.processJSONSchema=(t,n,r)=>Hi(e,t,n,r),e.keyType=t.keyType,e.valueType=t.valueType});function vo(e,t,n){return!t||!t._zod?new _o({type:`record`,keyType:Ta(),valueType:e,...v(t)}):new _o({type:`record`,keyType:e,valueType:t,...v(n)})}var yo=t(`ZodEnum`,(e,t)=>{Fn.init(e,t),O.init(e,t),e._zod.processJSONSchema=(t,n,r)=>Ei(e,t,n,r),e.enum=t.entries,e.options=Object.values(t.entries);let n=new Set(Object.keys(t.entries));e.extract=(e,r)=>{let i={};for(let r of e)if(n.has(r))i[r]=t.entries[r];else throw Error(`Key ${r} not found in enum`);return new yo({...t,checks:[],...v(r),entries:i})},e.exclude=(e,r)=>{let i={...t.entries};for(let t of e)if(n.has(t))delete i[t];else throw Error(`Key ${t} not found in enum`);return new yo({...t,checks:[],...v(r),entries:i})}});function bo(e,t){return new yo({type:`enum`,entries:Array.isArray(e)?Object.fromEntries(e.map(e=>[e,e])):e,...v(t)})}var xo=t(`ZodLiteral`,(e,t)=>{In.init(e,t),O.init(e,t),e._zod.processJSONSchema=(t,n,r)=>Di(e,t,n,r),e.values=new Set(t.values),Object.defineProperty(e,`value`,{get(){if(t.values.length>1)throw Error("This schema contains multiple valid literal values. Use `.values` instead.");return t.values[0]}})});function So(e,t){return new xo({type:`literal`,values:Array.isArray(e)?e:[e],...v(t)})}var Co=t(`ZodTransform`,(e,t)=>{Ln.init(e,t),O.init(e,t),e._zod.processJSONSchema=(t,n,r)=>Pi(e,t,n,r),e._zod.parse=(n,i)=>{if(i.direction===`backward`)throw new r(e.constructor.name);n.addIssue=r=>{if(typeof r==`string`)n.issues.push(xe(r,n.value,t));else{let t=r;t.fatal&&(t.continue=!1),t.code??=`custom`,t.input??=n.value,t.inst??=e,n.issues.push(xe(t))}};let a=t.transform(n.value,n);return a instanceof Promise?a.then(e=>(n.value=e,n.fallback=!0,n)):(n.value=a,n.fallback=!0,n)}});function wo(e){return new Co({type:`transform`,transform:e})}var To=t(`ZodOptional`,(e,t)=>{zn.init(e,t),O.init(e,t),e._zod.processJSONSchema=(t,n,r)=>Zi(e,t,n,r),e.unwrap=()=>e._zod.def.innerType});function Eo(e){return new To({type:`optional`,innerType:e})}var Do=t(`ZodExactOptional`,(e,t)=>{Bn.init(e,t),O.init(e,t),e._zod.processJSONSchema=(t,n,r)=>Zi(e,t,n,r),e.unwrap=()=>e._zod.def.innerType});function Oo(e){return new Do({type:`optional`,innerType:e})}var ko=t(`ZodNullable`,(e,t)=>{Vn.init(e,t),O.init(e,t),e._zod.processJSONSchema=(t,n,r)=>Ui(e,t,n,r),e.unwrap=()=>e._zod.def.innerType});function Ao(e){return new ko({type:`nullable`,innerType:e})}var jo=t(`ZodDefault`,(e,t)=>{Hn.init(e,t),O.init(e,t),e._zod.processJSONSchema=(t,n,r)=>Gi(e,t,n,r),e.unwrap=()=>e._zod.def.innerType,e.removeDefault=e.unwrap});function Mo(e,t){return new jo({type:`default`,innerType:e,get defaultValue(){return typeof t==`function`?t():oe(t)}})}var No=t(`ZodPrefault`,(e,t)=>{Wn.init(e,t),O.init(e,t),e._zod.processJSONSchema=(t,n,r)=>Ki(e,t,n,r),e.unwrap=()=>e._zod.def.innerType});function Po(e,t){return new No({type:`prefault`,innerType:e,get defaultValue(){return typeof t==`function`?t():oe(t)}})}var Fo=t(`ZodNonOptional`,(e,t)=>{Gn.init(e,t),O.init(e,t),e._zod.processJSONSchema=(t,n,r)=>Wi(e,t,n,r),e.unwrap=()=>e._zod.def.innerType});function Io(e,t){return new Fo({type:`nonoptional`,innerType:e,...v(t)})}var Lo=t(`ZodCatch`,(e,t)=>{qn.init(e,t),O.init(e,t),e._zod.processJSONSchema=(t,n,r)=>qi(e,t,n,r),e.unwrap=()=>e._zod.def.innerType,e.removeCatch=e.unwrap});function Ro(e,t){return new Lo({type:`catch`,innerType:e,catchValue:typeof t==`function`?t:()=>t})}var zo=t(`ZodPipe`,(e,t)=>{Jn.init(e,t),O.init(e,t),e._zod.processJSONSchema=(t,n,r)=>Ji(e,t,n,r),e.in=t.in,e.out=t.out});function Bo(e,t){return new zo({type:`pipe`,in:e,out:t})}var Vo=t(`ZodReadonly`,(e,t)=>{Xn.init(e,t),O.init(e,t),e._zod.processJSONSchema=(t,n,r)=>Yi(e,t,n,r),e.unwrap=()=>e._zod.def.innerType});function Ho(e){return new Vo({type:`readonly`,innerType:e})}var Uo=t(`ZodLazy`,(e,t)=>{Qn.init(e,t),O.init(e,t),e._zod.processJSONSchema=(t,n,r)=>Qi(e,t,n,r),e.unwrap=()=>e._zod.def.getter()});function Wo(e){return new Uo({type:`lazy`,getter:e})}var Go=t(`ZodCustom`,(e,t)=>{$n.init(e,t),O.init(e,t),e._zod.processJSONSchema=(t,n,r)=>Mi(e,t,n,r)});function Ko(e,t){return ii(Go,e??(()=>!0),t)}function qo(e,t={}){return ai(Go,e,t)}function Jo(e,t){return oi(e,t)}function Yo(e,t={}){let n=new Go({type:`custom`,check:`custom`,fn:t=>t instanceof e,abort:!0,...v(t)});return n._zod.bag.Class=e,n._zod.check=t=>{t.value instanceof e||t.issues.push({code:`invalid_type`,expected:e.name,input:t.value,inst:n,path:[...n._zod.def.path??[]]})},n}var A;(function(e){e.assertEqual=e=>{};function t(e){}e.assertIs=t;function n(e){throw Error()}e.assertNever=n,e.arrayToEnum=e=>{let t={};for(let n of e)t[n]=n;return t},e.getValidEnumValues=t=>{let n=e.objectKeys(t).filter(e=>typeof t[t[e]]!=`number`),r={};for(let e of n)r[e]=t[e];return e.objectValues(r)},e.objectValues=t=>e.objectKeys(t).map(function(e){return t[e]}),e.objectKeys=typeof Object.keys==`function`?e=>Object.keys(e):e=>{let t=[];for(let n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.push(n);return t},e.find=(e,t)=>{for(let n of e)if(t(n))return n},e.isInteger=typeof Number.isInteger==`function`?e=>Number.isInteger(e):e=>typeof e==`number`&&Number.isFinite(e)&&Math.floor(e)===e;function r(e,t=` | `){return e.map(e=>typeof e==`string`?`'${e}'`:e).join(t)}e.joinValues=r,e.jsonStringifyReplacer=(e,t)=>typeof t==`bigint`?t.toString():t})(A||={});var Xo;(function(e){e.mergeShapes=(e,t)=>({...e,...t})})(Xo||={});var j=A.arrayToEnum([`string`,`nan`,`number`,`integer`,`float`,`boolean`,`date`,`bigint`,`symbol`,`function`,`undefined`,`null`,`array`,`object`,`unknown`,`promise`,`void`,`never`,`map`,`set`]),M=e=>{switch(typeof e){case`undefined`:return j.undefined;case`string`:return j.string;case`number`:return Number.isNaN(e)?j.nan:j.number;case`boolean`:return j.boolean;case`function`:return j.function;case`bigint`:return j.bigint;case`symbol`:return j.symbol;case`object`:return Array.isArray(e)?j.array:e===null?j.null:e.then&&typeof e.then==`function`&&e.catch&&typeof e.catch==`function`?j.promise:typeof Map<`u`&&e instanceof Map?j.map:typeof Set<`u`&&e instanceof Set?j.set:typeof Date<`u`&&e instanceof Date?j.date:j.object;default:return j.unknown}},N=A.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`]),P=class e extends Error{get errors(){return this.issues}constructor(e){super(),this.issues=[],this.addIssue=e=>{this.issues=[...this.issues,e]},this.addIssues=(e=[])=>{this.issues=[...this.issues,...e]};let t=new.target.prototype;Object.setPrototypeOf?Object.setPrototypeOf(this,t):this.__proto__=t,this.name=`ZodError`,this.issues=e}format(e){let t=e||function(e){return e.message},n={_errors:[]},r=e=>{for(let i of e.issues)if(i.code===`invalid_union`)i.unionErrors.map(r);else if(i.code===`invalid_return_type`)r(i.returnTypeError);else if(i.code===`invalid_arguments`)r(i.argumentsError);else if(i.path.length===0)n._errors.push(t(i));else{let e=n,r=0;for(;r<i.path.length;){let n=i.path[r];r===i.path.length-1?(e[n]=e[n]||{_errors:[]},e[n]._errors.push(t(i))):e[n]=e[n]||{_errors:[]},e=e[n],r++}}};return r(this),n}static assert(t){if(!(t instanceof e))throw Error(`Not a ZodError: ${t}`)}toString(){return this.message}get message(){return JSON.stringify(this.issues,A.jsonStringifyReplacer,2)}get isEmpty(){return this.issues.length===0}flatten(e=e=>e.message){let t=Object.create(null),n=[];for(let r of this.issues)if(r.path.length>0){let n=r.path[0];t[n]=t[n]||[],t[n].push(e(r))}else n.push(e(r));return{formErrors:n,fieldErrors:t}}get formErrors(){return this.flatten()}};P.create=e=>new P(e);var Zo=(e,t)=>{let n;switch(e.code){case N.invalid_type:n=e.received===j.undefined?`Required`:`Expected ${e.expected}, received ${e.received}`;break;case N.invalid_literal:n=`Invalid literal value, expected ${JSON.stringify(e.expected,A.jsonStringifyReplacer)}`;break;case N.unrecognized_keys:n=`Unrecognized key(s) in object: ${A.joinValues(e.keys,`, `)}`;break;case N.invalid_union:n=`Invalid input`;break;case N.invalid_union_discriminator:n=`Invalid discriminator value. Expected ${A.joinValues(e.options)}`;break;case N.invalid_enum_value:n=`Invalid enum value. Expected ${A.joinValues(e.options)}, received '${e.received}'`;break;case N.invalid_arguments:n=`Invalid function arguments`;break;case N.invalid_return_type:n=`Invalid function return type`;break;case N.invalid_date:n=`Invalid date`;break;case N.invalid_string:typeof e.validation==`object`?`includes`in e.validation?(n=`Invalid input: must include "${e.validation.includes}"`,typeof e.validation.position==`number`&&(n=`${n} at one or more positions greater than or equal to ${e.validation.position}`)):`startsWith`in e.validation?n=`Invalid input: must start with "${e.validation.startsWith}"`:`endsWith`in e.validation?n=`Invalid input: must end with "${e.validation.endsWith}"`:A.assertNever(e.validation):n=e.validation===`regex`?`Invalid`:`Invalid ${e.validation}`;break;case N.too_small:n=e.type===`array`?`Array must contain ${e.exact?`exactly`:e.inclusive?`at least`:`more than`} ${e.minimum} element(s)`:e.type===`string`?`String must contain ${e.exact?`exactly`:e.inclusive?`at least`:`over`} ${e.minimum} character(s)`:e.type===`number`||e.type===`bigint`?`Number must be ${e.exact?`exactly equal to `:e.inclusive?`greater than or equal to `:`greater than `}${e.minimum}`:e.type===`date`?`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 N.too_big:n=e.type===`array`?`Array must contain ${e.exact?`exactly`:e.inclusive?`at most`:`less than`} ${e.maximum} element(s)`:e.type===`string`?`String must contain ${e.exact?`exactly`:e.inclusive?`at most`:`under`} ${e.maximum} character(s)`:e.type===`number`?`Number must be ${e.exact?`exactly`:e.inclusive?`less than or equal to`:`less than`} ${e.maximum}`:e.type===`bigint`?`BigInt must be ${e.exact?`exactly`:e.inclusive?`less than or equal to`:`less than`} ${e.maximum}`:e.type===`date`?`Date must be ${e.exact?`exactly`:e.inclusive?`smaller than or equal to`:`smaller than`} ${new Date(Number(e.maximum))}`:`Invalid input`;break;case N.custom:n=`Invalid input`;break;case N.invalid_intersection_types:n=`Intersection results could not be merged`;break;case N.not_multiple_of:n=`Number must be a multiple of ${e.multipleOf}`;break;case N.not_finite:n=`Number must be finite`;break;default:n=t.defaultError,A.assertNever(e)}return{message:n}},Qo=Zo;function $o(){return Qo}var es=e=>{let{data:t,path:n,errorMaps:r,issueData:i}=e,a=[...n,...i.path||[]],o={...i,path:a};if(i.message!==void 0)return{...i,path:a,message:i.message};let s=``,c=r.filter(e=>!!e).slice().reverse();for(let e of c)s=e(o,{data:t,defaultError:s}).message;return{...i,path:a,message:s}};function F(e,t){let n=$o(),r=es({issueData:t,data:e.data,path:e.path,errorMaps:[e.common.contextualErrorMap,e.schemaErrorMap,n,n===Zo?void 0:Zo].filter(e=>!!e)});e.common.issues.push(r)}var I=class e{constructor(){this.value=`valid`}dirty(){this.value===`valid`&&(this.value=`dirty`)}abort(){this.value!==`aborted`&&(this.value=`aborted`)}static mergeArray(e,t){let n=[];for(let r of t){if(r.status===`aborted`)return L;r.status===`dirty`&&e.dirty(),n.push(r.value)}return{status:e.value,value:n}}static async mergeObjectAsync(t,n){let r=[];for(let e of n){let t=await e.key,n=await e.value;r.push({key:t,value:n})}return e.mergeObjectSync(t,r)}static mergeObjectSync(e,t){let n={};for(let r of t){let{key:t,value:i}=r;if(t.status===`aborted`||i.status===`aborted`)return L;t.status===`dirty`&&e.dirty(),i.status===`dirty`&&e.dirty(),t.value!==`__proto__`&&(i.value!==void 0||r.alwaysSet)&&(n[t.value]=i.value)}return{status:e.value,value:n}}},L=Object.freeze({status:`aborted`}),ts=e=>({status:`dirty`,value:e}),R=e=>({status:`valid`,value:e}),ns=e=>e.status===`aborted`,rs=e=>e.status===`dirty`,z=e=>e.status===`valid`,is=e=>typeof Promise<`u`&&e instanceof Promise,B;(function(e){e.errToObj=e=>typeof e==`string`?{message:e}:e||{},e.toString=e=>typeof e==`string`?e:e?.message})(B||={});var V=class{constructor(e,t,n,r){this._cachedPath=[],this.parent=e,this.data=t,this._path=n,this._key=r}get path(){return this._cachedPath.length||(Array.isArray(this._key)?this._cachedPath.push(...this._path,...this._key):this._cachedPath.push(...this._path,this._key)),this._cachedPath}},as=(e,t)=>{if(z(t))return{success:!0,data:t.value};if(!e.common.issues.length)throw Error(`Validation failed but no issues detected.`);return{success:!1,get error(){if(this._error)return this._error;let t=new P(e.common.issues);return this._error=t,this._error}}};function H(e){if(!e)return{};let{errorMap:t,invalid_type_error:n,required_error:r,description:i}=e;if(t&&(n||r))throw Error(`Can't use "invalid_type_error" or "required_error" in conjunction with custom error map.`);return t?{errorMap:t,description:i}:{errorMap:(t,i)=>{let{message:a}=e;return t.code===`invalid_enum_value`?{message:a??i.defaultError}:i.data===void 0?{message:a??r??i.defaultError}:t.code===`invalid_type`?{message:a??n??i.defaultError}:{message:i.defaultError}},description:i}}var U=class{get description(){return this._def.description}_getType(e){return M(e.data)}_getOrReturnCtx(e,t){return t||{common:e.parent.common,data:e.data,parsedType:M(e.data),schemaErrorMap:this._def.errorMap,path:e.path,parent:e.parent}}_processInputParams(e){return{status:new I,ctx:{common:e.parent.common,data:e.data,parsedType:M(e.data),schemaErrorMap:this._def.errorMap,path:e.path,parent:e.parent}}}_parseSync(e){let t=this._parse(e);if(is(t))throw Error(`Synchronous parse encountered promise.`);return t}_parseAsync(e){let t=this._parse(e);return Promise.resolve(t)}parse(e,t){let n=this.safeParse(e,t);if(n.success)return n.data;throw n.error}safeParse(e,t){let n={common:{issues:[],async:t?.async??!1,contextualErrorMap:t?.errorMap},path:t?.path||[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:M(e)};return as(n,this._parseSync({data:e,path:n.path,parent:n}))}"~validate"(e){let t={common:{issues:[],async:!!this[`~standard`].async},path:[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:M(e)};if(!this[`~standard`].async)try{let n=this._parseSync({data:e,path:[],parent:t});return z(n)?{value:n.value}:{issues:t.common.issues}}catch(e){e?.message?.toLowerCase()?.includes(`encountered`)&&(this[`~standard`].async=!0),t.common={issues:[],async:!0}}return this._parseAsync({data:e,path:[],parent:t}).then(e=>z(e)?{value:e.value}:{issues:t.common.issues})}async parseAsync(e,t){let n=await this.safeParseAsync(e,t);if(n.success)return n.data;throw n.error}async safeParseAsync(e,t){let n={common:{issues:[],contextualErrorMap:t?.errorMap,async:!0},path:t?.path||[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:M(e)},r=this._parse({data:e,path:n.path,parent:n});return as(n,await(is(r)?r:Promise.resolve(r)))}refine(e,t){let n=e=>typeof t==`string`||t===void 0?{message:t}:typeof t==`function`?t(e):t;return this._refinement((t,r)=>{let i=e(t),a=()=>r.addIssue({code:N.custom,...n(t)});return typeof Promise<`u`&&i instanceof Promise?i.then(e=>e?!0:(a(),!1)):i?!0:(a(),!1)})}refinement(e,t){return this._refinement((n,r)=>e(n)?!0:(r.addIssue(typeof t==`function`?t(n,r):t),!1))}_refinement(e){return new X({schema:this,typeName:$.ZodEffects,effect:{type:`refinement`,refinement:e}})}superRefine(e){return this._refinement(e)}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),this[`~standard`]={version:1,vendor:`zod`,validate:e=>this[`~validate`](e)}}optional(){return Z.create(this,this._def)}nullable(){return Q.create(this,this._def)}nullish(){return this.nullable().optional()}array(){return K.create(this)}promise(){return tc.create(this,this._def)}or(e){return Hs.create([this,e],this._def)}and(e){return Gs.create(this,e,this._def)}transform(e){return new X({...H(this._def),schema:this,typeName:$.ZodEffects,effect:{type:`transform`,transform:e}})}default(e){let t=typeof e==`function`?e:()=>e;return new nc({...H(this._def),innerType:this,defaultValue:t,typeName:$.ZodDefault})}brand(){return new ac({typeName:$.ZodBranded,type:this,...H(this._def)})}catch(e){let t=typeof e==`function`?e:()=>e;return new rc({...H(this._def),innerType:this,catchValue:t,typeName:$.ZodCatch})}describe(e){let t=this.constructor;return new t({...this._def,description:e})}pipe(e){return oc.create(this,e)}readonly(){return sc.create(this)}isOptional(){return this.safeParse(void 0).success}isNullable(){return this.safeParse(null).success}},os=/^c[^\s-]{8,}$/i,ss=/^[0-9a-z]+$/,cs=/^[0-9A-HJKMNP-TV-Z]{26}$/i,ls=/^[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,us=/^[a-z0-9_-]{21}$/i,ds=/^[A-Za-z0-9-_]+\.[A-Za-z0-9-_]+\.[A-Za-z0-9-_]*$/,fs=/^[-+]?P(?!$)(?:(?:[-+]?\d+Y)|(?:[-+]?\d+[.,]\d+Y$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:(?:[-+]?\d+W)|(?:[-+]?\d+[.,]\d+W$))?(?:(?:[-+]?\d+D)|(?:[-+]?\d+[.,]\d+D$))?(?:T(?=[\d+-])(?:(?:[-+]?\d+H)|(?:[-+]?\d+[.,]\d+H$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:[-+]?\d+(?:[.,]\d+)?S)?)??$/,ps=/^(?!\.)(?!.*\.\.)([A-Z0-9_'+\-\.]*)[A-Z0-9_+-]@([A-Z0-9][A-Z0-9\-]*\.)+[A-Z]{2,}$/i,ms=`^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$`,hs,gs=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/,_s=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\/(3[0-2]|[12]?[0-9])$/,vs=/^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))$/,ys=/^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/,bs=/^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/,xs=/^([0-9a-zA-Z-_]{4})*(([0-9a-zA-Z-_]{2}(==)?)|([0-9a-zA-Z-_]{3}(=)?))?$/,Ss=`((\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-((0[13578]|1[02])-(0[1-9]|[12]\\d|3[01])|(0[469]|11)-(0[1-9]|[12]\\d|30)|(02)-(0[1-9]|1\\d|2[0-8])))`,Cs=RegExp(`^${Ss}$`);function ws(e){let t=`[0-5]\\d`;e.precision?t=`${t}\\.\\d{${e.precision}}`:e.precision??(t=`${t}(\\.\\d+)?`);let n=e.precision?`+`:`?`;return`([01]\\d|2[0-3]):[0-5]\\d(:${t})${n}`}function Ts(e){return RegExp(`^${ws(e)}$`)}function Es(e){let t=`${Ss}T${ws(e)}`,n=[];return n.push(e.local?`Z?`:`Z`),e.offset&&n.push(`([+-]\\d{2}:?\\d{2})`),t=`${t}(${n.join(`|`)})`,RegExp(`^${t}$`)}function Ds(e,t){return!!((t===`v4`||!t)&&gs.test(e)||(t===`v6`||!t)&&vs.test(e))}function Os(e,t){if(!ds.test(e))return!1;try{let[n]=e.split(`.`);if(!n)return!1;let r=n.replace(/-/g,`+`).replace(/_/g,`/`).padEnd(n.length+(4-n.length%4)%4,`=`),i=JSON.parse(atob(r));return!(typeof i!=`object`||!i||`typ`in i&&i?.typ!==`JWT`||!i.alg||t&&i.alg!==t)}catch{return!1}}function ks(e,t){return!!((t===`v4`||!t)&&_s.test(e)||(t===`v6`||!t)&&ys.test(e))}var As=class e extends U{_parse(e){if(this._def.coerce&&(e.data=String(e.data)),this._getType(e)!==j.string){let t=this._getOrReturnCtx(e);return F(t,{code:N.invalid_type,expected:j.string,received:t.parsedType}),L}let t=new I,n;for(let r of this._def.checks)if(r.kind===`min`)e.data.length<r.value&&(n=this._getOrReturnCtx(e,n),F(n,{code:N.too_small,minimum:r.value,type:`string`,inclusive:!0,exact:!1,message:r.message}),t.dirty());else if(r.kind===`max`)e.data.length>r.value&&(n=this._getOrReturnCtx(e,n),F(n,{code:N.too_big,maximum:r.value,type:`string`,inclusive:!0,exact:!1,message:r.message}),t.dirty());else if(r.kind===`length`){let i=e.data.length>r.value,a=e.data.length<r.value;(i||a)&&(n=this._getOrReturnCtx(e,n),i?F(n,{code:N.too_big,maximum:r.value,type:`string`,inclusive:!0,exact:!0,message:r.message}):a&&F(n,{code:N.too_small,minimum:r.value,type:`string`,inclusive:!0,exact:!0,message:r.message}),t.dirty())}else if(r.kind===`email`)ps.test(e.data)||(n=this._getOrReturnCtx(e,n),F(n,{validation:`email`,code:N.invalid_string,message:r.message}),t.dirty());else if(r.kind===`emoji`)hs||=new RegExp(ms,`u`),hs.test(e.data)||(n=this._getOrReturnCtx(e,n),F(n,{validation:`emoji`,code:N.invalid_string,message:r.message}),t.dirty());else if(r.kind===`uuid`)ls.test(e.data)||(n=this._getOrReturnCtx(e,n),F(n,{validation:`uuid`,code:N.invalid_string,message:r.message}),t.dirty());else if(r.kind===`nanoid`)us.test(e.data)||(n=this._getOrReturnCtx(e,n),F(n,{validation:`nanoid`,code:N.invalid_string,message:r.message}),t.dirty());else if(r.kind===`cuid`)os.test(e.data)||(n=this._getOrReturnCtx(e,n),F(n,{validation:`cuid`,code:N.invalid_string,message:r.message}),t.dirty());else if(r.kind===`cuid2`)ss.test(e.data)||(n=this._getOrReturnCtx(e,n),F(n,{validation:`cuid2`,code:N.invalid_string,message:r.message}),t.dirty());else if(r.kind===`ulid`)cs.test(e.data)||(n=this._getOrReturnCtx(e,n),F(n,{validation:`ulid`,code:N.invalid_string,message:r.message}),t.dirty());else if(r.kind===`url`)try{new URL(e.data)}catch{n=this._getOrReturnCtx(e,n),F(n,{validation:`url`,code:N.invalid_string,message:r.message}),t.dirty()}else r.kind===`regex`?(r.regex.lastIndex=0,r.regex.test(e.data)||(n=this._getOrReturnCtx(e,n),F(n,{validation:`regex`,code:N.invalid_string,message:r.message}),t.dirty())):r.kind===`trim`?e.data=e.data.trim():r.kind===`includes`?e.data.includes(r.value,r.position)||(n=this._getOrReturnCtx(e,n),F(n,{code:N.invalid_string,validation:{includes:r.value,position:r.position},message:r.message}),t.dirty()):r.kind===`toLowerCase`?e.data=e.data.toLowerCase():r.kind===`toUpperCase`?e.data=e.data.toUpperCase():r.kind===`startsWith`?e.data.startsWith(r.value)||(n=this._getOrReturnCtx(e,n),F(n,{code:N.invalid_string,validation:{startsWith:r.value},message:r.message}),t.dirty()):r.kind===`endsWith`?e.data.endsWith(r.value)||(n=this._getOrReturnCtx(e,n),F(n,{code:N.invalid_string,validation:{endsWith:r.value},message:r.message}),t.dirty()):r.kind===`datetime`?Es(r).test(e.data)||(n=this._getOrReturnCtx(e,n),F(n,{code:N.invalid_string,validation:`datetime`,message:r.message}),t.dirty()):r.kind===`date`?Cs.test(e.data)||(n=this._getOrReturnCtx(e,n),F(n,{code:N.invalid_string,validation:`date`,message:r.message}),t.dirty()):r.kind===`time`?Ts(r).test(e.data)||(n=this._getOrReturnCtx(e,n),F(n,{code:N.invalid_string,validation:`time`,message:r.message}),t.dirty()):r.kind===`duration`?fs.test(e.data)||(n=this._getOrReturnCtx(e,n),F(n,{validation:`duration`,code:N.invalid_string,message:r.message}),t.dirty()):r.kind===`ip`?Ds(e.data,r.version)||(n=this._getOrReturnCtx(e,n),F(n,{validation:`ip`,code:N.invalid_string,message:r.message}),t.dirty()):r.kind===`jwt`?Os(e.data,r.alg)||(n=this._getOrReturnCtx(e,n),F(n,{validation:`jwt`,code:N.invalid_string,message:r.message}),t.dirty()):r.kind===`cidr`?ks(e.data,r.version)||(n=this._getOrReturnCtx(e,n),F(n,{validation:`cidr`,code:N.invalid_string,message:r.message}),t.dirty()):r.kind===`base64`?bs.test(e.data)||(n=this._getOrReturnCtx(e,n),F(n,{validation:`base64`,code:N.invalid_string,message:r.message}),t.dirty()):r.kind===`base64url`?xs.test(e.data)||(n=this._getOrReturnCtx(e,n),F(n,{validation:`base64url`,code:N.invalid_string,message:r.message}),t.dirty()):A.assertNever(r);return{status:t.value,value:e.data}}_regex(e,t,n){return this.refinement(t=>e.test(t),{validation:t,code:N.invalid_string,...B.errToObj(n)})}_addCheck(t){return new e({...this._def,checks:[...this._def.checks,t]})}email(e){return this._addCheck({kind:`email`,...B.errToObj(e)})}url(e){return this._addCheck({kind:`url`,...B.errToObj(e)})}emoji(e){return this._addCheck({kind:`emoji`,...B.errToObj(e)})}uuid(e){return this._addCheck({kind:`uuid`,...B.errToObj(e)})}nanoid(e){return this._addCheck({kind:`nanoid`,...B.errToObj(e)})}cuid(e){return this._addCheck({kind:`cuid`,...B.errToObj(e)})}cuid2(e){return this._addCheck({kind:`cuid2`,...B.errToObj(e)})}ulid(e){return this._addCheck({kind:`ulid`,...B.errToObj(e)})}base64(e){return this._addCheck({kind:`base64`,...B.errToObj(e)})}base64url(e){return this._addCheck({kind:`base64url`,...B.errToObj(e)})}jwt(e){return this._addCheck({kind:`jwt`,...B.errToObj(e)})}ip(e){return this._addCheck({kind:`ip`,...B.errToObj(e)})}cidr(e){return this._addCheck({kind:`cidr`,...B.errToObj(e)})}datetime(e){return typeof e==`string`?this._addCheck({kind:`datetime`,precision:null,offset:!1,local:!1,message:e}):this._addCheck({kind:`datetime`,precision:e?.precision===void 0?null:e?.precision,offset:e?.offset??!1,local:e?.local??!1,...B.errToObj(e?.message)})}date(e){return this._addCheck({kind:`date`,message:e})}time(e){return typeof e==`string`?this._addCheck({kind:`time`,precision:null,message:e}):this._addCheck({kind:`time`,precision:e?.precision===void 0?null:e?.precision,...B.errToObj(e?.message)})}duration(e){return this._addCheck({kind:`duration`,...B.errToObj(e)})}regex(e,t){return this._addCheck({kind:`regex`,regex:e,...B.errToObj(t)})}includes(e,t){return this._addCheck({kind:`includes`,value:e,position:t?.position,...B.errToObj(t?.message)})}startsWith(e,t){return this._addCheck({kind:`startsWith`,value:e,...B.errToObj(t)})}endsWith(e,t){return this._addCheck({kind:`endsWith`,value:e,...B.errToObj(t)})}min(e,t){return this._addCheck({kind:`min`,value:e,...B.errToObj(t)})}max(e,t){return this._addCheck({kind:`max`,value:e,...B.errToObj(t)})}length(e,t){return this._addCheck({kind:`length`,value:e,...B.errToObj(t)})}nonempty(e){return this.min(1,B.errToObj(e))}trim(){return new e({...this._def,checks:[...this._def.checks,{kind:`trim`}]})}toLowerCase(){return new e({...this._def,checks:[...this._def.checks,{kind:`toLowerCase`}]})}toUpperCase(){return new e({...this._def,checks:[...this._def.checks,{kind:`toUpperCase`}]})}get isDatetime(){return!!this._def.checks.find(e=>e.kind===`datetime`)}get isDate(){return!!this._def.checks.find(e=>e.kind===`date`)}get isTime(){return!!this._def.checks.find(e=>e.kind===`time`)}get isDuration(){return!!this._def.checks.find(e=>e.kind===`duration`)}get isEmail(){return!!this._def.checks.find(e=>e.kind===`email`)}get isURL(){return!!this._def.checks.find(e=>e.kind===`url`)}get isEmoji(){return!!this._def.checks.find(e=>e.kind===`emoji`)}get isUUID(){return!!this._def.checks.find(e=>e.kind===`uuid`)}get isNANOID(){return!!this._def.checks.find(e=>e.kind===`nanoid`)}get isCUID(){return!!this._def.checks.find(e=>e.kind===`cuid`)}get isCUID2(){return!!this._def.checks.find(e=>e.kind===`cuid2`)}get isULID(){return!!this._def.checks.find(e=>e.kind===`ulid`)}get isIP(){return!!this._def.checks.find(e=>e.kind===`ip`)}get isCIDR(){return!!this._def.checks.find(e=>e.kind===`cidr`)}get isBase64(){return!!this._def.checks.find(e=>e.kind===`base64`)}get isBase64url(){return!!this._def.checks.find(e=>e.kind===`base64url`)}get minLength(){let e=null;for(let t of this._def.checks)t.kind===`min`&&(e===null||t.value>e)&&(e=t.value);return e}get maxLength(){let e=null;for(let t of this._def.checks)t.kind===`max`&&(e===null||t.value<e)&&(e=t.value);return e}};As.create=e=>new As({checks:[],typeName:$.ZodString,coerce:e?.coerce??!1,...H(e)});function js(e,t){let n=(e.toString().split(`.`)[1]||``).length,r=(t.toString().split(`.`)[1]||``).length,i=n>r?n:r;return Number.parseInt(e.toFixed(i).replace(`.`,``))%Number.parseInt(t.toFixed(i).replace(`.`,``))/10**i}var Ms=class e extends U{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)!==j.number){let t=this._getOrReturnCtx(e);return F(t,{code:N.invalid_type,expected:j.number,received:t.parsedType}),L}let t,n=new I;for(let r of this._def.checks)r.kind===`int`?A.isInteger(e.data)||(t=this._getOrReturnCtx(e,t),F(t,{code:N.invalid_type,expected:`integer`,received:`float`,message:r.message}),n.dirty()):r.kind===`min`?(r.inclusive?e.data<r.value:e.data<=r.value)&&(t=this._getOrReturnCtx(e,t),F(t,{code:N.too_small,minimum:r.value,type:`number`,inclusive:r.inclusive,exact:!1,message:r.message}),n.dirty()):r.kind===`max`?(r.inclusive?e.data>r.value:e.data>=r.value)&&(t=this._getOrReturnCtx(e,t),F(t,{code:N.too_big,maximum:r.value,type:`number`,inclusive:r.inclusive,exact:!1,message:r.message}),n.dirty()):r.kind===`multipleOf`?js(e.data,r.value)!==0&&(t=this._getOrReturnCtx(e,t),F(t,{code:N.not_multiple_of,multipleOf:r.value,message:r.message}),n.dirty()):r.kind===`finite`?Number.isFinite(e.data)||(t=this._getOrReturnCtx(e,t),F(t,{code:N.not_finite,message:r.message}),n.dirty()):A.assertNever(r);return{status:n.value,value:e.data}}gte(e,t){return this.setLimit(`min`,e,!0,B.toString(t))}gt(e,t){return this.setLimit(`min`,e,!1,B.toString(t))}lte(e,t){return this.setLimit(`max`,e,!0,B.toString(t))}lt(e,t){return this.setLimit(`max`,e,!1,B.toString(t))}setLimit(t,n,r,i){return new e({...this._def,checks:[...this._def.checks,{kind:t,value:n,inclusive:r,message:B.toString(i)}]})}_addCheck(t){return new e({...this._def,checks:[...this._def.checks,t]})}int(e){return this._addCheck({kind:`int`,message:B.toString(e)})}positive(e){return this._addCheck({kind:`min`,value:0,inclusive:!1,message:B.toString(e)})}negative(e){return this._addCheck({kind:`max`,value:0,inclusive:!1,message:B.toString(e)})}nonpositive(e){return this._addCheck({kind:`max`,value:0,inclusive:!0,message:B.toString(e)})}nonnegative(e){return this._addCheck({kind:`min`,value:0,inclusive:!0,message:B.toString(e)})}multipleOf(e,t){return this._addCheck({kind:`multipleOf`,value:e,message:B.toString(t)})}finite(e){return this._addCheck({kind:`finite`,message:B.toString(e)})}safe(e){return this._addCheck({kind:`min`,inclusive:!0,value:-(2**53-1),message:B.toString(e)})._addCheck({kind:`max`,inclusive:!0,value:2**53-1,message:B.toString(e)})}get minValue(){let e=null;for(let t of this._def.checks)t.kind===`min`&&(e===null||t.value>e)&&(e=t.value);return e}get maxValue(){let e=null;for(let t of this._def.checks)t.kind===`max`&&(e===null||t.value<e)&&(e=t.value);return e}get isInt(){return!!this._def.checks.find(e=>e.kind===`int`||e.kind===`multipleOf`&&A.isInteger(e.value))}get isFinite(){let e=null,t=null;for(let n of this._def.checks)if(n.kind===`finite`||n.kind===`int`||n.kind===`multipleOf`)return!0;else n.kind===`min`?(t===null||n.value>t)&&(t=n.value):n.kind===`max`&&(e===null||n.value<e)&&(e=n.value);return Number.isFinite(t)&&Number.isFinite(e)}};Ms.create=e=>new Ms({checks:[],typeName:$.ZodNumber,coerce:e?.coerce||!1,...H(e)});var Ns=class e extends U{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte}_parse(e){if(this._def.coerce)try{e.data=BigInt(e.data)}catch{return this._getInvalidInput(e)}if(this._getType(e)!==j.bigint)return this._getInvalidInput(e);let t,n=new I;for(let r of this._def.checks)r.kind===`min`?(r.inclusive?e.data<r.value:e.data<=r.value)&&(t=this._getOrReturnCtx(e,t),F(t,{code:N.too_small,type:`bigint`,minimum:r.value,inclusive:r.inclusive,message:r.message}),n.dirty()):r.kind===`max`?(r.inclusive?e.data>r.value:e.data>=r.value)&&(t=this._getOrReturnCtx(e,t),F(t,{code:N.too_big,type:`bigint`,maximum:r.value,inclusive:r.inclusive,message:r.message}),n.dirty()):r.kind===`multipleOf`?e.data%r.value!==BigInt(0)&&(t=this._getOrReturnCtx(e,t),F(t,{code:N.not_multiple_of,multipleOf:r.value,message:r.message}),n.dirty()):A.assertNever(r);return{status:n.value,value:e.data}}_getInvalidInput(e){let t=this._getOrReturnCtx(e);return F(t,{code:N.invalid_type,expected:j.bigint,received:t.parsedType}),L}gte(e,t){return this.setLimit(`min`,e,!0,B.toString(t))}gt(e,t){return this.setLimit(`min`,e,!1,B.toString(t))}lte(e,t){return this.setLimit(`max`,e,!0,B.toString(t))}lt(e,t){return this.setLimit(`max`,e,!1,B.toString(t))}setLimit(t,n,r,i){return new e({...this._def,checks:[...this._def.checks,{kind:t,value:n,inclusive:r,message:B.toString(i)}]})}_addCheck(t){return new e({...this._def,checks:[...this._def.checks,t]})}positive(e){return this._addCheck({kind:`min`,value:BigInt(0),inclusive:!1,message:B.toString(e)})}negative(e){return this._addCheck({kind:`max`,value:BigInt(0),inclusive:!1,message:B.toString(e)})}nonpositive(e){return this._addCheck({kind:`max`,value:BigInt(0),inclusive:!0,message:B.toString(e)})}nonnegative(e){return this._addCheck({kind:`min`,value:BigInt(0),inclusive:!0,message:B.toString(e)})}multipleOf(e,t){return this._addCheck({kind:`multipleOf`,value:e,message:B.toString(t)})}get minValue(){let e=null;for(let t of this._def.checks)t.kind===`min`&&(e===null||t.value>e)&&(e=t.value);return e}get maxValue(){let e=null;for(let t of this._def.checks)t.kind===`max`&&(e===null||t.value<e)&&(e=t.value);return e}};Ns.create=e=>new Ns({checks:[],typeName:$.ZodBigInt,coerce:e?.coerce??!1,...H(e)});var Ps=class extends U{_parse(e){if(this._def.coerce&&(e.data=!!e.data),this._getType(e)!==j.boolean){let t=this._getOrReturnCtx(e);return F(t,{code:N.invalid_type,expected:j.boolean,received:t.parsedType}),L}return R(e.data)}};Ps.create=e=>new Ps({typeName:$.ZodBoolean,coerce:e?.coerce||!1,...H(e)});var Fs=class e extends U{_parse(e){if(this._def.coerce&&(e.data=new Date(e.data)),this._getType(e)!==j.date){let t=this._getOrReturnCtx(e);return F(t,{code:N.invalid_type,expected:j.date,received:t.parsedType}),L}if(Number.isNaN(e.data.getTime()))return F(this._getOrReturnCtx(e),{code:N.invalid_date}),L;let t=new I,n;for(let r of this._def.checks)r.kind===`min`?e.data.getTime()<r.value&&(n=this._getOrReturnCtx(e,n),F(n,{code:N.too_small,message:r.message,inclusive:!0,exact:!1,minimum:r.value,type:`date`}),t.dirty()):r.kind===`max`?e.data.getTime()>r.value&&(n=this._getOrReturnCtx(e,n),F(n,{code:N.too_big,message:r.message,inclusive:!0,exact:!1,maximum:r.value,type:`date`}),t.dirty()):A.assertNever(r);return{status:t.value,value:new Date(e.data.getTime())}}_addCheck(t){return new e({...this._def,checks:[...this._def.checks,t]})}min(e,t){return this._addCheck({kind:`min`,value:e.getTime(),message:B.toString(t)})}max(e,t){return this._addCheck({kind:`max`,value:e.getTime(),message:B.toString(t)})}get minDate(){let e=null;for(let t of this._def.checks)t.kind===`min`&&(e===null||t.value>e)&&(e=t.value);return e==null?null:new Date(e)}get maxDate(){let e=null;for(let t of this._def.checks)t.kind===`max`&&(e===null||t.value<e)&&(e=t.value);return e==null?null:new Date(e)}};Fs.create=e=>new Fs({checks:[],coerce:e?.coerce||!1,typeName:$.ZodDate,...H(e)});var Is=class extends U{_parse(e){if(this._getType(e)!==j.symbol){let t=this._getOrReturnCtx(e);return F(t,{code:N.invalid_type,expected:j.symbol,received:t.parsedType}),L}return R(e.data)}};Is.create=e=>new Is({typeName:$.ZodSymbol,...H(e)});var Ls=class extends U{_parse(e){if(this._getType(e)!==j.undefined){let t=this._getOrReturnCtx(e);return F(t,{code:N.invalid_type,expected:j.undefined,received:t.parsedType}),L}return R(e.data)}};Ls.create=e=>new Ls({typeName:$.ZodUndefined,...H(e)});var Rs=class extends U{_parse(e){if(this._getType(e)!==j.null){let t=this._getOrReturnCtx(e);return F(t,{code:N.invalid_type,expected:j.null,received:t.parsedType}),L}return R(e.data)}};Rs.create=e=>new Rs({typeName:$.ZodNull,...H(e)});var zs=class extends U{constructor(){super(...arguments),this._any=!0}_parse(e){return R(e.data)}};zs.create=e=>new zs({typeName:$.ZodAny,...H(e)});var W=class extends U{constructor(){super(...arguments),this._unknown=!0}_parse(e){return R(e.data)}};W.create=e=>new W({typeName:$.ZodUnknown,...H(e)});var G=class extends U{_parse(e){let t=this._getOrReturnCtx(e);return F(t,{code:N.invalid_type,expected:j.never,received:t.parsedType}),L}};G.create=e=>new G({typeName:$.ZodNever,...H(e)});var Bs=class extends U{_parse(e){if(this._getType(e)!==j.undefined){let t=this._getOrReturnCtx(e);return F(t,{code:N.invalid_type,expected:j.void,received:t.parsedType}),L}return R(e.data)}};Bs.create=e=>new Bs({typeName:$.ZodVoid,...H(e)});var K=class e extends U{_parse(e){let{ctx:t,status:n}=this._processInputParams(e),r=this._def;if(t.parsedType!==j.array)return F(t,{code:N.invalid_type,expected:j.array,received:t.parsedType}),L;if(r.exactLength!==null){let e=t.data.length>r.exactLength.value,i=t.data.length<r.exactLength.value;(e||i)&&(F(t,{code:e?N.too_big:N.too_small,minimum:i?r.exactLength.value:void 0,maximum:e?r.exactLength.value:void 0,type:`array`,inclusive:!0,exact:!0,message:r.exactLength.message}),n.dirty())}if(r.minLength!==null&&t.data.length<r.minLength.value&&(F(t,{code:N.too_small,minimum:r.minLength.value,type:`array`,inclusive:!0,exact:!1,message:r.minLength.message}),n.dirty()),r.maxLength!==null&&t.data.length>r.maxLength.value&&(F(t,{code:N.too_big,maximum:r.maxLength.value,type:`array`,inclusive:!0,exact:!1,message:r.maxLength.message}),n.dirty()),t.common.async)return Promise.all([...t.data].map((e,n)=>r.type._parseAsync(new V(t,e,t.path,n)))).then(e=>I.mergeArray(n,e));let i=[...t.data].map((e,n)=>r.type._parseSync(new V(t,e,t.path,n)));return I.mergeArray(n,i)}get element(){return this._def.type}min(t,n){return new e({...this._def,minLength:{value:t,message:B.toString(n)}})}max(t,n){return new e({...this._def,maxLength:{value:t,message:B.toString(n)}})}length(t,n){return new e({...this._def,exactLength:{value:t,message:B.toString(n)}})}nonempty(e){return this.min(1,e)}};K.create=(e,t)=>new K({type:e,minLength:null,maxLength:null,exactLength:null,typeName:$.ZodArray,...H(t)});function Vs(e){if(e instanceof q){let t={};for(let n in e.shape){let r=e.shape[n];t[n]=Z.create(Vs(r))}return new q({...e._def,shape:()=>t})}else if(e instanceof K)return new K({...e._def,type:Vs(e.element)});else if(e instanceof Z)return Z.create(Vs(e.unwrap()));else if(e instanceof Q)return Q.create(Vs(e.unwrap()));else if(e instanceof Y)return Y.create(e.items.map(e=>Vs(e)));else return e}var q=class e extends U{constructor(){super(...arguments),this._cached=null,this.nonstrict=this.passthrough,this.augment=this.extend}_getCached(){if(this._cached!==null)return this._cached;let e=this._def.shape(),t=A.objectKeys(e);return this._cached={shape:e,keys:t},this._cached}_parse(e){if(this._getType(e)!==j.object){let t=this._getOrReturnCtx(e);return F(t,{code:N.invalid_type,expected:j.object,received:t.parsedType}),L}let{status:t,ctx:n}=this._processInputParams(e),{shape:r,keys:i}=this._getCached(),a=[];if(!(this._def.catchall instanceof G&&this._def.unknownKeys===`strip`))for(let e in n.data)i.includes(e)||a.push(e);let o=[];for(let e of i){let t=r[e],i=n.data[e];o.push({key:{status:`valid`,value:e},value:t._parse(new V(n,i,n.path,e)),alwaysSet:e in n.data})}if(this._def.catchall instanceof G){let e=this._def.unknownKeys;if(e===`passthrough`)for(let e of a)o.push({key:{status:`valid`,value:e},value:{status:`valid`,value:n.data[e]}});else if(e===`strict`)a.length>0&&(F(n,{code:N.unrecognized_keys,keys:a}),t.dirty());else if(e!==`strip`)throw Error(`Internal ZodObject error: invalid unknownKeys value.`)}else{let e=this._def.catchall;for(let t of a){let r=n.data[t];o.push({key:{status:`valid`,value:t},value:e._parse(new V(n,r,n.path,t)),alwaysSet:t in n.data})}}return n.common.async?Promise.resolve().then(async()=>{let e=[];for(let t of o){let n=await t.key,r=await t.value;e.push({key:n,value:r,alwaysSet:t.alwaysSet})}return e}).then(e=>I.mergeObjectSync(t,e)):I.mergeObjectSync(t,o)}get shape(){return this._def.shape()}strict(t){return B.errToObj,new e({...this._def,unknownKeys:`strict`,...t===void 0?{}:{errorMap:(e,n)=>{let r=this._def.errorMap?.(e,n).message??n.defaultError;return e.code===`unrecognized_keys`?{message:B.errToObj(t).message??r}:{message:r}}}})}strip(){return new e({...this._def,unknownKeys:`strip`})}passthrough(){return new e({...this._def,unknownKeys:`passthrough`})}extend(t){return new e({...this._def,shape:()=>({...this._def.shape(),...t})})}merge(t){return new e({unknownKeys:t._def.unknownKeys,catchall:t._def.catchall,shape:()=>({...this._def.shape(),...t._def.shape()}),typeName:$.ZodObject})}setKey(e,t){return this.augment({[e]:t})}catchall(t){return new e({...this._def,catchall:t})}pick(t){let n={};for(let e of A.objectKeys(t))t[e]&&this.shape[e]&&(n[e]=this.shape[e]);return new e({...this._def,shape:()=>n})}omit(t){let n={};for(let e of A.objectKeys(this.shape))t[e]||(n[e]=this.shape[e]);return new e({...this._def,shape:()=>n})}deepPartial(){return Vs(this)}partial(t){let n={};for(let e of A.objectKeys(this.shape)){let r=this.shape[e];t&&!t[e]?n[e]=r:n[e]=r.optional()}return new e({...this._def,shape:()=>n})}required(t){let n={};for(let e of A.objectKeys(this.shape))if(t&&!t[e])n[e]=this.shape[e];else{let t=this.shape[e];for(;t instanceof Z;)t=t._def.innerType;n[e]=t}return new e({...this._def,shape:()=>n})}keyof(){return Qs(A.objectKeys(this.shape))}};q.create=(e,t)=>new q({shape:()=>e,unknownKeys:`strip`,catchall:G.create(),typeName:$.ZodObject,...H(t)}),q.strictCreate=(e,t)=>new q({shape:()=>e,unknownKeys:`strict`,catchall:G.create(),typeName:$.ZodObject,...H(t)}),q.lazycreate=(e,t)=>new q({shape:e,unknownKeys:`strip`,catchall:G.create(),typeName:$.ZodObject,...H(t)});var Hs=class extends U{_parse(e){let{ctx:t}=this._processInputParams(e),n=this._def.options;function r(e){for(let t of e)if(t.result.status===`valid`)return t.result;for(let n of e)if(n.result.status===`dirty`)return t.common.issues.push(...n.ctx.common.issues),n.result;let n=e.map(e=>new P(e.ctx.common.issues));return F(t,{code:N.invalid_union,unionErrors:n}),L}if(t.common.async)return Promise.all(n.map(async e=>{let n={...t,common:{...t.common,issues:[]},parent:null};return{result:await e._parseAsync({data:t.data,path:t.path,parent:n}),ctx:n}})).then(r);{let e,r=[];for(let i of n){let n={...t,common:{...t.common,issues:[]},parent:null},a=i._parseSync({data:t.data,path:t.path,parent:n});if(a.status===`valid`)return a;a.status===`dirty`&&!e&&(e={result:a,ctx:n}),n.common.issues.length&&r.push(n.common.issues)}if(e)return t.common.issues.push(...e.ctx.common.issues),e.result;let i=r.map(e=>new P(e));return F(t,{code:N.invalid_union,unionErrors:i}),L}}get options(){return this._def.options}};Hs.create=(e,t)=>new Hs({options:e,typeName:$.ZodUnion,...H(t)});var J=e=>e instanceof Xs?J(e.schema):e instanceof X?J(e.innerType()):e instanceof Zs?[e.value]:e instanceof $s?e.options:e instanceof ec?A.objectValues(e.enum):e instanceof nc?J(e._def.innerType):e instanceof Ls?[void 0]:e instanceof Rs?[null]:e instanceof Z?[void 0,...J(e.unwrap())]:e instanceof Q?[null,...J(e.unwrap())]:e instanceof ac||e instanceof sc?J(e.unwrap()):e instanceof rc?J(e._def.innerType):[],Us=class e extends U{_parse(e){let{ctx:t}=this._processInputParams(e);if(t.parsedType!==j.object)return F(t,{code:N.invalid_type,expected:j.object,received:t.parsedType}),L;let n=this.discriminator,r=t.data[n],i=this.optionsMap.get(r);return i?t.common.async?i._parseAsync({data:t.data,path:t.path,parent:t}):i._parseSync({data:t.data,path:t.path,parent:t}):(F(t,{code:N.invalid_union_discriminator,options:Array.from(this.optionsMap.keys()),path:[n]}),L)}get discriminator(){return this._def.discriminator}get options(){return this._def.options}get optionsMap(){return this._def.optionsMap}static create(t,n,r){let i=new Map;for(let e of n){let n=J(e.shape[t]);if(!n.length)throw Error(`A discriminator value for key \`${t}\` could not be extracted from all schema options`);for(let r of n){if(i.has(r))throw Error(`Discriminator property ${String(t)} has duplicate value ${String(r)}`);i.set(r,e)}}return new e({typeName:$.ZodDiscriminatedUnion,discriminator:t,options:n,optionsMap:i,...H(r)})}};function Ws(e,t){let n=M(e),r=M(t);if(e===t)return{valid:!0,data:e};if(n===j.object&&r===j.object){let n=A.objectKeys(t),r=A.objectKeys(e).filter(e=>n.indexOf(e)!==-1),i={...e,...t};for(let n of r){let r=Ws(e[n],t[n]);if(!r.valid)return{valid:!1};i[n]=r.data}return{valid:!0,data:i}}else if(n===j.array&&r===j.array){if(e.length!==t.length)return{valid:!1};let n=[];for(let r=0;r<e.length;r++){let i=e[r],a=t[r],o=Ws(i,a);if(!o.valid)return{valid:!1};n.push(o.data)}return{valid:!0,data:n}}else if(n===j.date&&r===j.date&&+e==+t)return{valid:!0,data:e};else return{valid:!1}}var Gs=class extends U{_parse(e){let{status:t,ctx:n}=this._processInputParams(e),r=(e,r)=>{if(ns(e)||ns(r))return L;let i=Ws(e.value,r.value);return i.valid?((rs(e)||rs(r))&&t.dirty(),{status:t.value,value:i.data}):(F(n,{code:N.invalid_intersection_types}),L)};return n.common.async?Promise.all([this._def.left._parseAsync({data:n.data,path:n.path,parent:n}),this._def.right._parseAsync({data:n.data,path:n.path,parent:n})]).then(([e,t])=>r(e,t)):r(this._def.left._parseSync({data:n.data,path:n.path,parent:n}),this._def.right._parseSync({data:n.data,path:n.path,parent:n}))}};Gs.create=(e,t,n)=>new Gs({left:e,right:t,typeName:$.ZodIntersection,...H(n)});var Y=class e extends U{_parse(e){let{status:t,ctx:n}=this._processInputParams(e);if(n.parsedType!==j.array)return F(n,{code:N.invalid_type,expected:j.array,received:n.parsedType}),L;if(n.data.length<this._def.items.length)return F(n,{code:N.too_small,minimum:this._def.items.length,inclusive:!0,exact:!1,type:`array`}),L;!this._def.rest&&n.data.length>this._def.items.length&&(F(n,{code:N.too_big,maximum:this._def.items.length,inclusive:!0,exact:!1,type:`array`}),t.dirty());let r=[...n.data].map((e,t)=>{let r=this._def.items[t]||this._def.rest;return r?r._parse(new V(n,e,n.path,t)):null}).filter(e=>!!e);return n.common.async?Promise.all(r).then(e=>I.mergeArray(t,e)):I.mergeArray(t,r)}get items(){return this._def.items}rest(t){return new e({...this._def,rest:t})}};Y.create=(e,t)=>{if(!Array.isArray(e))throw Error(`You must pass an array of schemas to z.tuple([ ... ])`);return new Y({items:e,typeName:$.ZodTuple,rest:null,...H(t)})};var Ks=class e extends U{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(e){let{status:t,ctx:n}=this._processInputParams(e);if(n.parsedType!==j.object)return F(n,{code:N.invalid_type,expected:j.object,received:n.parsedType}),L;let r=[],i=this._def.keyType,a=this._def.valueType;for(let e in n.data)r.push({key:i._parse(new V(n,e,n.path,e)),value:a._parse(new V(n,n.data[e],n.path,e)),alwaysSet:e in n.data});return n.common.async?I.mergeObjectAsync(t,r):I.mergeObjectSync(t,r)}get element(){return this._def.valueType}static create(t,n,r){return n instanceof U?new e({keyType:t,valueType:n,typeName:$.ZodRecord,...H(r)}):new e({keyType:As.create(),valueType:t,typeName:$.ZodRecord,...H(n)})}},qs=class extends U{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(e){let{status:t,ctx:n}=this._processInputParams(e);if(n.parsedType!==j.map)return F(n,{code:N.invalid_type,expected:j.map,received:n.parsedType}),L;let r=this._def.keyType,i=this._def.valueType,a=[...n.data.entries()].map(([e,t],a)=>({key:r._parse(new V(n,e,n.path,[a,`key`])),value:i._parse(new V(n,t,n.path,[a,`value`]))}));if(n.common.async){let e=new Map;return Promise.resolve().then(async()=>{for(let n of a){let r=await n.key,i=await n.value;if(r.status===`aborted`||i.status===`aborted`)return L;(r.status===`dirty`||i.status===`dirty`)&&t.dirty(),e.set(r.value,i.value)}return{status:t.value,value:e}})}else{let e=new Map;for(let n of a){let r=n.key,i=n.value;if(r.status===`aborted`||i.status===`aborted`)return L;(r.status===`dirty`||i.status===`dirty`)&&t.dirty(),e.set(r.value,i.value)}return{status:t.value,value:e}}}};qs.create=(e,t,n)=>new qs({valueType:t,keyType:e,typeName:$.ZodMap,...H(n)});var Js=class e extends U{_parse(e){let{status:t,ctx:n}=this._processInputParams(e);if(n.parsedType!==j.set)return F(n,{code:N.invalid_type,expected:j.set,received:n.parsedType}),L;let r=this._def;r.minSize!==null&&n.data.size<r.minSize.value&&(F(n,{code:N.too_small,minimum:r.minSize.value,type:`set`,inclusive:!0,exact:!1,message:r.minSize.message}),t.dirty()),r.maxSize!==null&&n.data.size>r.maxSize.value&&(F(n,{code:N.too_big,maximum:r.maxSize.value,type:`set`,inclusive:!0,exact:!1,message:r.maxSize.message}),t.dirty());let i=this._def.valueType;function a(e){let n=new Set;for(let r of e){if(r.status===`aborted`)return L;r.status===`dirty`&&t.dirty(),n.add(r.value)}return{status:t.value,value:n}}let o=[...n.data.values()].map((e,t)=>i._parse(new V(n,e,n.path,t)));return n.common.async?Promise.all(o).then(e=>a(e)):a(o)}min(t,n){return new e({...this._def,minSize:{value:t,message:B.toString(n)}})}max(t,n){return new e({...this._def,maxSize:{value:t,message:B.toString(n)}})}size(e,t){return this.min(e,t).max(e,t)}nonempty(e){return this.min(1,e)}};Js.create=(e,t)=>new Js({valueType:e,minSize:null,maxSize:null,typeName:$.ZodSet,...H(t)});var Ys=class e extends U{constructor(){super(...arguments),this.validate=this.implement}_parse(e){let{ctx:t}=this._processInputParams(e);if(t.parsedType!==j.function)return F(t,{code:N.invalid_type,expected:j.function,received:t.parsedType}),L;function n(e,n){return es({data:e,path:t.path,errorMaps:[t.common.contextualErrorMap,t.schemaErrorMap,$o(),Zo].filter(e=>!!e),issueData:{code:N.invalid_arguments,argumentsError:n}})}function r(e,n){return es({data:e,path:t.path,errorMaps:[t.common.contextualErrorMap,t.schemaErrorMap,$o(),Zo].filter(e=>!!e),issueData:{code:N.invalid_return_type,returnTypeError:n}})}let i={errorMap:t.common.contextualErrorMap},a=t.data;if(this._def.returns instanceof tc){let e=this;return R(async function(...t){let o=new P([]),s=await e._def.args.parseAsync(t,i).catch(e=>{throw o.addIssue(n(t,e)),o}),c=await Reflect.apply(a,this,s);return await e._def.returns._def.type.parseAsync(c,i).catch(e=>{throw o.addIssue(r(c,e)),o})})}else{let e=this;return R(function(...t){let o=e._def.args.safeParse(t,i);if(!o.success)throw new P([n(t,o.error)]);let s=Reflect.apply(a,this,o.data),c=e._def.returns.safeParse(s,i);if(!c.success)throw new P([r(s,c.error)]);return c.data})}}parameters(){return this._def.args}returnType(){return this._def.returns}args(...t){return new e({...this._def,args:Y.create(t).rest(W.create())})}returns(t){return new e({...this._def,returns:t})}implement(e){return this.parse(e)}strictImplement(e){return this.parse(e)}static create(t,n,r){return new e({args:t||Y.create([]).rest(W.create()),returns:n||W.create(),typeName:$.ZodFunction,...H(r)})}},Xs=class extends U{get schema(){return this._def.getter()}_parse(e){let{ctx:t}=this._processInputParams(e);return this._def.getter()._parse({data:t.data,path:t.path,parent:t})}};Xs.create=(e,t)=>new Xs({getter:e,typeName:$.ZodLazy,...H(t)});var Zs=class extends U{_parse(e){if(e.data!==this._def.value){let t=this._getOrReturnCtx(e);return F(t,{received:t.data,code:N.invalid_literal,expected:this._def.value}),L}return{status:`valid`,value:e.data}}get value(){return this._def.value}};Zs.create=(e,t)=>new Zs({value:e,typeName:$.ZodLiteral,...H(t)});function Qs(e,t){return new $s({values:e,typeName:$.ZodEnum,...H(t)})}var $s=class e extends U{_parse(e){if(typeof e.data!=`string`){let t=this._getOrReturnCtx(e),n=this._def.values;return F(t,{expected:A.joinValues(n),received:t.parsedType,code:N.invalid_type}),L}if(this._cache||=new Set(this._def.values),!this._cache.has(e.data)){let t=this._getOrReturnCtx(e),n=this._def.values;return F(t,{received:t.data,code:N.invalid_enum_value,options:n}),L}return R(e.data)}get options(){return this._def.values}get enum(){let e={};for(let t of this._def.values)e[t]=t;return e}get Values(){let e={};for(let t of this._def.values)e[t]=t;return e}get Enum(){let e={};for(let t of this._def.values)e[t]=t;return e}extract(t,n=this._def){return e.create(t,{...this._def,...n})}exclude(t,n=this._def){return e.create(this.options.filter(e=>!t.includes(e)),{...this._def,...n})}};$s.create=Qs;var ec=class extends U{_parse(e){let t=A.getValidEnumValues(this._def.values),n=this._getOrReturnCtx(e);if(n.parsedType!==j.string&&n.parsedType!==j.number){let e=A.objectValues(t);return F(n,{expected:A.joinValues(e),received:n.parsedType,code:N.invalid_type}),L}if(this._cache||=new Set(A.getValidEnumValues(this._def.values)),!this._cache.has(e.data)){let e=A.objectValues(t);return F(n,{received:n.data,code:N.invalid_enum_value,options:e}),L}return R(e.data)}get enum(){return this._def.values}};ec.create=(e,t)=>new ec({values:e,typeName:$.ZodNativeEnum,...H(t)});var tc=class extends U{unwrap(){return this._def.type}_parse(e){let{ctx:t}=this._processInputParams(e);return t.parsedType!==j.promise&&t.common.async===!1?(F(t,{code:N.invalid_type,expected:j.promise,received:t.parsedType}),L):R((t.parsedType===j.promise?t.data:Promise.resolve(t.data)).then(e=>this._def.type.parseAsync(e,{path:t.path,errorMap:t.common.contextualErrorMap})))}};tc.create=(e,t)=>new tc({type:e,typeName:$.ZodPromise,...H(t)});var X=class extends U{innerType(){return this._def.schema}sourceType(){return this._def.schema._def.typeName===$.ZodEffects?this._def.schema.sourceType():this._def.schema}_parse(e){let{status:t,ctx:n}=this._processInputParams(e),r=this._def.effect||null,i={addIssue:e=>{F(n,e),e.fatal?t.abort():t.dirty()},get path(){return n.path}};if(i.addIssue=i.addIssue.bind(i),r.type===`preprocess`){let e=r.transform(n.data,i);if(n.common.async)return Promise.resolve(e).then(async e=>{if(t.value===`aborted`)return L;let r=await this._def.schema._parseAsync({data:e,path:n.path,parent:n});return r.status===`aborted`?L:r.status===`dirty`||t.value===`dirty`?ts(r.value):r});{if(t.value===`aborted`)return L;let r=this._def.schema._parseSync({data:e,path:n.path,parent:n});return r.status===`aborted`?L:r.status===`dirty`||t.value===`dirty`?ts(r.value):r}}if(r.type===`refinement`){let e=e=>{let t=r.refinement(e,i);if(n.common.async)return Promise.resolve(t);if(t instanceof Promise)throw Error(`Async refinement encountered during synchronous parse operation. Use .parseAsync instead.`);return e};if(n.common.async===!1){let r=this._def.schema._parseSync({data:n.data,path:n.path,parent:n});return r.status===`aborted`?L:(r.status===`dirty`&&t.dirty(),e(r.value),{status:t.value,value:r.value})}else return this._def.schema._parseAsync({data:n.data,path:n.path,parent:n}).then(n=>n.status===`aborted`?L:(n.status===`dirty`&&t.dirty(),e(n.value).then(()=>({status:t.value,value:n.value}))))}if(r.type===`transform`)if(n.common.async===!1){let e=this._def.schema._parseSync({data:n.data,path:n.path,parent:n});if(!z(e))return L;let a=r.transform(e.value,i);if(a instanceof Promise)throw Error(`Asynchronous transform encountered during synchronous parse operation. Use .parseAsync instead.`);return{status:t.value,value:a}}else return this._def.schema._parseAsync({data:n.data,path:n.path,parent:n}).then(e=>z(e)?Promise.resolve(r.transform(e.value,i)).then(e=>({status:t.value,value:e})):L);A.assertNever(r)}};X.create=(e,t,n)=>new X({schema:e,typeName:$.ZodEffects,effect:t,...H(n)}),X.createWithPreprocess=(e,t,n)=>new X({schema:t,effect:{type:`preprocess`,transform:e},typeName:$.ZodEffects,...H(n)});var Z=class extends U{_parse(e){return this._getType(e)===j.undefined?R(void 0):this._def.innerType._parse(e)}unwrap(){return this._def.innerType}};Z.create=(e,t)=>new Z({innerType:e,typeName:$.ZodOptional,...H(t)});var Q=class extends U{_parse(e){return this._getType(e)===j.null?R(null):this._def.innerType._parse(e)}unwrap(){return this._def.innerType}};Q.create=(e,t)=>new Q({innerType:e,typeName:$.ZodNullable,...H(t)});var nc=class extends U{_parse(e){let{ctx:t}=this._processInputParams(e),n=t.data;return t.parsedType===j.undefined&&(n=this._def.defaultValue()),this._def.innerType._parse({data:n,path:t.path,parent:t})}removeDefault(){return this._def.innerType}};nc.create=(e,t)=>new nc({innerType:e,typeName:$.ZodDefault,defaultValue:typeof t.default==`function`?t.default:()=>t.default,...H(t)});var rc=class extends U{_parse(e){let{ctx:t}=this._processInputParams(e),n={...t,common:{...t.common,issues:[]}},r=this._def.innerType._parse({data:n.data,path:n.path,parent:{...n}});return is(r)?r.then(e=>({status:`valid`,value:e.status===`valid`?e.value:this._def.catchValue({get error(){return new P(n.common.issues)},input:n.data})})):{status:`valid`,value:r.status===`valid`?r.value:this._def.catchValue({get error(){return new P(n.common.issues)},input:n.data})}}removeCatch(){return this._def.innerType}};rc.create=(e,t)=>new rc({innerType:e,typeName:$.ZodCatch,catchValue:typeof t.catch==`function`?t.catch:()=>t.catch,...H(t)});var ic=class extends U{_parse(e){if(this._getType(e)!==j.nan){let t=this._getOrReturnCtx(e);return F(t,{code:N.invalid_type,expected:j.nan,received:t.parsedType}),L}return{status:`valid`,value:e.data}}};ic.create=e=>new ic({typeName:$.ZodNaN,...H(e)});var ac=class extends U{_parse(e){let{ctx:t}=this._processInputParams(e),n=t.data;return this._def.type._parse({data:n,path:t.path,parent:t})}unwrap(){return this._def.type}},oc=class e extends U{_parse(e){let{status:t,ctx:n}=this._processInputParams(e);if(n.common.async)return(async()=>{let e=await this._def.in._parseAsync({data:n.data,path:n.path,parent:n});return e.status===`aborted`?L:e.status===`dirty`?(t.dirty(),ts(e.value)):this._def.out._parseAsync({data:e.value,path:n.path,parent:n})})();{let e=this._def.in._parseSync({data:n.data,path:n.path,parent:n});return e.status===`aborted`?L:e.status===`dirty`?(t.dirty(),{status:`dirty`,value:e.value}):this._def.out._parseSync({data:e.value,path:n.path,parent:n})}}static create(t,n){return new e({in:t,out:n,typeName:$.ZodPipeline})}},sc=class extends U{_parse(e){let t=this._def.innerType._parse(e),n=e=>(z(e)&&(e.value=Object.freeze(e.value)),e);return is(t)?t.then(e=>n(e)):n(t)}unwrap(){return this._def.innerType}};sc.create=(e,t)=>new sc({innerType:e,typeName:$.ZodReadonly,...H(t)}),q.lazycreate;var $;(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`})($||={}),As.create,Ms.create,ic.create,Ns.create,Ps.create,Fs.create,Is.create,Ls.create,Rs.create,zs.create,W.create,G.create,Bs.create,K.create,q.create,q.strictCreate,Hs.create,Us.create,Gs.create,Y.create,Ks.create,qs.create,Js.create,Ys.create,Xs.create,Zs.create,$s.create,ec.create,tc.create,X.create,Z.create,Q.create,X.createWithPreprocess,oc.create;export{go as _,io as a,fa as b,fo as c,no as d,Ka as f,Ta as g,so as h,Qa as i,Wo as l,vo as m,bo as n,Xa as o,oo as p,Yo as r,Ko as s,$ as t,So as u,lo as v,ea as x,eo as y};
package/dist/index.html CHANGED
@@ -8,7 +8,6 @@
8
8
  - For stricter CSP, serve headers via your web server (see docs/deployment.md) and use
9
9
  nonces or hashes instead of 'unsafe-inline'.
10
10
  -->
11
- <meta http-equiv="Content-Security-Policy" content="default-src 'self'; script-src 'self' 'unsafe-inline'; style-src 'self' 'unsafe-inline'; img-src 'self' data: blob: https:; font-src 'self' data:; connect-src 'self' ws: wss: http://localhost:* https://*.objectstack.io https://*.sentry.io; worker-src 'self' blob:; frame-src 'self';" />
12
11
  <link rel="icon" type="image/svg+xml" href="/vite.svg" id="favicon" />
13
12
  <meta name="viewport" content="width=device-width, initial-scale=1.0, viewport-fit=cover" />
14
13
  <meta name="mobile-web-app-capable" content="yes" />
@@ -19,21 +18,33 @@
19
18
  <script>
20
19
  window.process = window.process || { env: { NODE_ENV: 'development' }, version: '', platform: 'browser' };
21
20
  </script>
22
- <script type="module" crossorigin src="/console/assets/index-DDpLaQOV.js"></script>
23
- <link rel="modulepreload" crossorigin href="/console/assets/rolldown-runtime-Dw2cE7zH.js">
24
- <link rel="modulepreload" crossorigin href="/console/assets/data-adapter-wZ81OFjZ.js">
25
- <link rel="modulepreload" crossorigin href="/console/assets/framework-DJlDX9E6.js">
26
- <link rel="modulepreload" crossorigin href="/console/assets/infrastructure-C6Ph6Ug0.js">
27
- <link rel="modulepreload" crossorigin href="/console/assets/plugins-core-PiAAytWV.js">
28
- <link rel="modulepreload" crossorigin href="/console/assets/vendor-objectstack-BtztJIHv.js">
29
- <link rel="modulepreload" crossorigin href="/console/assets/plugins-views-CE0VP3vl.js">
30
- <link rel="modulepreload" crossorigin href="/console/assets/vendor-react-BwtAzZZ3.js">
31
- <link rel="modulepreload" crossorigin href="/console/assets/ui-layout-DdDX0gzI.js">
32
- <link rel="stylesheet" crossorigin href="/console/assets/plugins-core-Cfhp_BXE.css">
21
+ <script type="module" crossorigin src="/console/assets/index-DATdOX6r.js"></script>
22
+ <link rel="modulepreload" crossorigin href="/console/assets/rolldown-runtime-S-ySWqyJ.js">
23
+ <link rel="modulepreload" crossorigin href="/console/assets/data-adapter-v22lWuhc.js">
24
+ <link rel="modulepreload" crossorigin href="/console/assets/framework-BW6KsEI0.js">
25
+ <link rel="modulepreload" crossorigin href="/console/assets/infrastructure-94fpO8jL.js">
26
+ <link rel="modulepreload" crossorigin href="/console/assets/plugins-core-Ccvbi6db.js">
27
+ <link rel="modulepreload" crossorigin href="/console/assets/vendor-objectstack-Dhrq31KF.js">
28
+ <link rel="modulepreload" crossorigin href="/console/assets/plugins-views-CbLIJkBs.js">
29
+ <link rel="modulepreload" crossorigin href="/console/assets/vendor-icons-CrSf7tAH.js">
30
+ <link rel="modulepreload" crossorigin href="/console/assets/vendor-react-ryfytPb-.js">
31
+ <link rel="modulepreload" crossorigin href="/console/assets/ui-layout-CYz0tyDf.js">
32
+ <link rel="modulepreload" crossorigin href="/console/assets/vendor-zod-Dfb8LXKF.js">
33
+ <link rel="modulepreload" crossorigin href="/console/assets/skeletons-CIQE_YYE.js">
34
+ <link rel="modulepreload" crossorigin href="/console/assets/MetadataInspector-DVtCDQtx.js">
35
+ <link rel="modulepreload" crossorigin href="/console/assets/RecordDetailView-CYgcTNQp.js">
36
+ <link rel="modulepreload" crossorigin href="/console/assets/AdapterProvider-Cd4HYb7q.js">
37
+ <link rel="modulepreload" crossorigin href="/console/assets/MetadataProvider-Dvc9BxbC.js">
38
+ <link rel="modulepreload" crossorigin href="/console/assets/DashboardView-BnX2k5Kx.js">
39
+ <link rel="modulepreload" crossorigin href="/console/assets/PageView-CUDEz8Xo.js">
40
+ <link rel="modulepreload" crossorigin href="/console/assets/ReportView-ovWyjJsZ.js">
41
+ <link rel="modulepreload" crossorigin href="/console/assets/SearchResultsPage-B-NchFoJ.js">
42
+ <link rel="modulepreload" crossorigin href="/console/assets/src-BGoL_8qF.js">
43
+ <link rel="stylesheet" crossorigin href="/console/assets/plugins-core-B5ROGaJH.css">
33
44
  <link rel="stylesheet" crossorigin href="/console/assets/plugins-views-DnNKJB60.css">
34
- <link rel="stylesheet" crossorigin href="/console/assets/index-D9-L0QBO.css">
35
- <link rel="modulepreload" href="/console/assets/framework-DJlDX9E6.js" />
36
- <link rel="modulepreload" href="/console/assets/vendor-react-BwtAzZZ3.js" />
45
+ <link rel="stylesheet" crossorigin href="/console/assets/index-nwlbpqhl.css">
46
+ <link rel="modulepreload" href="/console/assets/framework-BW6KsEI0.js" />
47
+ <link rel="modulepreload" href="/console/assets/vendor-react-ryfytPb-.js" />
37
48
  </head>
38
49
  <body>
39
50
  <div id="root"></div>
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@object-ui/console",
3
- "version": "3.1.5",
3
+ "version": "3.3.1",
4
4
  "description": "ObjectStack Console - The standard runtime UI for ObjectStack applications",
5
5
  "type": "module",
6
6
  "main": "./plugin.js",
@@ -22,79 +22,63 @@
22
22
  "@dnd-kit/core": "^6.3.1",
23
23
  "@dnd-kit/sortable": "^10.0.0",
24
24
  "@dnd-kit/utilities": "^3.2.2",
25
- "@objectstack/cli": "^3.3.0",
26
- "@objectstack/client": "^3.3.0",
27
- "@objectstack/driver-memory": "^3.3.0",
28
- "@objectstack/objectql": "^3.3.0",
29
- "@objectstack/plugin-msw": "^3.3.0",
30
- "@objectstack/runtime": "^3.3.0",
31
- "@objectstack/spec": "^3.3.0",
32
- "@tailwindcss/postcss": "^4.2.2",
25
+ "@objectstack/client": "^4.0.4",
26
+ "@objectstack/spec": "^4.0.4",
27
+ "@tailwindcss/postcss": "^4.2.4",
33
28
  "@testing-library/jest-dom": "^6.9.1",
34
29
  "@testing-library/react": "^16.3.2",
35
30
  "@testing-library/user-event": "^14.6.1",
36
- "@types/node": "^25.5.0",
31
+ "@types/node": "^25.6.0",
37
32
  "@types/react": "19.2.14",
38
33
  "@types/react-dom": "19.2.3",
39
34
  "@vitejs/plugin-react": "^6.0.1",
40
- "@vitest/ui": "^4.1.0",
41
- "autoprefixer": "^10.4.27",
42
- "happy-dom": "^20.8.4",
43
- "lucide-react": "^0.577.0",
44
- "msw": "^2.12.14",
45
- "postcss": "^8.5.8",
46
- "react": "19.2.4",
47
- "react-dom": "19.2.4",
48
- "react-router-dom": "^7.13.1",
35
+ "@vitest/ui": "^4.1.5",
36
+ "autoprefixer": "^10.5.0",
37
+ "happy-dom": "^20.9.0",
38
+ "lucide-react": "^1.8.0",
39
+ "postcss": "^8.5.13",
40
+ "react": "19.2.5",
41
+ "react-dom": "19.2.5",
42
+ "react-router-dom": "^7.14.2",
49
43
  "sonner": "^2.0.7",
50
- "tailwindcss": "^4.2.2",
51
- "typescript": "^5.9.3",
52
- "vite": "^8.0.1",
53
- "vitest": "^4.1.0",
54
- "@object-ui/auth": "3.1.5",
55
- "@object-ui/collaboration": "3.1.5",
56
- "@object-ui/components": "3.1.5",
57
- "@object-ui/core": "3.1.5",
58
- "@object-ui/data-objectstack": "3.1.5",
59
- "@object-ui/example-crm": "3.1.0",
60
- "@object-ui/example-kitchen-sink": "3.1.0",
61
- "@object-ui/example-todo": "3.1.0",
62
- "@object-ui/fields": "3.1.5",
63
- "@object-ui/i18n": "3.1.5",
64
- "@object-ui/layout": "3.1.5",
65
- "@object-ui/mobile": "3.1.5",
66
- "@object-ui/permissions": "3.1.5",
67
- "@object-ui/plugin-calendar": "3.1.5",
68
- "@object-ui/plugin-charts": "3.1.5",
69
- "@object-ui/plugin-dashboard": "3.1.5",
70
- "@object-ui/plugin-designer": "3.1.5",
71
- "@object-ui/plugin-detail": "3.1.5",
72
- "@object-ui/plugin-form": "3.1.5",
73
- "@object-ui/plugin-gantt": "3.1.5",
74
- "@object-ui/plugin-grid": "3.1.5",
75
- "@object-ui/plugin-kanban": "3.1.5",
76
- "@object-ui/plugin-list": "3.1.5",
77
- "@object-ui/plugin-map": "3.1.5",
78
- "@object-ui/plugin-markdown": "3.1.5",
79
- "@object-ui/plugin-report": "3.1.5",
80
- "@object-ui/plugin-timeline": "3.1.5",
81
- "@object-ui/plugin-view": "3.1.5",
82
- "@object-ui/react": "3.1.5",
83
- "@object-ui/types": "3.1.5"
84
- },
85
- "msw": {
86
- "workerDirectory": [
87
- "public"
88
- ]
44
+ "tailwindcss": "^4.2.4",
45
+ "typescript": "^6.0.3",
46
+ "vite": "^8.0.9",
47
+ "vitest": "^4.1.5",
48
+ "@object-ui/app-shell": "3.3.1",
49
+ "@object-ui/auth": "3.3.1",
50
+ "@object-ui/collaboration": "3.3.1",
51
+ "@object-ui/components": "3.3.1",
52
+ "@object-ui/core": "3.3.1",
53
+ "@object-ui/data-objectstack": "3.3.1",
54
+ "@object-ui/fields": "3.3.1",
55
+ "@object-ui/i18n": "3.3.1",
56
+ "@object-ui/layout": "3.3.1",
57
+ "@object-ui/mobile": "3.3.1",
58
+ "@object-ui/permissions": "3.3.1",
59
+ "@object-ui/plugin-calendar": "3.3.1",
60
+ "@object-ui/plugin-charts": "3.3.1",
61
+ "@object-ui/plugin-chatbot": "3.3.1",
62
+ "@object-ui/plugin-dashboard": "3.3.1",
63
+ "@object-ui/plugin-designer": "3.3.1",
64
+ "@object-ui/plugin-detail": "3.3.1",
65
+ "@object-ui/plugin-form": "3.3.1",
66
+ "@object-ui/plugin-gantt": "3.3.1",
67
+ "@object-ui/plugin-grid": "3.3.1",
68
+ "@object-ui/plugin-kanban": "3.3.1",
69
+ "@object-ui/plugin-list": "3.3.1",
70
+ "@object-ui/plugin-map": "3.3.1",
71
+ "@object-ui/plugin-markdown": "3.3.1",
72
+ "@object-ui/plugin-report": "3.3.1",
73
+ "@object-ui/plugin-timeline": "3.3.1",
74
+ "@object-ui/plugin-view": "3.3.1",
75
+ "@object-ui/react": "3.3.1",
76
+ "@object-ui/types": "3.3.1"
89
77
  },
90
78
  "scripts": {
91
- "msw:init": "msw init -y public",
92
- "dev": "pnpm msw:init && vite",
93
- "start": "tsx ../../node_modules/@objectstack/cli/bin/objectstack.js serve objectstack.config.ts",
94
- "start:mock": "pnpm msw:init && vite preview",
79
+ "dev": "vite",
95
80
  "build:plugin": "tsc -p tsconfig.plugin.json",
96
- "build": "pnpm msw:init && tsc && VITE_USE_MOCK_SERVER=false vite build && pnpm build:plugin",
97
- "build:vercel": "pnpm msw:init && tsc && VITE_USE_MOCK_SERVER=true vite build && pnpm build:plugin",
81
+ "build": "tsc && vite build && pnpm build:plugin",
98
82
  "build:analyze": "pnpm build && echo 'Bundle analysis available at dist/stats.html'",
99
83
  "preview": "vite preview",
100
84
  "test": "vitest run",
package/plugin.js CHANGED
@@ -20,8 +20,8 @@
20
20
  *
21
21
  * @see https://github.com/objectstack-ai/objectui
22
22
  */
23
- import { fileURLToPath } from 'url';
24
- import { dirname, resolve } from 'path';
23
+ import { fileURLToPath } from 'node:url';
24
+ import { dirname, resolve } from 'node:path';
25
25
  const __filename = fileURLToPath(import.meta.url);
26
26
  const __dirname = dirname(__filename);
27
27
  /** Absolute path to the built SPA assets (dist/) */
package/plugin.ts CHANGED
@@ -21,8 +21,8 @@
21
21
  * @see https://github.com/objectstack-ai/objectui
22
22
  */
23
23
 
24
- import { fileURLToPath } from 'url';
25
- import { dirname, resolve } from 'path';
24
+ import { fileURLToPath } from 'node:url';
25
+ import { dirname, resolve } from 'node:path';
26
26
 
27
27
  const __filename = fileURLToPath(import.meta.url);
28
28
  const __dirname = dirname(__filename);
@@ -1 +0,0 @@
1
- import"./framework-DJlDX9E6.js";import{E as e}from"./plugins-core-PiAAytWV.js";import"./infrastructure-C6Ph6Ug0.js";export{e as AddressField};