UNPKG

@visactor/vmind

Version:

<div align="center"> <a href="https://github.com/VisActor#gh-light-mode-only" target="_blank"> <img alt="VisActor Logo" width="200" src="https://github.com/VisActor/.github/blob/main/profile/logo_500_200_light.svg"/> </a> <a href="https://githu

70 lines (62 loc) 1.89 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: !0 }), exports.pipelineRadar = exports.radarAxis = exports.radarDisplayConf = exports.radarField = void 0; const common_1 = require("./common"), radarField = context => { var _a, _b; const {cell: cell, spec: spec} = context; return (cell.x || cell.angle) && (spec.categoryField = null !== (_a = cell.x) && void 0 !== _a ? _a : cell.angle), (cell.y || cell.value) && (spec.valueField = null !== (_b = cell.y) && void 0 !== _b ? _b : cell.value), cell.color && (spec.seriesField = cell.color), !spec.categoryField && spec.seriesField && (spec.categoryField = spec.seriesField, delete spec.seriesField), { spec: spec }; }; exports.radarField = radarField; const radarDisplayConf = context => { const {spec: spec, chartTheme: chartTheme} = context; return chartTheme || (spec.area = { visible: !0 }), { spec: spec }; }; exports.radarDisplayConf = radarDisplayConf; const radarAxis = context => { const {spec: spec} = context; return spec.axes = [ { orient: "radius", zIndex: 100, domainLine: { visible: !1 }, label: { visible: !0, space: 0, style: {} }, grid: { smooth: !1, style: {} } }, { orient: "angle", zIndex: 50, tick: { visible: !1 }, domainLine: { visible: !1 }, label: { space: 20 }, grid: { style: {} } } ], { spec: spec }; }; exports.radarAxis = radarAxis, exports.pipelineRadar = [ common_1.data, common_1.color, exports.radarField, exports.radarDisplayConf, exports.radarAxis, common_1.discreteLegend ]; //# sourceMappingURL=radar.js.map