ll-package
Version:
2 lines (1 loc) • 993 B
JavaScript
Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const v=(n,e,t,b,x)=>{const o=n/2,c=0,r=o,$=t*1/Math.sqrt(2),a=o-t*(1-1/Math.sqrt(2)),h=o-e*(1/Math.sqrt(2)),l=t*(Math.sqrt(2)-1)+e*(1/Math.sqrt(2)),g=2*o-h,y=l,M=2*o-$,f=a,q=2*o-c,m=r,p=o*Math.sqrt(2)+t*(Math.sqrt(2)-2),s=t*(Math.sqrt(2)-1);return{pointerEvents:"none",width:n,height:n,overflow:"hidden","&::after":{content:'""',position:"absolute",width:p,height:p,bottom:0,insetInline:0,margin:"auto",borderRadius:{_skip_check_:!0,value:`0 0 ${e}px 0`},transform:"translateY(50%) rotate(-135deg)",boxShadow:x,zIndex:0,background:"transparent"},"&::before":{position:"absolute",bottom:0,insetInlineStart:0,width:n,height:n/2,background:b,clipPath:{_multi_value_:!0,value:[`polygon(${s}px 100%, 50% ${s}px, ${2*o-s}px 100%, ${s}px 100%)`,`path('M ${c} ${r} A ${t} ${t} 0 0 0 ${$} ${a} L ${h} ${l} A ${e} ${e} 0 0 1 ${g} ${y} L ${M} ${f} A ${t} ${t} 0 0 0 ${q} ${m} Z')`]},content:'""'}}};exports.roundedArrow=v;
;