UNPKG

@antv/g2

Version:

the Grammar of Graphics in Javascript

21 lines 562 B
import { deepMix } from '@antv/util'; import { inferredColumn, constant } from './utils/helper'; /** * Add zero constant encode for y1 channel. */ export const MaybeZeroY1 = () => { return (I, mark) => { const { encode } = mark; const { y1 } = encode; if (y1 !== undefined) return [I, mark]; return [ I, deepMix({}, mark, { encode: { y1: inferredColumn(constant(I, 0)) }, }), ]; }; }; MaybeZeroY1.props = {}; //# sourceMappingURL=maybeZeroY1.js.map