import{Rt as e}from"./mermaid-7ea9cbd6-DmivzQ7-.js";import{n as t,t as n}from"./path-BKCho5uS.js";import{t as r}from"./array-Bda68fSV.js";function i(e){return e[0]}function a(e){return e[1]}function o(o,s){var c=t(!0),l=null,u=e,d=null,f=n(p);o=typeof o==`function`?o:o===void 0?i:t(o),s=typeof s==`function`?s:s===void 0?a:t(s);function p(e){var t,n=(e=r(e)).length,i,a=!1,p;for(l??(d=u(p=f())),t=0;t<=n;++t)!(t<n&&c(i=e[t],t,e))===a&&((a=!a)?d.lineStart():d.lineEnd()),a&&d.point(+o(i,t,e),+s(i,t,e));if(p)return d=null,p+``||null}return p.x=function(e){return arguments.length?(o=typeof e==`function`?e:t(+e),p):o},p.y=function(e){return arguments.length?(s=typeof e==`function`?e:t(+e),p):s},p.defined=function(e){return arguments.length?(c=typeof e==`function`?e:t(!!e),p):c},p.curve=function(e){return arguments.length?(u=e,l!=null&&(d=u(l)),p):u},p.context=function(e){return arguments.length?(e==null?l=d=null:d=u(l=e),p):l},p}export{o as t};