import{defaultConfig as e}from"../../theme/internal.mjs";import{computed as t}from"vue";function n(n,r){let i=t(()=>n?.value||{}),a=t(()=>i.value.inherit===!1||!r?.value?e:r.value);return t(()=>{if(!n?.value)return r?.value;let e={...a.value.components};return Object.keys(n.value.components||{}).forEach(t=>{e[t]={...e[t],...n.value.components[t]}}),{...a.value,...i.value,token:{...a.value.token,...i.value.token},components:e}})}export{n as default};