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

Function Jp

resources/vega.min.js:11601–11623  ·  view source on GitHub ↗
(t, e, n)

Source from the content-addressed store, hash-verified

11599 return t && t.gradient;
11600 }
11601 function Jp(t, e, n) {
11602 const r = t.gradient;
11603 let i = t.id,
11604 o = "radial" === r ? Vp : "";
11605 return (
11606 i ||
11607 ((i = t.id = "gradient_" + Gp++),
11608 "radial" === r
11609 ? ((t.x1 = Zp(t.x1, 0.5)),
11610 (t.y1 = Zp(t.y1, 0.5)),
11611 (t.r1 = Zp(t.r1, 0)),
11612 (t.x2 = Zp(t.x2, 0.5)),
11613 (t.y2 = Zp(t.y2, 0.5)),
11614 (t.r2 = Zp(t.r2, 0.5)),
11615 (o = Vp))
11616 : ((t.x1 = Zp(t.x1, 0)),
11617 (t.y1 = Zp(t.y1, 0)),
11618 (t.x2 = Zp(t.x2, 1)),
11619 (t.y2 = Zp(t.y2, 0)))),
11620 (e[i] = t),
11621 "url(" + (n || "") + "#" + o + i + ")"
11622 );
11623 }
11624 function Zp(t, e) {
11625 return null != t ? t : e;
11626 }

Callers 2

styleMethod · 0.85
attrMethod · 0.85

Calls 1

ZpFunction · 0.85

Tested by

no test coverage detected