diff --git a/.gitignore b/.gitignore
index 60a4aff1..624876e9 100644
--- a/.gitignore
+++ b/.gitignore
@@ -4,3 +4,4 @@ dist
dist-ssr
*.local
.vscode
+.idea
diff --git a/package.json b/package.json
index 8895b4e3..bbcf6e73 100644
--- a/package.json
+++ b/package.json
@@ -41,7 +41,7 @@
"three": "^0.145.0",
"vue": "^3.2.31",
"vue-demi": "^0.13.1",
- "vue-i18n": "^9.2.2",
+ "vue-i18n": "9.2.2",
"vue-router": "4.0.12",
"vue3-lazyload": "^0.2.5-beta",
"vue3-sketch-ruler": "^1.3.3",
diff --git a/src/packages/components/Charts/Maps/MapBase/config.ts b/src/packages/components/Charts/Maps/MapBase/config.ts
index dd020e50..d9844001 100644
--- a/src/packages/components/Charts/Maps/MapBase/config.ts
+++ b/src/packages/components/Charts/Maps/MapBase/config.ts
@@ -11,7 +11,10 @@ export const option = {
dataset: dataJson,
mapRegion: {
adcode: 'china',
- showHainanIsLands: true
+ showHainanIsLands: true,
+ enter: false,
+ backSize: 20,
+ backColor: '#ffffff'
},
tooltip: {
show: true,
@@ -103,19 +106,19 @@ export const option = {
borderColor: 'rgba(147, 235, 248, 0.8)',
textStyle: {
color: '#FFFFFF',
- fontSize: 12,
+ fontSize: 12
}
},
label: {
show: false,
color: '#FFFFFF',
- fontSize: 12,
+ fontSize: 12
},
emphasis: {
disabled: false,
label: {
color: '#FFFFFF',
- fontSize: 12,
+ fontSize: 12
},
itemStyle: {
areaColor: '#389BB7',
@@ -148,6 +151,26 @@ export const option = {
shadowOffsetY: 2,
shadowBlur: 10
}
+ },
+ {
+ type: 'lines',
+ zlevel: 2,
+ effect: {
+ show: true,
+ period: 4, //箭头指向速度,值越小速度越快
+ trailLength: 0.4, //特效尾迹长度[0,1]值越大,尾迹越长重
+ symbol: 'arrow', //箭头图标
+ symbolSize: 7 //图标大小
+ },
+ lineStyle: {
+ normal: {
+ color: '#4fb6d2',
+ width: 1, //线条宽度
+ opacity: 0.1, //尾迹线条透明度
+ curveness: 0.3 //尾迹线条曲直度
+ }
+ },
+ data: []
}
]
}
diff --git a/src/packages/components/Charts/Maps/MapBase/config.vue b/src/packages/components/Charts/Maps/MapBase/config.vue
index b3ef4961..e0363d8f 100644
--- a/src/packages/components/Charts/Maps/MapBase/config.vue
+++ b/src/packages/components/Charts/Maps/MapBase/config.vue
@@ -69,11 +69,7 @@
-
+
-
+
@@ -180,6 +176,22 @@
显示南海群岛
+
+ 点击进入下级
+
+
+
+
+
+
+
+
+
@@ -191,7 +203,7 @@
-
+
@@ -223,6 +235,47 @@
+
+
+
+
+
+
+
+
+ 值越小速度越快
+
+
+
+
+
+
+
+ 特效尾迹长度[0,1]值越大,尾迹越长重
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/packages/components/Charts/Mores/Graph/config.ts b/src/packages/components/Charts/Mores/Graph/config.ts
index 0dfb0dc8..125d7469 100644
--- a/src/packages/components/Charts/Mores/Graph/config.ts
+++ b/src/packages/components/Charts/Mores/Graph/config.ts
@@ -9,7 +9,8 @@ export const includes = []
// 关系图布局
export const GraphLayout = [
{ label: '无', value: 'none' },
- { label: '环形', value: 'circular' }
+ { label: '环形', value: 'circular' },
+ { label: '力引导', value: 'force' }
]
// 标签开关
@@ -24,44 +25,57 @@ export const LabelPosition = [
{ label: '右侧', value: 'right' },
{ label: '顶部', value: 'top' },
{ label: '底部', value: 'bottom' },
- { label: '内部', value: 'inside' },
+ { label: '内部', value: 'inside' }
+]
+
+// 图-迭代动画
+export const LayoutAnimation = [
+ { label: '开启', value: 1 },
+ { label: '关闭', value: 0 }
]
export const option = {
- dataset: { ...dataJson },
- tooltip: {},
- legend:{
- show:true,
- textStyle:{
- color:"#eee",
- fontSize: 14 ,
- },
- data: dataJson.categories.map(function (a) {
- return a.name;
- })
+ dataset: { ...dataJson },
+ tooltip: {},
+ legend: {
+ show: true,
+ textStyle: {
+ color: '#eee',
+ fontSize: 14
},
- series: [
- {
- type: 'graph',
- layout: 'none', // none circular环形布局
- data: dataJson.nodes,
- links: dataJson.links,
- categories: dataJson.categories,
- label: { // 标签
- show: 1,
- position: 'right',
- formatter: '{b}'
- },
- labelLayout: {
- hideOverlap: true
- },
- lineStyle: {
- color: 'source', // 线条颜色
- curveness: 0.2 // 线条卷曲程度
- }
+ data: dataJson.categories.map(function (a) {
+ return a.name
+ })
+ },
+ series: [
+ {
+ type: 'graph',
+ layout: 'none', // none circular环形布局
+ data: dataJson.nodes,
+ links: dataJson.links,
+ categories: dataJson.categories,
+ label: {
+ show: 1,
+ position: 'right',
+ formatter: '{b}'
+ },
+ labelLayout: {
+ hideOverlap: true
+ },
+ lineStyle: {
+ color: 'source', // 线条颜色
+ curveness: 0.2 // 线条卷曲程度
+ },
+ force: {
+ repulsion: 100,
+ gravity: 0.1,
+ edgeLength: 30,
+ layoutAnimation: 1,
+ friction: 0.6
}
- ]
- };
+ }
+ ]
+}
export default class Config extends PublicConfigClass implements CreateComponentType {
public key = GraphConfig.key
diff --git a/src/packages/components/Charts/Mores/Graph/config.vue b/src/packages/components/Charts/Mores/Graph/config.vue
index 07319fde..65e6e38d 100644
--- a/src/packages/components/Charts/Mores/Graph/config.vue
+++ b/src/packages/components/Charts/Mores/Graph/config.vue
@@ -16,14 +16,14 @@
-
+
+ v-model:value="optionData.series[0].lineStyle.curveness"
+ :min="0"
+ :step="0.01"
+ placeholder="弯曲程度"
+ size="small"
+ >
@@ -32,10 +32,61 @@
size="small"
:modes="['hex']"
v-model:value="optionData.legend.textStyle.color"
- >
+ >
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -46,7 +97,7 @@
diff --git a/src/packages/components/Charts/Mores/Graph/index.vue b/src/packages/components/Charts/Mores/Graph/index.vue
index 40c2b0e1..378c968e 100644
--- a/src/packages/components/Charts/Mores/Graph/index.vue
+++ b/src/packages/components/Charts/Mores/Graph/index.vue
@@ -1,5 +1,12 @@
-
+