import{i as e}from"./preload-helper-B45gAKPr.js";import{t}from"./iframe-CMLjY6eW.js";import{n,t as r}from"./Select-DMXjzkDO.js";function i(e,t){return e[t]}function a(e,t,n){let r=e[t];if(typeof r==`string`||typeof r==`number`)return r;let a=i(e,n);return typeof a==`string`||typeof a==`number`?a:String(a)}function o({label:e,description:t,disabled:n,placeholder:o,size:c,options:l,value:u,onChange:d,optionKey:f,optionLabel:p,renderCode:m,className:h,clearable:g}){return(0,s.jsx)(r,{label:e,description:t,disabled:n,placeholder:o,size:c,options:l,value:u===void 0?void 0:l.find(e=>i(e,f)===u),onChange:e=>d(e?i(e,f):void 0),getOptionKey:e=>i(e,f),getOptionLabel:e=>a(e,p,f),getOptionCode:m?e=>i(e,f):void 0,className:h,clearable:g})}var s,c=e((()=>{n(),s=t(),o.__docgenInfo={description:``,methods:[],displayName:`SerializableSelect`,props:{options:{required:!0,tsType:{name:`unknown`},description:``},onChange:{required:!0,tsType:{name:`signature`,type:`function`,raw:`(value: SerializableOptionValue<TOption, TOptionKey> | undefined) => void`,signature:{arguments:[{type:{name:`union`,raw:`SerializableOptionValue<TOption, TOptionKey> | undefined`,elements:[{name:`Extract`,elements:[{name:`TOption[TOptionKey]`,raw:`TOption[TOptionKey]`},{name:`union`,raw:`string | number`,elements:[{name:`string`},{name:`number`}]}],raw:`Extract<
	TOption[TOptionKey],
	SelectOptionKey
>`},{name:`undefined`}]},name:`value`}],return:{name:`void`}}},description:``},optionKey:{required:!0,tsType:{name:`TOptionKey`},description:``},optionLabel:{required:!0,tsType:{name:`TOptionLabel`},description:``},renderCode:{required:!1,tsType:{name:`literal`,value:`true`},description:``},className:{required:!1,tsType:{name:`string`},description:``},clearable:{required:!1,tsType:{name:`boolean`},description:``}},composes:[`Omit`]}}));export{c as n,o as t};