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

Function Em

resources/vega-lite.min.js:11630–11736  ·  view source on GitHub ↗
(e, t, n, i)

Source from the content-addressed store, hash-verified

11628 }
11629 }
11630 function Em(e, t, n, i) {
11631 const r = (function (e, t, n, i) {
11632 switch (t.type) {
11633 case "nominal":
11634 case "ordinal":
11635 if (We(e) || "discrete" === tn(e))
11636 return (
11637 "shape" === e && "ordinal" === t.type && Si(fi(e, "ordinal")),
11638 "ordinal"
11639 );
11640 if (Mt(e)) return "band";
11641 if (_t(e) || jt(e)) {
11642 if (p(["rect", "bar", "image", "rule", "tick"], n.type))
11643 return "band";
11644 if (i) return "band";
11645 } else if ("arc" === n.type && e in Pt) return "band";
11646 return lo(n[st(e)]) || (ca(t) && t.axis?.tickBand)
11647 ? "band"
11648 : "point";
11649 case "temporal":
11650 return We(e)
11651 ? "time"
11652 : "discrete" === tn(e)
11653 ? (Si(fi(e, "temporal")), "ordinal")
11654 : Zo(t) && t.timeUnit && Ii(t.timeUnit).utc
11655 ? "utc"
11656 : Mt(e)
11657 ? "band"
11658 : "time";
11659 case "quantitative":
11660 return We(e)
11661 ? Zo(t) && mn(t.bin)
11662 ? "bin-ordinal"
11663 : "linear"
11664 : "discrete" === tn(e)
11665 ? (Si(fi(e, "quantitative")), "ordinal")
11666 : Mt(e)
11667 ? "band"
11668 : "linear";
11669 case "geojson":
11670 return;
11671 }
11672 throw new Error(oi(t.type));
11673 })(
11674 t,
11675 n,
11676 i,
11677 arguments.length > 4 && void 0 !== arguments[4] && arguments[4],
11678 ),
11679 { type: o } = e;
11680 return Qt(t)
11681 ? void 0 !== o
11682 ? (function (e, t) {
11683 let n =
11684 arguments.length > 2 && void 0 !== arguments[2] && arguments[2];
11685 if (!Qt(e)) return !1;
11686 switch (e) {
11687 case te:

Callers 1

MmFunction · 0.70

Calls 15

WeFunction · 0.85
caFunction · 0.85
ZoFunction · 0.85
oiFunction · 0.85
krFunction · 0.85
tnFunction · 0.70
SiFunction · 0.70
fiFunction · 0.70
MtFunction · 0.70
_tFunction · 0.70
jtFunction · 0.70
pFunction · 0.70

Tested by

no test coverage detected