MCPcopy Create free account
hub / github.com/alignoth/alignoth / formatSpan

Function formatSpan

resources/vega.min.js:2923–2944  ·  view source on GitHub ↗
(t, r, i, o)

Source from the content-addressed store, hash-verified

2921 var r, i;
2922 },
2923 formatSpan(t, r, i, o) {
2924 o = Oe(null == o ? ",f" : o);
2925 const a = xe(t, r, i),
2926 s = Math.max(Math.abs(t), Math.abs(r));
2927 let u;
2928 if (null == o.precision)
2929 switch (o.type) {
2930 case "s":
2931 return (isNaN((u = Ve(a, s))) || (o.precision = u), n(o, s));
2932 case "":
2933 case "e":
2934 case "g":
2935 case "p":
2936 case "r":
2937 isNaN((u = Xe(a, s))) || (o.precision = u - ("e" === o.type));
2938 break;
2939 case "f":
2940 case "%":
2941 isNaN((u = Ge(a))) || (o.precision = u - 2 * ("%" === o.type));
2942 }
2943 return e(o);
2944 },
2945 };
2946 }
2947 let Mo, Eo;

Callers

nothing calls this directly

Calls 7

VeFunction · 0.85
XeFunction · 0.85
GeFunction · 0.85
eFunction · 0.85
OeFunction · 0.70
xeFunction · 0.70
nFunction · 0.70

Tested by

no test coverage detected