@antv/gpt-vis 0.0.2 → 0.0.4
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/README.md +3 -3
- package/dist/cjs/Area/index.js +61 -0
- package/dist/cjs/ChartCodeRender/index.js +121 -0
- package/dist/cjs/ChartCodeRender/type.js +17 -0
- package/dist/cjs/Column/index.js +73 -0
- package/dist/cjs/GPTVis/index.js +56 -0
- package/dist/cjs/HeatMap/index.js +90 -0
- package/dist/cjs/Line/index.js +62 -0
- package/dist/cjs/PathMap/index.js +150 -0
- package/dist/cjs/Pie/index.js +72 -0
- package/dist/cjs/PinMap/index.js +125 -0
- package/dist/cjs/WordCloud/index.js +57 -0
- package/dist/cjs/constants/index.js +54 -0
- package/dist/{index.d.ts → cjs/index.d.ts} +2 -2
- package/dist/cjs/index.js +65 -0
- package/dist/cjs/types/index.js +39 -0
- package/dist/esm/Area/index.d.ts +5 -0
- package/dist/esm/ChartCodeRender/index.css +19 -0
- package/dist/esm/ChartCodeRender/index.d.ts +10 -0
- package/dist/{ChartCodeRender → esm/ChartCodeRender}/index.js +1 -1
- package/dist/esm/ChartCodeRender/type.d.ts +55 -0
- package/dist/esm/Column/index.d.ts +5 -0
- package/dist/esm/GPTVis/index.d.ts +10 -0
- package/dist/esm/HeatMap/index.d.ts +12 -0
- package/dist/esm/Line/index.d.ts +5 -0
- package/dist/esm/PathMap/index.d.ts +12 -0
- package/dist/esm/Pie/index.d.ts +19 -0
- package/dist/esm/Pie/index.text.d.ts +0 -0
- package/dist/esm/Pie/index.text.js +0 -0
- package/dist/esm/PinMap/index.d.ts +12 -0
- package/dist/esm/PinMap/maker.svg +1 -0
- package/dist/esm/WordCloud/index.d.ts +11 -0
- package/dist/esm/constants/index.d.ts +2 -0
- package/dist/esm/index.d.ts +13 -0
- package/dist/{index.js → esm/index.js} +4 -3
- package/dist/esm/types/index.d.ts +26 -0
- package/package.json +7 -7
- package/dist/Message/index.d.ts +0 -18
- package/dist/Message/index.js +0 -14
- /package/dist/{Area → cjs/Area}/index.d.ts +0 -0
- /package/dist/{ChartCodeRender → cjs/ChartCodeRender}/index.css +0 -0
- /package/dist/{ChartCodeRender → cjs/ChartCodeRender}/index.d.ts +0 -0
- /package/dist/{ChartCodeRender → cjs/ChartCodeRender}/type.d.ts +0 -0
- /package/dist/{Column → cjs/Column}/index.d.ts +0 -0
- /package/dist/{GPTVis → cjs/GPTVis}/index.d.ts +0 -0
- /package/dist/{HeatMap → cjs/HeatMap}/index.d.ts +0 -0
- /package/dist/{Line → cjs/Line}/index.d.ts +0 -0
- /package/dist/{PathMap → cjs/PathMap}/index.d.ts +0 -0
- /package/dist/{Pie → cjs/Pie}/index.d.ts +0 -0
- /package/dist/{Pie → cjs/Pie}/index.text.d.ts +0 -0
- /package/dist/{Pie → cjs/Pie}/index.text.js +0 -0
- /package/dist/{PinMap → cjs/PinMap}/index.d.ts +0 -0
- /package/dist/{PinMap → cjs/PinMap}/maker.svg +0 -0
- /package/dist/{WordCloud → cjs/WordCloud}/index.d.ts +0 -0
- /package/dist/{constants → cjs/constants}/index.d.ts +0 -0
- /package/dist/{types → cjs/types}/index.d.ts +0 -0
- /package/dist/{Area → esm/Area}/index.js +0 -0
- /package/dist/{ChartCodeRender → esm/ChartCodeRender}/type.js +0 -0
- /package/dist/{Column → esm/Column}/index.js +0 -0
- /package/dist/{GPTVis → esm/GPTVis}/index.js +0 -0
- /package/dist/{HeatMap → esm/HeatMap}/index.js +0 -0
- /package/dist/{Line → esm/Line}/index.js +0 -0
- /package/dist/{PathMap → esm/PathMap}/index.js +0 -0
- /package/dist/{Pie → esm/Pie}/index.js +0 -0
- /package/dist/{PinMap → esm/PinMap}/index.js +0 -0
- /package/dist/{WordCloud → esm/WordCloud}/index.js +0 -0
- /package/dist/{constants → esm/constants}/index.js +0 -0
- /package/dist/{types → esm/types}/index.js +0 -0
|
@@ -3,9 +3,10 @@ export { default as Column } from "./Column";
|
|
|
3
3
|
export { default as Line } from "./Line";
|
|
4
4
|
export { default as Pie } from "./Pie";
|
|
5
5
|
export { default as WordCloud } from "./WordCloud";
|
|
6
|
-
|
|
7
|
-
// export { default as
|
|
8
|
-
// export { default as
|
|
6
|
+
|
|
7
|
+
// export { default as HeatMap, type HeatMapProps } from './HeatMap';
|
|
8
|
+
// export { default as PathMap, type PathMapProps } from './PathMap';
|
|
9
|
+
// export { default as PinMap, type PinMapProps } from './PinMap';
|
|
9
10
|
|
|
10
11
|
export { withChartCode, withDefaultChartCode } from "./ChartCodeRender";
|
|
11
12
|
export { default as GPTVis } from "./GPTVis";
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { type CSSProperties } from 'react';
|
|
2
|
+
export declare enum ChartType {
|
|
3
|
+
Pie = "pie",
|
|
4
|
+
Column = "column",
|
|
5
|
+
Line = "line",
|
|
6
|
+
Area = "area",
|
|
7
|
+
WordCloud = "word-cloud",
|
|
8
|
+
PinMap = "pin-map",
|
|
9
|
+
PathMap = "path-map",
|
|
10
|
+
HeatMap = "heat-map"
|
|
11
|
+
}
|
|
12
|
+
export interface BaseChartProps<T> {
|
|
13
|
+
data: T[];
|
|
14
|
+
style?: CSSProperties;
|
|
15
|
+
className?: string;
|
|
16
|
+
}
|
|
17
|
+
export interface XYAxis {
|
|
18
|
+
x: string | number;
|
|
19
|
+
y: number;
|
|
20
|
+
[key: string]: string | number;
|
|
21
|
+
}
|
|
22
|
+
export interface StackableChartProps extends BaseChartProps<XYAxis> {
|
|
23
|
+
xField?: string;
|
|
24
|
+
yField?: string;
|
|
25
|
+
stackField?: string;
|
|
26
|
+
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@antv/gpt-vis",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.4",
|
|
4
4
|
"description": "A chart library for LLM Agent",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -8,10 +8,11 @@
|
|
|
8
8
|
},
|
|
9
9
|
"author": "antvis",
|
|
10
10
|
"sideEffects": [
|
|
11
|
-
"**/*.
|
|
11
|
+
"**/*.css"
|
|
12
12
|
],
|
|
13
|
-
"
|
|
14
|
-
"
|
|
13
|
+
"main": "dist/cjs/index.js",
|
|
14
|
+
"module": "dist/esm/index.js",
|
|
15
|
+
"typings": "dist/esm/index.d.ts",
|
|
15
16
|
"files": [
|
|
16
17
|
"dist",
|
|
17
18
|
"README.md"
|
|
@@ -19,7 +20,7 @@
|
|
|
19
20
|
"scripts": {
|
|
20
21
|
"build": "bigfish-lib build",
|
|
21
22
|
"build:watch": "bigfish-lib build -w",
|
|
22
|
-
"ci": "tnpm run lint
|
|
23
|
+
"ci": "tnpm run lint",
|
|
23
24
|
"cov": "jest --coverage",
|
|
24
25
|
"create": "bigfish-lib create",
|
|
25
26
|
"deploy": "bigfish-lib deploy",
|
|
@@ -58,7 +59,7 @@
|
|
|
58
59
|
"@antv/l7": "^2.22.0",
|
|
59
60
|
"@antv/larkmap": "^1.4.17",
|
|
60
61
|
"@babel/runtime": "^7.18.0",
|
|
61
|
-
"lodash
|
|
62
|
+
"lodash": "^4.17.21",
|
|
62
63
|
"react-markdown": "^9.0.1",
|
|
63
64
|
"rehype-raw": "^7.0.0",
|
|
64
65
|
"styled-components": "^6.0.7"
|
|
@@ -72,7 +73,6 @@
|
|
|
72
73
|
"@testing-library/jest-dom": "^5.1.1",
|
|
73
74
|
"@testing-library/react": "^15.0.0",
|
|
74
75
|
"@types/jest": "^29.4.0",
|
|
75
|
-
"@types/lodash-es": "^4.17.12",
|
|
76
76
|
"@types/react": "^18.0.0",
|
|
77
77
|
"antd": "^5.0.0",
|
|
78
78
|
"husky": "^8.0.0",
|
package/dist/Message/index.d.ts
DELETED
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { Options } from 'react-markdown';
|
|
3
|
-
export type MessageProps = {
|
|
4
|
-
/**
|
|
5
|
-
* 需要被渲染的 markdown 字符串
|
|
6
|
-
*/
|
|
7
|
-
children: string;
|
|
8
|
-
/**
|
|
9
|
-
* 注册的组件
|
|
10
|
-
*/
|
|
11
|
-
components?: Options['components'];
|
|
12
|
-
/**
|
|
13
|
-
* 注册的 rehype 插件
|
|
14
|
-
*/
|
|
15
|
-
rehypePlugins?: Options['rehypePlugins'];
|
|
16
|
-
};
|
|
17
|
-
declare const Message: React.FC<MessageProps>;
|
|
18
|
-
export default Message;
|
package/dist/Message/index.js
DELETED
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import _toConsumableArray from "@babel/runtime/helpers/esm/toConsumableArray";
|
|
2
|
-
import React from 'react';
|
|
3
|
-
import Markdown from 'react-markdown';
|
|
4
|
-
import rehypeRaw from 'rehype-raw';
|
|
5
|
-
var Message = function Message(_ref) {
|
|
6
|
-
var children = _ref.children,
|
|
7
|
-
components = _ref.components,
|
|
8
|
-
rehypePlugins = _ref.rehypePlugins;
|
|
9
|
-
return /*#__PURE__*/React.createElement(Markdown, {
|
|
10
|
-
components: components,
|
|
11
|
-
rehypePlugins: [rehypeRaw].concat(_toConsumableArray(rehypePlugins || []))
|
|
12
|
-
}, children);
|
|
13
|
-
};
|
|
14
|
-
export default Message;
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|