@lionad/cx-comps-tanstack-charts 0.1.0-alpha.17 → 0.1.0-alpha.18
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.mjs
CHANGED
|
@@ -23,7 +23,7 @@ import { treeLayout } from "@tanstack/charts/hierarchy/tree";
|
|
|
23
23
|
import { treemap } from "@tanstack/charts/hierarchy/treemap";
|
|
24
24
|
import { forceLayout } from "@tanstack/charts/network/force";
|
|
25
25
|
import { sankeyDiagram } from "@tanstack/charts/network/sankey";
|
|
26
|
-
import { geoAlbersUsa, geoEqualEarth, geoIdentity, geoMercator, geoNaturalEarth1, geoOrthographic } from "d3-geo";
|
|
26
|
+
import { geoAlbersUsa, geoEqualEarth, geoEquirectangular, geoIdentity, geoMercator, geoNaturalEarth1, geoOrthographic } from "d3-geo";
|
|
27
27
|
import { decorative } from "@tanstack/charts/mark/decorative";
|
|
28
28
|
import { tooltip } from "@tanstack/charts/tooltip";
|
|
29
29
|
import { viewGrid } from "@tanstack/charts/view";
|
|
@@ -1097,13 +1097,16 @@ function translateForceGraph(spec, datasets) {
|
|
|
1097
1097
|
yDomain: [graph.yDomain[0], graph.yDomain[1]]
|
|
1098
1098
|
};
|
|
1099
1099
|
}
|
|
1100
|
-
/** d3-geo 投影名称枚举 → 工厂(descriptor.type 形态:() => projection
|
|
1100
|
+
/** d3-geo 投影名称枚举 → 工厂(descriptor.type 形态:() => projection);
|
|
1101
|
+
* 等距圆柱必须用 equirectangular 而非 identity:identity 的 stream 无 sphere 方法,
|
|
1102
|
+
* fit/渲染 Sphere 几何(球面描边层)直接抛 TypeError */
|
|
1101
1103
|
const GEO_PROJECTION_FACTORIES = {
|
|
1102
1104
|
mercator: geoMercator,
|
|
1103
1105
|
orthographic: geoOrthographic,
|
|
1104
1106
|
naturalEarth1: geoNaturalEarth1,
|
|
1105
1107
|
albersUsa: geoAlbersUsa,
|
|
1106
1108
|
equalEarth: geoEqualEarth,
|
|
1109
|
+
equirectangular: geoEquirectangular,
|
|
1107
1110
|
identity: geoIdentity
|
|
1108
1111
|
};
|
|
1109
1112
|
/** geoShape:projection 名称枚举 → descriptor {type, fit, inset};fit:'data' 由库拟合数据本体,{data:'<name>'} 拟合另一命名数据集 */
|
|
@@ -234,8 +234,8 @@ export interface CxChartMarkSpec {
|
|
|
234
234
|
labelFontWeight?: number;
|
|
235
235
|
orientation?: 'left' | 'right' | 'top' | 'bottom';
|
|
236
236
|
nodeSize?: [number, number];
|
|
237
|
-
projection?: 'mercator' | 'orthographic' | 'naturalEarth1' | 'albersUsa' | 'equalEarth' | 'identity' | {
|
|
238
|
-
$by: Record<string, 'mercator' | 'orthographic' | 'naturalEarth1' | 'albersUsa' | 'equalEarth' | 'identity'>;
|
|
237
|
+
projection?: 'mercator' | 'orthographic' | 'naturalEarth1' | 'albersUsa' | 'equalEarth' | 'equirectangular' | 'identity' | {
|
|
238
|
+
$by: Record<string, 'mercator' | 'orthographic' | 'naturalEarth1' | 'albersUsa' | 'equalEarth' | 'equirectangular' | 'identity'>;
|
|
239
239
|
};
|
|
240
240
|
fit?: 'data' | 'sphere' | {
|
|
241
241
|
data: string;
|