drill.define(()=>{const e=e=>{let t=/[\d\.]+(.+)/.exec(e);return t?t[1]:""},t=(t,a)=>{let r=parseFloat(t.parent.parent.w),n=parseFloat(t.parent.parent.h),l={vw:r/100,vh:n/100,percentW:r/100,percentH:n/100};if(void 0===a){a=0;let{w:r}=t;switch(e(r)){case"bw":throw"can't use bw in box width";case"px":a=parseFloat(r);break;case"%":a=parseFloat(r)*l.percentW;break;case"vw":a=parseFloat(r)*l.vw;break;case"vh":a=parseFloat(r)*l.vh}}return l.bw=a/100,l};return{refreshText:(a,r={})=>{let{unitObj:n,tarWidth:l}=r;n||(n=t(a,l)),"pre-text"==a.tag&&["fontSize","lineHeight","letterSpacing"].forEach(t=>{let r=a[t],l=e(r);n[l]&&(r=parseFloat(r)*n[l],r+="px"),a.$xvTextCon.style[t]=r,a.$textInpueEle.style[t]=r})},getUnit:e,getUnitPx:t}});