import{dq as y,p as l,dr as m,h as u,az as g,c8 as d,bt as f,U as b}from"./index-Cc-6WbPt.js";import{c}from"./complement-BOrTcrWV.js";const o=y({String:"string",Integer:"integer",Float:"number",Boolean:"boolean","Array of Float":"arraynumber","Array of Integer":"arrayinteger","Array of String":"arraystring","Array of Boolean":"arrayboolean"}),B=a=>a.reduce((e,{name:r,description:t,required:p,type:i})=>{if(r==="")return e;const s=i[0];if(s.includes("Array")){const n=s.slice(s.lastIndexOf(" ")+1);e.properties[r]={description:t,type:"array",items:{type:o.getByKey(n)}}}else e.properties[r]={type:o.getByKey(s),...t?{description:t}:{description:""}};return p&&e.required.push(r),e},{properties:{},required:[]}),j=a=>Object.entries(a.properties).map(([e,{description:r,type:t,items:p}])=>({name:e,type:[o.getByValue(t+(p?p.type:""))],required:a.required.includes(e),description:r??""})),x=l(b("properties"),f,g(d(["type","description","items"])),m(c(u)));export{B as a,x as j,j as m,o as p};
