"use strict";const x=require("vue"),H=require("class-variant"),N=require("@techor/extend"),S=require("clsx"),B=new Proxy((n,...r)=>Array.isArray(n)&&"raw"in n||typeof n!="object"||!("setup"in n)&&!("__v_isVNode"in n)?B.div(n,...r):j(n.tag??n,n.params),{get:function(n,r){return r in n||(n[r]=j(r,void 0)),n[r]}});function j(n,r){return(...w)=>{const A=(h,...p)=>{const u=[...r||[],[h,p]],d=x.defineComponent((O,{slots:g,attrs:b})=>()=>{var q;const k=[],P=[];let i;const v=[],C=Object.assign({},typeof n=="string"?{}:n.props,b),_=e=>{switch(typeof e){case"object":if(Array.isArray(e)){const t=e[1];if(t&&typeof t=="object"){const s=Object.keys(t);for(const f of P){const a=Object.entries(f[1]);if(a.length===s.length&&a.every(([l,V])=>s.includes(l)&&t[l]===V))return!0}P.push(e)}}else{const t=Object.keys(e);if(t.length)switch(typeof e[t[0]]){case"object":case"string":if(i){for(const s of t){const f=e[s];switch(typeof f){case"object":if(s in i){const a=i[s];for(const l in f)l in a||(a[l]=f[l])}else i[s]=f;break;case"string":s in i||(i[s]=f);break}}return!0}else i=e;break;case"boolean":for(const s of t)e[s]&&k.push(s);return!0}}break;case"function":const c=e(C);if(typeof c=="object"&&_(c))return!0;break}};for(let e=u.length-1;e>=0;e--){const c=u[e],t=[...c[1]];for(let s=0;s=0;e--){const c=v[e];k.push(H(c[0],...c[1])(C))}const T={};for(const e in b)e.startsWith("$")||(T[e]=b[e]);return x.h(n,{...O,...T,class:S(k,b.class)},(q=g.default)==null?void 0:q.call(g))});return d.params=u,d.tag=n,d.inheritAttrs=!1,d},o=w[0];let y=r||[];if(o.params&&(y=[...y,...o.params]),Array.isArray(o)&&"raw"in o)return A(o,...w.slice(1));if(typeof o=="object"&&"setup"in o)return j(n,y);if(typeof o=="object"&&"__v_isVNode"in o)return j(typeof n=="string"?o:N(n,o),y);{const h=[],p=[];for(const u of w)(typeof u=="string"?h:p).push(u);return A(h,...p)}}}module.exports=B;