@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
50 lines (45 loc) • 1.33 kB
JavaScript
import { arrayData, color } from "./common";
export const basemap = context => {
const {basemapOption: basemapOption, spec: spec} = context;
return basemapOption.regionProjectType ? spec.region = [ {
roam: !0,
projection: {
type: basemapOption.regionProjectType
},
coordinate: basemapOption.regionCoordinate
} ] : spec.region = [ {
roam: !0,
coordinate: basemapOption.regionCoordinate
} ], spec.map = "map", {
spec: spec
};
};
export const mapField = context => {
const {spec: spec, cell: cell} = context;
return spec.nameField = cell.color, spec.valueField = cell.size, spec.nameProperty = cell.color,
{
spec: spec
};
};
export const mapDisplayConf = context => {
const {spec: spec, cell: cell} = context;
return spec.legends = [ {
visible: !0,
type: "color",
field: cell.size,
orient: "bottom",
position: "start"
} ], spec.area = {
style: {
fill: {
field: cell.size,
scale: "color",
changeDomain: "replace"
}
}
}, {
spec: spec
};
};
export const pipelineMapChart = [ basemap, color, arrayData, mapField, mapDisplayConf ];
//# sourceMappingURL=map.js.map