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

Function ho

resources/vega-lite.min.js:1775–1789  ·  view source on GitHub ↗
(e)

Source from the content-addressed store, hash-verified

1773 return void 0 !== s ? "show" : a;
1774 }
1775 function ho(e) {
1776 let { scaleName: t, scale: n, mode: i } = e;
1777 const r = `domain('${t}')`;
1778 if (!n || !t) return;
1779 const o = `${r}[0]`,
1780 a = `peek(${r})`,
1781 s = n.domainHasZero();
1782 if ("definitely" === s) return { scale: t, value: 0 };
1783 if ("maybe" === s) {
1784 return {
1785 signal: `scale('${t}', inrange(0, ${r}) ? 0 : ${"zeroOrMin" === i ? o : a})`,
1786 };
1787 }
1788 return { signal: `scale('${t}', ${"zeroOrMin" === i ? o : a})` };
1789 }
1790 function yo(e) {
1791 let {
1792 scaleChannel: t,

Callers 2

voFunction · 0.70
buFunction · 0.70

Calls 1

domainHasZeroMethod · 0.80

Tested by

no test coverage detected