From 0c0d606ae536807e2ce795a0ddf905c732c8490e Mon Sep 17 00:00:00 2001 From: "Ma.Jinkai" Date: Tue, 22 Oct 2024 12:32:37 +0800 Subject: [PATCH] feat(projects): add antv g6 example --- package.json | 2 + pnpm-lock.yaml | 589 +++++++++++++++++- src/locales/langs/en-us.ts | 1 + src/locales/langs/zh-cn.ts | 1 + src/router/elegant/imports.ts | 1 + src/router/elegant/routes.ts | 10 + src/router/elegant/transform.ts | 1 + src/typings/components.d.ts | 9 + src/typings/elegant-router.d.ts | 2 + src/views/plugin/charts/antv/data.ts | 60 ++ src/views/plugin/charts/antv/index.vue | 59 ++ .../plugin/charts/antv/modules/antv-flow.vue | 134 ++++ .../charts/antv/modules/antv-g6-flow.ts | 169 +++++ .../plugin/charts/antv/modules/status.ts | 99 +++ 14 files changed, 1105 insertions(+), 32 deletions(-) create mode 100644 src/views/plugin/charts/antv/data.ts create mode 100644 src/views/plugin/charts/antv/index.vue create mode 100644 src/views/plugin/charts/antv/modules/antv-flow.vue create mode 100644 src/views/plugin/charts/antv/modules/antv-g6-flow.ts create mode 100644 src/views/plugin/charts/antv/modules/status.ts diff --git a/package.json b/package.json index 907b26e8..2d6da473 100644 --- a/package.json +++ b/package.json @@ -49,6 +49,7 @@ "dependencies": { "@antv/data-set": "0.11.8", "@antv/g2": "5.2.5", + "@antv/g6": "^5.0.26", "@better-scroll/core": "2.5.1", "@iconify/vue": "4.1.2", "@sa/alova": "workspace:*", @@ -57,6 +58,7 @@ "@sa/hooks": "workspace:*", "@sa/materials": "workspace:*", "@sa/utils": "workspace:*", + "@vueuse/components": "^11.1.0", "@vueuse/core": "11.1.0", "clipboard": "2.0.11", "dayjs": "1.11.13", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index d8bfa5dc..cc97c170 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -14,6 +14,9 @@ importers: '@antv/g2': specifier: 5.2.5 version: 5.2.5 + '@antv/g6': + specifier: ^5.0.26 + version: 5.0.26(workerize-loader@2.0.2(webpack@5.95.0(esbuild@0.23.1))) '@better-scroll/core': specifier: 2.5.1 version: 2.5.1 @@ -21,7 +24,7 @@ importers: specifier: 4.1.2 version: 4.1.2(vue@3.5.11(typescript@5.6.3)) '@sa/alova': - specifier: workspace:^ + specifier: workspace:* version: link:packages/alova '@sa/axios': specifier: workspace:* @@ -38,6 +41,9 @@ importers: '@sa/utils': specifier: workspace:* version: link:packages/utils + '@vueuse/components': + specifier: ^11.1.0 + version: 11.1.0(vue@3.5.11(typescript@5.6.3)) '@vueuse/core': specifier: 11.1.0 version: 11.1.0(vue@3.5.11(typescript@5.6.3)) @@ -161,13 +167,13 @@ importers: version: 0.63.4 '@unocss/vite': specifier: 0.63.4 - version: 0.63.4(rollup@4.24.0)(vite@5.4.8(@types/node@22.7.5)(sass@1.79.4)) + version: 0.63.4(rollup@4.24.0)(vite@5.4.8(@types/node@22.7.5)(sass@1.79.4)(terser@5.36.0)) '@vitejs/plugin-vue': specifier: 5.1.4 - version: 5.1.4(vite@5.4.8(@types/node@22.7.5)(sass@1.79.4))(vue@3.5.11(typescript@5.6.3)) + version: 5.1.4(vite@5.4.8(@types/node@22.7.5)(sass@1.79.4)(terser@5.36.0))(vue@3.5.11(typescript@5.6.3)) '@vitejs/plugin-vue-jsx': specifier: 4.0.1 - version: 4.0.1(vite@5.4.8(@types/node@22.7.5)(sass@1.79.4))(vue@3.5.11(typescript@5.6.3)) + version: 4.0.1(vite@5.4.8(@types/node@22.7.5)(sass@1.79.4)(terser@5.36.0))(vue@3.5.11(typescript@5.6.3)) eslint: specifier: 9.12.0 version: 9.12.0(jiti@2.3.3) @@ -197,16 +203,16 @@ importers: version: 0.27.4(@babel/parser@7.25.7)(rollup@4.24.0)(vue@3.5.11(typescript@5.6.3))(webpack-sources@3.2.3) vite: specifier: 5.4.8 - version: 5.4.8(@types/node@22.7.5)(sass@1.79.4) + version: 5.4.8(@types/node@22.7.5)(sass@1.79.4)(terser@5.36.0) vite-plugin-progress: specifier: 0.0.7 - version: 0.0.7(vite@5.4.8(@types/node@22.7.5)(sass@1.79.4)) + version: 0.0.7(vite@5.4.8(@types/node@22.7.5)(sass@1.79.4)(terser@5.36.0)) vite-plugin-svg-icons: specifier: 2.0.1 - version: 2.0.1(vite@5.4.8(@types/node@22.7.5)(sass@1.79.4)) + version: 2.0.1(vite@5.4.8(@types/node@22.7.5)(sass@1.79.4)(terser@5.36.0)) vite-plugin-vue-devtools: specifier: 7.4.6 - version: 7.4.6(rollup@4.24.0)(vite@5.4.8(@types/node@22.7.5)(sass@1.79.4))(vue@3.5.11(typescript@5.6.3)) + version: 7.4.6(rollup@4.24.0)(vite@5.4.8(@types/node@22.7.5)(sass@1.79.4)(terser@5.36.0))(vue@3.5.11(typescript@5.6.3)) vue-eslint-parser: specifier: 9.4.3 version: 9.4.3(eslint@9.12.0(jiti@2.3.3)) @@ -369,6 +375,9 @@ packages: '@antfu/utils@0.7.10': resolution: {integrity: sha512-+562v9k4aI80m1+VuMHehNJWLOFjBnXn3tdOitzD0il5b7smkSBal4+a3oKiQTbrwMmN/TBUMDvbdoWDehgOww==} + '@antv/algorithm@0.1.26': + resolution: {integrity: sha512-DVhcFSQ8YQnMNW34Mk8BSsfc61iC1sAnmcfYoXTAshYHuU50p/6b7x3QYaGctDNKWGvi1ub7mPcSY0bK+aN0qg==} + '@antv/component@2.0.4': resolution: {integrity: sha512-1bqDP98gCZhgAK34SGjQk2LI0BoY+VPA3iO74hM+bjSug33V99baoB29ahO+E/upf/o0aiOhkYN/lM3zWKeCxg==} @@ -423,12 +432,21 @@ packages: '@antv/g2@5.2.5': resolution: {integrity: sha512-8DzGoYkb9K5OZmEzEp4lvK0LpG8D6UGgZ2uNEnoHRKoqibi+9VF6//igqITMZo3IDPNohlNnQEu63h71L+V5pQ==} + '@antv/g6@5.0.26': + resolution: {integrity: sha512-+Lq5hsOJbO9XHVPMyMM9L6xHlWdEvfWe6z18NycAdyXbwq0MlKb8DPzYeVXOcC/655e/kLZ4jxWf8JA3mYF2Ww==} + '@antv/g@6.0.14': resolution: {integrity: sha512-OMqo9eDB+Wku/Uj/cZU1va1d4pj3LwV68ChqrN3ozo4Xz2Pj7EoEV6o0/H8TGJthl4b9jp5k9dvI6nablvxdMg==} + '@antv/graphlib@2.0.3': + resolution: {integrity: sha512-EtQR+DIfsYy28tumTnH560v7yIzXZq0nSgFBZh76mMiV1oHEN1L4p6JKu7IMtILH14mDqzmYYYFetYoAODoQUw==} + '@antv/hierarchy@0.6.14': resolution: {integrity: sha512-V3uknf7bhynOqQDw2sg+9r9DwZ9pc6k/EcqyTFdfXB1+ydr7urisP0MipIuimucvQKN+Qkd+d6w601r1UIroqQ==} + '@antv/layout@1.2.14-beta.8': + resolution: {integrity: sha512-/zP8pRz28ahYSVk4fsfhl3T1X3FvCAi7Q3YQ8H2LZEvTojYYrJtO2AXFsojehU6HGVnIAq+QIjd3He6ot8+gvA==} + '@antv/scale@0.4.16': resolution: {integrity: sha512-5wg/zB5kXHxpTV5OYwJD3ja6R8yTiqIOkjOhmpEJiowkzRlbEC/BOyMvNUq5fqFIHnMCE9woO7+c3zxEQCKPjw==} @@ -1002,6 +1020,9 @@ packages: resolution: {integrity: sha512-R8gLRTZeyp03ymzP/6Lil/28tGeGEzhx1q2k703KGWRAI1VdvPIXdG70VJc2pAMw3NA6JKL5hhFu1sJX0Mnn/A==} engines: {node: '>=6.0.0'} + '@jridgewell/source-map@0.3.6': + resolution: {integrity: sha512-1ZJTZebgqllO79ue2bm3rIGud/bOe0pP5BjSRCRxxYkEZS8STV7zN84UBbiYu7jy+eCKSnVIUgoWWE/tt+shMQ==} + '@jridgewell/sourcemap-codec@1.5.0': resolution: {integrity: sha512-gv3ZRaISU3fjPAgNsriBRqGWQL6quFx04YMPW/zD8XMLsU32mhCCbfbO6KZFLjvYpCZ8zyDEgqsgf+PwPaM7GQ==} @@ -1027,6 +1048,11 @@ packages: resolution: {integrity: sha512-Yhlar6v9WQgUp/He7BdgzOz8lqMQ8sU+jkCq7Wx8Myc5YFJLbEe7lgui/V7G1qB1DJykHSGwreceSaD60Y0PUQ==} hasBin: true + '@naoak/workerize-transferable@0.1.0': + resolution: {integrity: sha512-fDLfuP71IPNP5+zSfxFb52OHgtjZvauRJWbVnpzQ7G7BjcbLjTny0OW1d3ZO806XKpLWNKmeeW3MhE0sy8iwYQ==} + peerDependencies: + workerize-loader: '*' + '@nodelib/fs.scandir@2.1.5': resolution: {integrity: sha512-vq24Bq3ym5HEQm2NKCr3yXDwjc7vTsEThRDnkp2DK9p1uqLR+DHurm/NOTo0KG7HYHU7eppKZj3MyqYuMBf62g==} engines: {node: '>= 8'} @@ -1503,6 +1529,9 @@ packages: '@vue/shared@3.5.11': resolution: {integrity: sha512-W8GgysJVnFo81FthhzurdRAWP/byq3q2qIw70e0JWblzVhjgOMiC2GyovXrZTFQJnFVryYaKGP3Tc9vYzYm6PQ==} + '@vueuse/components@11.1.0': + resolution: {integrity: sha512-8CTbvH1rHfAlqsMdMg6G2OiIvHiHn8HRx0yyJ+Ri/C8J6cLylXAd7VESawoCAkRdAXT4ucPnj/uYHZqEb0JbBQ==} + '@vueuse/core@11.1.0': resolution: {integrity: sha512-P6dk79QYA6sKQnghrUz/1tHi0n9mrb/iO1WTMk/ElLmTyNqgDeSZ3wcDf6fRBGzRJbeG1dxzEOvLENMjr+E3fg==} @@ -1512,12 +1541,68 @@ packages: '@vueuse/shared@11.1.0': resolution: {integrity: sha512-YUtIpY122q7osj+zsNMFAfMTubGz0sn5QzE5gPzAIiCmtt2ha3uQUY1+JPyL4gRCTsLPX82Y9brNbo/aqlA91w==} + '@webassemblyjs/ast@1.12.1': + resolution: {integrity: sha512-EKfMUOPRRUTy5UII4qJDGPpqfwjOmZ5jeGFwid9mnoqIFK+e0vqoi1qH56JpmZSzEL53jKnNzScdmftJyG5xWg==} + + '@webassemblyjs/floating-point-hex-parser@1.11.6': + resolution: {integrity: sha512-ejAj9hfRJ2XMsNHk/v6Fu2dGS+i4UaXBXGemOfQ/JfQ6mdQg/WXtwleQRLLS4OvfDhv8rYnVwH27YJLMyYsxhw==} + + '@webassemblyjs/helper-api-error@1.11.6': + resolution: {integrity: sha512-o0YkoP4pVu4rN8aTJgAyj9hC2Sv5UlkzCHhxqWj8butaLvnpdc2jOwh4ewE6CX0txSfLn/UYaV/pheS2Txg//Q==} + + '@webassemblyjs/helper-buffer@1.12.1': + resolution: {integrity: sha512-nzJwQw99DNDKr9BVCOZcLuJJUlqkJh+kVzVl6Fmq/tI5ZtEyWT1KZMyOXltXLZJmDtvLCDgwsyrkohEtopTXCw==} + + '@webassemblyjs/helper-numbers@1.11.6': + resolution: {integrity: sha512-vUIhZ8LZoIWHBohiEObxVm6hwP034jwmc9kuq5GdHZH0wiLVLIPcMCdpJzG4C11cHoQ25TFIQj9kaVADVX7N3g==} + + '@webassemblyjs/helper-wasm-bytecode@1.11.6': + resolution: {integrity: sha512-sFFHKwcmBprO9e7Icf0+gddyWYDViL8bpPjJJl0WHxCdETktXdmtWLGVzoHbqUcY4Be1LkNfwTmXOJUFZYSJdA==} + + '@webassemblyjs/helper-wasm-section@1.12.1': + resolution: {integrity: sha512-Jif4vfB6FJlUlSbgEMHUyk1j234GTNG9dBJ4XJdOySoj518Xj0oGsNi59cUQF4RRMS9ouBUxDDdyBVfPTypa5g==} + + '@webassemblyjs/ieee754@1.11.6': + resolution: {integrity: sha512-LM4p2csPNvbij6U1f19v6WR56QZ8JcHg3QIJTlSwzFcmx6WSORicYj6I63f9yU1kEUtrpG+kjkiIAkevHpDXrg==} + + '@webassemblyjs/leb128@1.11.6': + resolution: {integrity: sha512-m7a0FhE67DQXgouf1tbN5XQcdWoNgaAuoULHIfGFIEVKA6tu/edls6XnIlkmS6FrXAquJRPni3ZZKjw6FSPjPQ==} + + '@webassemblyjs/utf8@1.11.6': + resolution: {integrity: sha512-vtXf2wTQ3+up9Zsg8sa2yWiQpzSsMyXj0qViVP6xKGCUT8p8YJ6HqI7l5eCnWx1T/FYdsv07HQs2wTFbbof/RA==} + + '@webassemblyjs/wasm-edit@1.12.1': + resolution: {integrity: sha512-1DuwbVvADvS5mGnXbE+c9NfA8QRcZ6iKquqjjmR10k6o+zzsRVesil54DKexiowcFCPdr/Q0qaMgB01+SQ1u6g==} + + '@webassemblyjs/wasm-gen@1.12.1': + resolution: {integrity: sha512-TDq4Ojh9fcohAw6OIMXqiIcTq5KUXTGRkVxbSo1hQnSy6lAM5GSdfwWeSxpAo0YzgsgF182E/U0mDNhuA0tW7w==} + + '@webassemblyjs/wasm-opt@1.12.1': + resolution: {integrity: sha512-Jg99j/2gG2iaz3hijw857AVYekZe2SAskcqlWIZXjji5WStnOpVoat3gQfT/Q5tb2djnCjBtMocY/Su1GfxPBg==} + + '@webassemblyjs/wasm-parser@1.12.1': + resolution: {integrity: sha512-xikIi7c2FHXysxXe3COrVUPSheuBtpcfhbpFj4gmu7KRLYOzANztwUU0IbsqvMqzuNK2+glRGWCEqZo1WCLyAQ==} + + '@webassemblyjs/wast-printer@1.12.1': + resolution: {integrity: sha512-+X4WAlOisVWQMikjbcvY2e0rwPsKQ9F688lksZhBcPycBBuii3O7m8FACbDMWDojpAqvjIncrG8J0XHKyQfVeA==} + + '@xtuc/ieee754@1.2.0': + resolution: {integrity: sha512-DX8nKgqcGwsc0eJSqYt5lwP4DH5FlHnmuWWBRy7X0NcaGR0ZtuyeESgMwTYVEtxmsNGY+qit4QYT/MIYTOTPeA==} + + '@xtuc/long@4.2.2': + resolution: {integrity: sha512-NuHqBY1PB/D8xU6s/thBgOAiAP7HOYDQ32+BFZILJ8ivkUkAHQnWfn6WhL79Owj1qmUnoN/YPhktdIoucipkAQ==} + abbrev@1.1.1: resolution: {integrity: sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==} abs-svg-path@0.1.1: resolution: {integrity: sha512-d8XPSGjfyzlXC3Xx891DJRyZfqk5JU0BJrDQcsWomFIV1/BIzPW5HDH5iDdWpqWaav0YVIEzT1RHTwWr0FFshA==} + acorn-import-attributes@1.9.5: + resolution: {integrity: sha512-n02Vykv5uA3eHGM/Z2dQrcD56kL8TyDb2p1+0P83PClMnC/nc+anbQRhIOWnSq4Ke/KvDPrY3C9hDtC/A3eHnQ==} + peerDependencies: + acorn: ^8 + acorn-jsx@5.3.2: resolution: {integrity: sha512-rq9s+JNhf0IChjtDXxllJ7g41oZk5SlXtp0LHwyA5cejwn7vKmKp4pPri6YEePv2PU65sAsegbXtIinmDFDXgQ==} peerDependencies: @@ -1536,6 +1621,11 @@ packages: resolution: {integrity: sha512-RZNwNclF7+MS/8bDg70amg32dyeZGZxiDuQmZxKLAlQjr3jGyLx+4Kkk58UO7D2QdgFIQCovuSuZESne6RG6XQ==} engines: {node: '>= 6.0.0'} + ajv-keywords@3.5.2: + resolution: {integrity: sha512-5p6WTN0DdTGVQk6VjcEju19IgaHudalcfabD7yhDGeA6bcQnmL+CpveLJq/3hvfwd1aof6L386Ougkx6RfyMIQ==} + peerDependencies: + ajv: ^6.9.1 + ajv@6.12.6: resolution: {integrity: sha512-j3fVLgvTo527anyYyJOGTYJbG+vnnQYvE0m5mmkc1TK+nxAppkCLMIL0aZ4dblVCNoGShhm+kzE4ZUykBoMg4g==} @@ -1702,6 +1792,12 @@ packages: engines: {node: ^6 || ^7 || ^8 || ^9 || ^10 || ^11 || ^12 || >=13.7} hasBin: true + bubblesets-js@2.3.3: + resolution: {integrity: sha512-7++8/mcahpmJyIGY+YSPG5o2FnTIeNgVx17eoFyEjzcTblpcMd8SSUtt67MlKYlj8mIh9/aYpY+1GvPoy6pViQ==} + + buffer-from@1.1.2: + resolution: {integrity: sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ==} + builtin-modules@3.3.0: resolution: {integrity: sha512-zhaCDicdLuWN5UbN5IMnFqNMhNfo919sH85y2/ea+5Yg9TsTkeZxpL+JLbp6cgYFS4sRLp3YV4S6yDuqVWHYOw==} engines: {node: '>=6'} @@ -1810,6 +1906,10 @@ packages: resolution: {integrity: sha512-bIomtDF5KGpdogkLd9VspvFzk9KfpyyGlS8YFVZl7TGPBHL5snIOnxeshwVgPteQ9b4Eydl+pVbIyE1DcvCWgQ==} engines: {node: '>=10'} + chrome-trace-event@1.0.4: + resolution: {integrity: sha512-rNjApaLzuwaOTjCiT8lSDdGN1APCiqkChLMJxJPWLunPAt5fy8xgU9/jNOchV84wfIxrA0lRQB7oCT8jrn/wrQ==} + engines: {node: '>=6.0'} + ci-info@4.0.0: resolution: {integrity: sha512-TdHqgGf9odd8SXNuxtUBVx8Nv+qZOejE6qyqiy5NtbYYQOeFa6zmHkxlPzmaLxWWHsU6nJmB7AETdVPi+2NBUg==} engines: {node: '>=8'} @@ -1889,6 +1989,9 @@ packages: resolution: {integrity: sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==} engines: {node: '>= 0.8'} + comlink@4.4.1: + resolution: {integrity: sha512-+1dlx0aY5Jo1vHy/tSsIGpSkN4tS9rZSW8FIhG0JH/crs9wwweswIo/POr451r7bZww3hFbPAKnTpimzL/mm4Q==} + commander@12.1.0: resolution: {integrity: sha512-Vw8qHK3bZM9y/P10u3Vib8o/DdkvA2OtPtZvD871QKjy74Wj1WSKFILMPRPSdUSx5RFK1arlJzEtA4PkFgnbuA==} engines: {node: '>=18'} @@ -2008,6 +2111,9 @@ packages: resolution: {integrity: sha512-tdQAmyA18i4J7wprpYq8ClcxZy3SC31QMeByyCFyRt7BVHdREQZ5lpzoe5mFEYZUWe+oq8HBvk9JjpibyEV4Jg==} engines: {node: '>=12'} + d3-binarytree@1.0.2: + resolution: {integrity: sha512-cElUNH+sHu95L04m92pG73t2MEJXKu+GeKUN1TJkFsu93E5W8E9Sc3kHEGJKgenGvj19m6upSn2EunvMgMD2Yw==} + d3-collection@1.0.7: resolution: {integrity: sha512-ii0/r5f4sjKNTfh84Di+DpztYwqKhEyUlKoPrzUFfeSkWxjW49xU2QzO9qrPrNkpdI0XJkfzvmTu8V2Zylln6A==} @@ -2031,6 +2137,10 @@ packages: engines: {node: '>=12'} hasBin: true + d3-force-3d@3.0.5: + resolution: {integrity: sha512-tdwhAhoTYZY/a6eo9nR7HP3xSW/C6XvJTbeRpR92nlPzH6OiE+4MliN9feuSFd0tPtEUo+191qOhCTWx3NYifg==} + engines: {node: '>=12'} + d3-force@3.0.0: resolution: {integrity: sha512-zxV/SsA+U4yte8051P4ECydjD/S+qeYtnaIyAs9tgHCqfguma/aAQDjo85A9Z6EKhBirHRJHXIgJUlffT4wdLg==} engines: {node: '>=12'} @@ -2067,6 +2177,9 @@ packages: resolution: {integrity: sha512-3bYs1rOD33uo8aqJfKP3JWPAibgw8Zm2+L9vBKEHJ2Rg+viTR7o5Mmv5mZcieN+FRYaAOWX5SJATX6k1PWz72g==} engines: {node: '>=12'} + d3-octree@1.0.2: + resolution: {integrity: sha512-Qxg4oirJrNXauiuC94uKMbgxwnhdda9xRLl9ihq45srlJ4Ga3CSgqGcAL8iW7N5CIv4Oz8x3E734ulxyvHPvwA==} + d3-path@1.0.9: resolution: {integrity: sha512-VLaYcn81dtHVTjEHd8B+pbe9yHWpXKZUC87PzoFmsFrJqgFwDe/qxfp5MlfsfM1V5E/iVt0MmEbWQ7FVIXh/bg==} @@ -2364,6 +2477,9 @@ packages: resolution: {integrity: sha512-Zf5H2Kxt2xjTvbJvP2ZWLEICxA6j+hAmMzIlypy4xcBg1vKVnx89Wy0GbS+kf5cwCVFFzdCFh2XSCFNULS6csw==} engines: {node: '>= 0.4'} + es-module-lexer@1.5.4: + resolution: {integrity: sha512-MVNK56NiMrOwitFB7cqDwq0CQutbw+0BvLshJSse0MUNU+y1FC3bUS/AQg7oUng+/wKrrki7JfmwtVHkVfPLlw==} + es-object-atoms@1.0.0: resolution: {integrity: sha512-MZ4iQ6JwHOBQjahnjwaC1ZtIBH+2ohjamzAO3oaHcXYup7qxjF2fixyH+Q71voWHeOkI2q/TnJao/KfXYIZWbw==} engines: {node: '>= 0.4'} @@ -2476,6 +2592,10 @@ packages: peerDependencies: eslint: ^6.2.0 || ^7.0.0 || ^8.0.0 || ^9.0.0 + eslint-scope@5.1.1: + resolution: {integrity: sha512-2NxwbF/hZ0KpepYN0cNbo+FN6XoK7GaHlQhgx/hIZl6Va0bF45RQOOwhLIy8lQDbuCiadSLCBnH2CFYquit5bw==} + engines: {node: '>=8.0.0'} + eslint-scope@7.2.2: resolution: {integrity: sha512-dOt21O7lTMhDM+X9mB4GX+DZrZtCUJPL/wlcTqxyrx5IvO0IYtILdtrQGQp+8n5S0gwSVmOf9NQrjMOgfQZlIg==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} @@ -2527,6 +2647,10 @@ packages: resolution: {integrity: sha512-KmfKL3b6G+RXvP8N1vr3Tq1kL/oCFgn2NYXEtqP8/L3pKapUA4G8cFVaoF3SU323CD4XypR/ffioHmkti6/Tag==} engines: {node: '>=4.0'} + estraverse@4.3.0: + resolution: {integrity: sha512-39nnKffWz8xN1BU/2c79n9nB9HDzo0niYUqx6xyqUnyoAnQyyWpOTdZEeiCch8BBu515t4wp9ZmgVfVhn9EBpw==} + engines: {node: '>=4.0'} + estraverse@5.3.0: resolution: {integrity: sha512-MMdARuVEQziNTeJD8DgMqmhwR11BRQ/cBP+pLtYdSTnf3MIO8fFeiINEbX36ZdNlfU/7A9f3gUw49B3oQsvwBA==} engines: {node: '>=4.0'} @@ -2551,6 +2675,10 @@ packages: eventemitter3@5.0.1: resolution: {integrity: sha512-GWkBvjiSZK87ELrYOSESUYeVIc9mvLLf/nXalMOS5dYrgZq9o5OVkbZAVM06CVxYsCwH9BDZFPlQTlPA1j4ahA==} + events@3.3.0: + resolution: {integrity: sha512-mQw+2fkQbALzQ7V0MY0IqdnXNOeTtP4r0lN9z7AAawCXgqea7bDii20AYrIBrFd/Hx0M2Ocz6S111CaFkUcb0Q==} + engines: {node: '>=0.8.x'} + evtd@0.2.4: resolution: {integrity: sha512-qaeGN5bx63s/AXgQo8gj6fBkxge+OoLddLniox5qtLAEY5HSnuSlISXVPxnSae1dWblvTh4/HoMIB+mbMsvZzw==} @@ -2774,6 +2902,9 @@ packages: resolution: {integrity: sha512-XxwI8EOhVQgWp6iDL+3b0r86f4d6AX6zSU55HfB4ydCEuXLXc5FcYeOu+nnGftS4TEju/11rt4KJPTMgbfmv4A==} engines: {node: '>=10.13.0'} + glob-to-regexp@0.4.1: + resolution: {integrity: sha512-lkX1HJXwyMcprw/5YUZc2s7DrpAiHB21/V+E1rHUrVNokkvB6bqMzT0VfV6/86ZNabt1k14YOIaT7nDvOX3Iiw==} + glob@10.4.5: resolution: {integrity: sha512-7Bv8RF0k6xjo7d4A/PxYLbUCfb6c+Vpd2/mB2yRDlew7Jb5hEXiCD9ibfO7wpk8i4sevK6DFny9h7EYbM3/sHg==} hasBin: true @@ -2912,6 +3043,10 @@ packages: resolution: {integrity: sha512-dFcAjpTQFgoLMzC2VwU+C/CbS7uRL0lWmxDITmqm7C+7F0Odmj6s9l6alZc6AELXhrnggM2CeWSXHGOdX2YtwA==} engines: {node: '>= 6'} + hull.js@1.0.6: + resolution: {integrity: sha512-TC7e9sHYOaCVms0sn2hN7buxnaGfcl9h5EPVoVX9DTPoMpqQiS9bf3tmGDgiNaMVHBD91RAvWjCxrJ5Jx8BI5A==} + deprecated: This package is not maintained anymore on npmjs.com, please use GitHub URL to fetch the latest version. See the package homepage for instructions. + human-signals@5.0.0: resolution: {integrity: sha512-AXcZb6vzzrFAUE61HnN4mpLqd/cSIwNQjtNWR0euPm6y0iqx3G4gOXaIDdtdDwZmhwe82LA6+zinmW4UBWVePQ==} engines: {node: '>=16.17.0'} @@ -2993,6 +3128,9 @@ packages: resolution: {integrity: sha512-YBUanLI8Yoihw923YeFUS5fs0fF2f5TSFTNiYAAzhhDscDa3lEqYuz1pDOEP5KvX94I9ey3vsqjJcLVFVU+3QA==} engines: {node: '>= 0.10'} + is-any-array@2.0.1: + resolution: {integrity: sha512-UtilS7hLRu++wb/WBAw9bNuP1Eg04Ivn1vERJck8zJthEvXCBEBpGR/33u/xLKWEQf95803oalHrVDptcAvFdQ==} + is-arguments@1.1.1: resolution: {integrity: sha512-8Q7EARjzEnKpt/PCD7e1cgUS0a6X8u5tdSiMqXhojOdoV9TsMsiO+9VLC5vAmO8N7/GmXn7yjR8qnA6bVAEzfA==} engines: {node: '>= 0.4'} @@ -3200,6 +3338,10 @@ packages: resolution: {integrity: sha512-bZsjR/iRjl1Nk1UkjGpAzLNfQtzuijhn2g+pbZb98HQ1Gk8vM9hfbxeMBP+M2/UUdwj0RqGG3mlvk2MsAqwvEw==} engines: {node: 20 || >=22} + jest-worker@27.5.1: + resolution: {integrity: sha512-7vuh85V5cdDofPyxn58nrPjBktZo0u9x1g8WtjQol+jZDaE+fhN+cIvTj11GndBnMnyfrUOG1sZQxCdjKh+DKg==} + engines: {node: '>= 10.13.0'} + jiti@1.21.6: resolution: {integrity: sha512-2yTgeWTWzMWkHu6Jp9NKgePDaYHbntiwvYuuJLbbN9vl7DC9DvXKOB2BC3ZZ92D3cvV/aflH0osDfwpHepQ53w==} hasBin: true @@ -3326,10 +3468,18 @@ packages: resolution: {integrity: sha512-IXO6OCs9yg8tMKzfPZ1YmheJbZCiEsnBdcB03l0OcfK9prKnJb96siuHCr5Fl37/yo9DnKU+TLpxzTUspw9shg==} engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} + loader-runner@4.3.0: + resolution: {integrity: sha512-3R/1M+yS3j5ou80Me59j7F9IMs4PXs3VqRrm0TU3AbKPxlmpoY1TNscJV/oGJXo8qCatFGTfDbY6W6ipGOYXfg==} + engines: {node: '>=6.11.5'} + loader-utils@1.4.2: resolution: {integrity: sha512-I5d00Pd/jwMD2QCduo657+YM/6L3KZu++pmX9VFncxaxvHcru9jx1lBaFft+r4Mt2jK0Yhp41XlRAihzPxHNCg==} engines: {node: '>=4.0.0'} + loader-utils@2.0.4: + resolution: {integrity: sha512-xXqpXoINfFhgua9xiqD8fPFHgkoq1mmmpE92WlDbm9rNRd/EbRb+Gqf908T2DMfuHjjJlksiK2RbHVOdD/MqSw==} + engines: {node: '>=8.9.0'} + local-pkg@0.5.0: resolution: {integrity: sha512-ok6z3qlYyCDS4ZEU27HaU6x/xZa9Whf8jD4ptH5UZTQYZVYeb9bnZ3ojVhiJNLiXK1Hfc0GNbLXcmZ5plLDDBg==} engines: {node: '>=14'} @@ -3559,6 +3709,18 @@ packages: engines: {node: '>=10'} hasBin: true + ml-array-max@1.2.4: + resolution: {integrity: sha512-BlEeg80jI0tW6WaPyGxf5Sa4sqvcyY6lbSn5Vcv44lp1I2GR6AWojfUvLnGTNsIXrZ8uqWmo8VcG1WpkI2ONMQ==} + + ml-array-min@1.2.3: + resolution: {integrity: sha512-VcZ5f3VZ1iihtrGvgfh/q0XlMobG6GQ8FsNyQXD3T+IlstDv85g8kfV0xUG1QPRO/t21aukaJowDzMTc7j5V6Q==} + + ml-array-rescale@1.3.7: + resolution: {integrity: sha512-48NGChTouvEo9KBctDfHC3udWnQKNKEWN0ziELvY3KG25GR5cA8K8wNVzracsqSW1QEkAXjTNx+ycgAv06/1mQ==} + + ml-matrix@6.12.0: + resolution: {integrity: sha512-AGfR+pWaC0GmzjUnB6BfwhndPEUGz0i7QUYdqNuw1zhTov/vSRJ9pP2hs6BoGpaSbtXgrKjZz2zjD1M0xuur6A==} + mlly@1.7.2: resolution: {integrity: sha512-tN3dvVHYVz4DhSXinXIk7u9syPYaJvio118uomkovAtWBT+RdbP6Lfh/5Lvo519YMmwBafwlh20IPTXIStscpA==} @@ -3604,6 +3766,9 @@ packages: natural-compare@1.4.0: resolution: {integrity: sha512-OWND8ei3VtNC9h7V60qff3SVobHr996CTwgxubgyQYEpg290h9J0buyECNNJexkFm5sOajh5G116RYA1c8ZMSw==} + neo-async@2.6.2: + resolution: {integrity: sha512-Yd3UES5mWCSqR+qNT93S3UoYUkqAZ9lLg8a7g9rimsWmYGK8cVToA4/sF3RrshdyV3sAGMXVUmpMYOw+dLpOuw==} + next-tick@1.1.0: resolution: {integrity: sha512-CXdUiJembsNjuToQvxayPZF9Vqht7hewsvy2sOWafLvi2awflj9mOC6bHIg50orX8IJvWKY9wYQ/zB2kogPslQ==} @@ -3990,6 +4155,9 @@ packages: quickselect@2.0.0: resolution: {integrity: sha512-RKJ22hX8mHe3Y6wH/N3wCM6BWtjaxIyyUIkpHOvfFnxdI4yD4tBXEBKSbriGujF6jnSVkJrffuo6vxACiSSxIw==} + randombytes@2.1.0: + resolution: {integrity: sha512-vYl3iOX+4CKUWuxGi9Ukhie6fsqXqS9FE2Zaic4tNFD2N2QQaXOMFbuKK4QmDHC0JO6B1Zp41J0LpT0oR68amQ==} + rate-limiter-flexible@5.0.3: resolution: {integrity: sha512-lWx2y8NBVlTOLPyqs+6y7dxfEpT6YFqKy3MzWbCy95sTTOhOuxufP2QvRyOHpfXpB9OUJPbVLybw3z3AVAS5fA==} @@ -4145,6 +4313,10 @@ packages: engines: {node: '>=14.0.0'} hasBin: true + schema-utils@3.3.0: + resolution: {integrity: sha512-pN/yOAvcC+5rQ5nERGuwrjLlYvLTbCibnZ1I7B1LaiAz9BRBlE9GMgE/eqV30P7aJQUf7Ddimy/RsbYO/GrVGg==} + engines: {node: '>= 10.13.0'} + seemly@0.3.9: resolution: {integrity: sha512-bMLcaEqhIViiPbaumjLN8t1y+JpD/N8SiyYOyp0i0W6RgdyLWboIsUWAbZojF//JyerxPZR5Tgda+x3Pdne75A==} @@ -4169,6 +4341,9 @@ packages: engines: {node: '>=10'} hasBin: true + serialize-javascript@6.0.2: + resolution: {integrity: sha512-Saa1xPByTTq2gdeFZYLLo+RFE35NHZkAbqZeWNd3BpzppeVisAqpDjcp8dyf6uIvEqJRd46jemmyA4iFIeVk8g==} + set-blocking@2.0.0: resolution: {integrity: sha512-KiKBS8AnWGEyLzofFfmvKwpdPzqiy16LvQfK3yv/fVH7Bj13/wl3JSR1J+rfgRE9q7xUJK4qvgS8raSOeLUehw==} @@ -4265,6 +4440,9 @@ packages: source-map-support@0.3.3: resolution: {integrity: sha512-9O4+y9n64RewmFoKUZ/5Tx9IHIcXM6Q+RTSw6ehnqybUz4a7iwR3Eaw80uLtqqQ5D0C+5H03D4KKGo9PdP33Gg==} + source-map-support@0.5.21: + resolution: {integrity: sha512-uBHU3L3czsIyYXKX88fdrGovxdSCoTGDRZ6SYXtSRxLZUzHg5P/66Ht6uoUlHu9EZod+inXhKo3qQgwXUT/y1w==} + source-map-url@0.4.1: resolution: {integrity: sha512-cPiFOTLUKvJFIg4SKVScy4ilPPW6rFgMgfuZJPNoDuMs3nC1HbMUycBoJw77xFIp6z1UJQJOfx6C9GMH80DiTw==} deprecated: See https://github.com/lydell/source-map-url#deprecated @@ -4398,6 +4576,10 @@ packages: resolution: {integrity: sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==} engines: {node: '>=8'} + supports-color@8.1.1: + resolution: {integrity: sha512-MpUEN2OodtUzxvKQl72cUF7RQ5EiHsGvSsVG0ia9c5RbWGL2CI4C7EpPS8UTBIplnlzZiNuV56w+FuNxy3ty2Q==} + engines: {node: '>=10'} + supports-preserve-symlinks-flag@1.0.0: resolution: {integrity: sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==} engines: {node: '>= 0.4'} @@ -4439,6 +4621,27 @@ packages: resolution: {integrity: sha512-DZ4yORTwrbTj/7MZYq2w+/ZFdI6OZ/f9SFHR+71gIVUZhOQPHzVCLpvRnPgyaMpfWxxk/4ONva3GQSyNIKRv6A==} engines: {node: '>=10'} + terser-webpack-plugin@5.3.10: + resolution: {integrity: sha512-BKFPWlPDndPs+NGGCr1U59t0XScL5317Y0UReNrHaw9/FwhPENlq6bfgs+4yPfyP51vqC1bQ4rp1EfXW5ZSH9w==} + engines: {node: '>= 10.13.0'} + peerDependencies: + '@swc/core': '*' + esbuild: '*' + uglify-js: '*' + webpack: ^5.1.0 + peerDependenciesMeta: + '@swc/core': + optional: true + esbuild: + optional: true + uglify-js: + optional: true + + terser@5.36.0: + resolution: {integrity: sha512-IYV9eNMuFAV4THUspIRXkLakHnV6XO7FEdtKjf/mDyrnqUg9LnlOn6/RwRvM9SZjR4GUq8Nk8zj67FzVARr74w==} + engines: {node: '>=10'} + hasBin: true + text-table@0.2.0: resolution: {integrity: sha512-N+8UisAXDGk8PFXP4HAzVR9nbfmVJ3zYLAWiTIoqC5v5isinhr+r5uaO8+7r3BMfuNIufIsA7RdpVgacC2cSpw==} @@ -4837,6 +5040,10 @@ packages: wangeditor@4.7.15: resolution: {integrity: sha512-aPTdREd8BxXVyJ5MI+LU83FQ7u1EPd341iXIorRNYSOvoimNoZ4nPg+yn3FGbB93/owEa6buLw8wdhYnMCJQLg==} + watchpack@2.4.2: + resolution: {integrity: sha512-TnbFSbcOCcDgjZ4piURLCbJ3nJhznVh9kw6F6iokjiFPl8ONxe9A6nMDVXDiNbrSfLILs6vB07F7wLBrwPYzJw==} + engines: {node: '>=10.13.0'} + webidl-conversions@3.0.1: resolution: {integrity: sha512-2JAn3z8AR6rjK8Sm8orRC0h/bcl/DqL7tRPdGZ4I1CjdF+EaMLmYxBHyXuKL849eucPFhvBoxMsflfOb8kxaeQ==} @@ -4847,6 +5054,16 @@ packages: webpack-virtual-modules@0.6.2: resolution: {integrity: sha512-66/V2i5hQanC51vBQKPH4aI8NMAcBW59FVBs+rC7eGHupMyfn34q7rZIE+ETlJ+XTevqfUhVVBgSUNSW2flEUQ==} + webpack@5.95.0: + resolution: {integrity: sha512-2t3XstrKULz41MNMBF+cJ97TyHdyQ8HCt//pqErqDvNjU9YQBnZxIHa11VXsi7F3mb5/aO2tuDxdeTPdU7xu9Q==} + engines: {node: '>=10.13.0'} + hasBin: true + peerDependencies: + webpack-cli: '*' + peerDependenciesMeta: + webpack-cli: + optional: true + whatwg-url@5.0.0: resolution: {integrity: sha512-saE57nupxk6v3HY35+jzBwYa0rKSy0XR8JSxZPwgLr7ys0IBzhGviA1/TUGJLmSVqs8pb9AnvICXEuOHLprYTw==} @@ -4888,6 +5105,11 @@ packages: resolution: {integrity: sha512-xSBsCeh+g+dinoBv3GAOWM4LcVVO68wLXRanibtBSdUvkGWQRGeE9P7IwU9EmDDi4jA6L44lz15CGMwdw9N5+Q==} engines: {node: '>=0.4.0'} + workerize-loader@2.0.2: + resolution: {integrity: sha512-HoZ6XY4sHWxA2w0WpzgBwUiR3dv1oo7bS+oCwIpb6n54MclQ/7KXdXsVIChTCygyuHtVuGBO1+i3HzTt699UJQ==} + peerDependencies: + webpack: '*' + wrap-ansi@7.0.0: resolution: {integrity: sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==} engines: {node: '>=10'} @@ -4986,6 +5208,11 @@ snapshots: '@antfu/utils@0.7.10': {} + '@antv/algorithm@0.1.26': + dependencies: + '@antv/util': 2.0.17 + tslib: 2.7.0 + '@antv/component@2.0.4': dependencies: '@antv/g': 6.0.14 @@ -5140,6 +5367,23 @@ snapshots: fmin: 0.0.2 pdfast: 0.2.0 + '@antv/g6@5.0.26(workerize-loader@2.0.2(webpack@5.95.0(esbuild@0.23.1)))': + dependencies: + '@antv/algorithm': 0.1.26 + '@antv/component': 2.0.4 + '@antv/event-emitter': 0.1.3 + '@antv/g': 6.0.14 + '@antv/g-canvas': 2.0.15 + '@antv/g-plugin-dragndrop': 2.0.10 + '@antv/graphlib': 2.0.3 + '@antv/hierarchy': 0.6.14 + '@antv/layout': 1.2.14-beta.8(workerize-loader@2.0.2(webpack@5.95.0(esbuild@0.23.1))) + '@antv/util': 3.3.10 + bubblesets-js: 2.3.3 + hull.js: 1.0.6 + transitivePeerDependencies: + - workerize-loader + '@antv/g@6.0.14': dependencies: '@antv/g-camera-api': 2.0.13 @@ -5147,8 +5391,29 @@ snapshots: '@antv/g-lite': 2.0.11 '@antv/g-web-animations-api': 2.0.11 + '@antv/graphlib@2.0.3': + dependencies: + '@antv/event-emitter': 0.1.3 + '@antv/hierarchy@0.6.14': {} + '@antv/layout@1.2.14-beta.8(workerize-loader@2.0.2(webpack@5.95.0(esbuild@0.23.1)))': + dependencies: + '@antv/event-emitter': 0.1.3 + '@antv/graphlib': 2.0.3 + '@antv/util': 3.3.10 + '@naoak/workerize-transferable': 0.1.0(workerize-loader@2.0.2(webpack@5.95.0(esbuild@0.23.1))) + comlink: 4.4.1 + d3-force: 3.0.0 + d3-force-3d: 3.0.5 + d3-octree: 1.0.2 + d3-quadtree: 3.0.1 + dagre: 0.8.5 + ml-matrix: 6.12.0 + tslib: 2.7.0 + transitivePeerDependencies: + - workerize-loader + '@antv/scale@0.4.16': dependencies: '@antv/util': 3.3.10 @@ -5665,6 +5930,11 @@ snapshots: '@jridgewell/set-array@1.2.1': {} + '@jridgewell/source-map@0.3.6': + dependencies: + '@jridgewell/gen-mapping': 0.3.5 + '@jridgewell/trace-mapping': 0.3.25 + '@jridgewell/sourcemap-codec@1.5.0': {} '@jridgewell/trace-mapping@0.3.25': @@ -5705,6 +5975,10 @@ snapshots: - supports-color optional: true + '@naoak/workerize-transferable@0.1.0(workerize-loader@2.0.2(webpack@5.95.0(esbuild@0.23.1)))': + dependencies: + workerize-loader: 2.0.2(webpack@5.95.0(esbuild@0.23.1)) + '@nodelib/fs.scandir@2.1.5': dependencies: '@nodelib/fs.stat': 2.0.5 @@ -6103,7 +6377,7 @@ snapshots: dependencies: '@unocss/core': 0.63.4 - '@unocss/vite@0.63.4(rollup@4.24.0)(vite@5.4.8(@types/node@22.7.5)(sass@1.79.4))': + '@unocss/vite@0.63.4(rollup@4.24.0)(vite@5.4.8(@types/node@22.7.5)(sass@1.79.4)(terser@5.36.0))': dependencies: '@ampproject/remapping': 2.3.0 '@rollup/pluginutils': 5.1.2(rollup@4.24.0) @@ -6113,24 +6387,24 @@ snapshots: chokidar: 3.6.0 magic-string: 0.30.11 tinyglobby: 0.2.9 - vite: 5.4.8(@types/node@22.7.5)(sass@1.79.4) + vite: 5.4.8(@types/node@22.7.5)(sass@1.79.4)(terser@5.36.0) transitivePeerDependencies: - rollup - supports-color - '@vitejs/plugin-vue-jsx@4.0.1(vite@5.4.8(@types/node@22.7.5)(sass@1.79.4))(vue@3.5.11(typescript@5.6.3))': + '@vitejs/plugin-vue-jsx@4.0.1(vite@5.4.8(@types/node@22.7.5)(sass@1.79.4)(terser@5.36.0))(vue@3.5.11(typescript@5.6.3))': dependencies: '@babel/core': 7.25.7 '@babel/plugin-transform-typescript': 7.25.7(@babel/core@7.25.7) '@vue/babel-plugin-jsx': 1.2.5(@babel/core@7.25.7) - vite: 5.4.8(@types/node@22.7.5)(sass@1.79.4) + vite: 5.4.8(@types/node@22.7.5)(sass@1.79.4)(terser@5.36.0) vue: 3.5.11(typescript@5.6.3) transitivePeerDependencies: - supports-color - '@vitejs/plugin-vue@5.1.4(vite@5.4.8(@types/node@22.7.5)(sass@1.79.4))(vue@3.5.11(typescript@5.6.3))': + '@vitejs/plugin-vue@5.1.4(vite@5.4.8(@types/node@22.7.5)(sass@1.79.4)(terser@5.36.0))(vue@3.5.11(typescript@5.6.3))': dependencies: - vite: 5.4.8(@types/node@22.7.5)(sass@1.79.4) + vite: 5.4.8(@types/node@22.7.5)(sass@1.79.4)(terser@5.36.0) vue: 3.5.11(typescript@5.6.3) '@volar/language-core@2.4.6': @@ -6212,14 +6486,14 @@ snapshots: '@vue/devtools-api@6.6.4': {} - '@vue/devtools-core@7.4.6(vite@5.4.8(@types/node@22.7.5)(sass@1.79.4))(vue@3.5.11(typescript@5.6.3))': + '@vue/devtools-core@7.4.6(vite@5.4.8(@types/node@22.7.5)(sass@1.79.4)(terser@5.36.0))(vue@3.5.11(typescript@5.6.3))': dependencies: '@vue/devtools-kit': 7.4.6 '@vue/devtools-shared': 7.4.6 mitt: 3.0.1 nanoid: 3.3.7 pathe: 1.1.2 - vite-hot-client: 0.2.3(vite@5.4.8(@types/node@22.7.5)(sass@1.79.4)) + vite-hot-client: 0.2.3(vite@5.4.8(@types/node@22.7.5)(sass@1.79.4)(terser@5.36.0)) vue: 3.5.11(typescript@5.6.3) transitivePeerDependencies: - vite @@ -6275,6 +6549,15 @@ snapshots: '@vue/shared@3.5.11': {} + '@vueuse/components@11.1.0(vue@3.5.11(typescript@5.6.3))': + dependencies: + '@vueuse/core': 11.1.0(vue@3.5.11(typescript@5.6.3)) + '@vueuse/shared': 11.1.0(vue@3.5.11(typescript@5.6.3)) + vue-demi: 0.14.10(vue@3.5.11(typescript@5.6.3)) + transitivePeerDependencies: + - '@vue/composition-api' + - vue + '@vueuse/core@11.1.0(vue@3.5.11(typescript@5.6.3))': dependencies: '@types/web-bluetooth': 0.0.20 @@ -6294,11 +6577,95 @@ snapshots: - '@vue/composition-api' - vue + '@webassemblyjs/ast@1.12.1': + dependencies: + '@webassemblyjs/helper-numbers': 1.11.6 + '@webassemblyjs/helper-wasm-bytecode': 1.11.6 + + '@webassemblyjs/floating-point-hex-parser@1.11.6': {} + + '@webassemblyjs/helper-api-error@1.11.6': {} + + '@webassemblyjs/helper-buffer@1.12.1': {} + + '@webassemblyjs/helper-numbers@1.11.6': + dependencies: + '@webassemblyjs/floating-point-hex-parser': 1.11.6 + '@webassemblyjs/helper-api-error': 1.11.6 + '@xtuc/long': 4.2.2 + + '@webassemblyjs/helper-wasm-bytecode@1.11.6': {} + + '@webassemblyjs/helper-wasm-section@1.12.1': + dependencies: + '@webassemblyjs/ast': 1.12.1 + '@webassemblyjs/helper-buffer': 1.12.1 + '@webassemblyjs/helper-wasm-bytecode': 1.11.6 + '@webassemblyjs/wasm-gen': 1.12.1 + + '@webassemblyjs/ieee754@1.11.6': + dependencies: + '@xtuc/ieee754': 1.2.0 + + '@webassemblyjs/leb128@1.11.6': + dependencies: + '@xtuc/long': 4.2.2 + + '@webassemblyjs/utf8@1.11.6': {} + + '@webassemblyjs/wasm-edit@1.12.1': + dependencies: + '@webassemblyjs/ast': 1.12.1 + '@webassemblyjs/helper-buffer': 1.12.1 + '@webassemblyjs/helper-wasm-bytecode': 1.11.6 + '@webassemblyjs/helper-wasm-section': 1.12.1 + '@webassemblyjs/wasm-gen': 1.12.1 + '@webassemblyjs/wasm-opt': 1.12.1 + '@webassemblyjs/wasm-parser': 1.12.1 + '@webassemblyjs/wast-printer': 1.12.1 + + '@webassemblyjs/wasm-gen@1.12.1': + dependencies: + '@webassemblyjs/ast': 1.12.1 + '@webassemblyjs/helper-wasm-bytecode': 1.11.6 + '@webassemblyjs/ieee754': 1.11.6 + '@webassemblyjs/leb128': 1.11.6 + '@webassemblyjs/utf8': 1.11.6 + + '@webassemblyjs/wasm-opt@1.12.1': + dependencies: + '@webassemblyjs/ast': 1.12.1 + '@webassemblyjs/helper-buffer': 1.12.1 + '@webassemblyjs/wasm-gen': 1.12.1 + '@webassemblyjs/wasm-parser': 1.12.1 + + '@webassemblyjs/wasm-parser@1.12.1': + dependencies: + '@webassemblyjs/ast': 1.12.1 + '@webassemblyjs/helper-api-error': 1.11.6 + '@webassemblyjs/helper-wasm-bytecode': 1.11.6 + '@webassemblyjs/ieee754': 1.11.6 + '@webassemblyjs/leb128': 1.11.6 + '@webassemblyjs/utf8': 1.11.6 + + '@webassemblyjs/wast-printer@1.12.1': + dependencies: + '@webassemblyjs/ast': 1.12.1 + '@xtuc/long': 4.2.2 + + '@xtuc/ieee754@1.2.0': {} + + '@xtuc/long@4.2.2': {} + abbrev@1.1.1: optional: true abs-svg-path@0.1.1: {} + acorn-import-attributes@1.9.5(acorn@8.12.1): + dependencies: + acorn: 8.12.1 + acorn-jsx@5.3.2(acorn@8.12.1): dependencies: acorn: 8.12.1 @@ -6314,6 +6681,10 @@ snapshots: - supports-color optional: true + ajv-keywords@3.5.2(ajv@6.12.6): + dependencies: + ajv: 6.12.6 + ajv@6.12.6: dependencies: fast-deep-equal: 3.1.3 @@ -6486,6 +6857,10 @@ snapshots: node-releases: 2.0.18 update-browserslist-db: 1.1.1(browserslist@4.24.0) + bubblesets-js@2.3.3: {} + + buffer-from@1.1.2: {} + builtin-modules@3.3.0: {} bumpp@9.7.1: @@ -6634,6 +7009,8 @@ snapshots: chownr@2.0.0: {} + chrome-trace-event@1.0.4: {} + ci-info@4.0.0: {} citty@0.1.6: @@ -6719,6 +7096,8 @@ snapshots: dependencies: delayed-stream: 1.0.0 + comlink@4.4.1: {} + commander@12.1.0: {} commander@2.20.3: {} @@ -6820,6 +7199,8 @@ snapshots: dependencies: internmap: 2.0.3 + d3-binarytree@1.0.2: {} + d3-collection@1.0.7: {} d3-color@3.1.0: {} @@ -6843,6 +7224,14 @@ snapshots: iconv-lite: 0.6.3 rw: 1.3.3 + d3-force-3d@3.0.5: + dependencies: + d3-binarytree: 1.0.2 + d3-dispatch: 3.0.1 + d3-octree: 1.0.2 + d3-quadtree: 3.0.1 + d3-timer: 3.0.1 + d3-force@3.0.0: dependencies: d3-dispatch: 3.0.1 @@ -6881,6 +7270,8 @@ snapshots: dependencies: d3-color: 3.1.0 + d3-octree@1.0.2: {} + d3-path@1.0.9: {} d3-path@2.0.0: {} @@ -7198,6 +7589,8 @@ snapshots: es-errors@1.3.0: {} + es-module-lexer@1.5.4: {} + es-object-atoms@1.0.0: dependencies: es-errors: 1.3.0 @@ -7395,6 +7788,11 @@ snapshots: transitivePeerDependencies: - supports-color + eslint-scope@5.1.1: + dependencies: + esrecurse: 4.3.0 + estraverse: 4.3.0 + eslint-scope@7.2.2: dependencies: esrecurse: 4.3.0 @@ -7480,6 +7878,8 @@ snapshots: dependencies: estraverse: 5.3.0 + estraverse@4.3.0: {} + estraverse@5.3.0: {} estree-walker@2.0.2: {} @@ -7497,6 +7897,8 @@ snapshots: eventemitter3@5.0.1: {} + events@3.3.0: {} + evtd@0.2.4: {} execa@8.0.1: @@ -7777,6 +8179,8 @@ snapshots: dependencies: is-glob: 4.0.3 + glob-to-regexp@0.4.1: {} + glob@10.4.5: dependencies: foreground-child: 3.3.0 @@ -7918,6 +8322,8 @@ snapshots: - supports-color optional: true + hull.js@1.0.6: {} + human-signals@5.0.0: {} human-signals@7.0.0: {} @@ -7988,6 +8394,8 @@ snapshots: dependencies: hasown: 2.0.2 + is-any-array@2.0.1: {} + is-arguments@1.1.1: dependencies: call-bind: 1.0.7 @@ -8162,6 +8570,12 @@ snapshots: dependencies: '@isaacs/cliui': 8.0.2 + jest-worker@27.5.1: + dependencies: + '@types/node': 22.7.5 + merge-stream: 2.0.0 + supports-color: 8.1.1 + jiti@1.21.6: {} jiti@2.0.0-beta.3: {} @@ -8271,12 +8685,20 @@ snapshots: load-tsconfig@0.2.5: {} + loader-runner@4.3.0: {} + loader-utils@1.4.2: dependencies: big.js: 5.2.2 emojis-list: 3.0.0 json5: 1.0.2 + loader-utils@2.0.4: + dependencies: + big.js: 5.2.2 + emojis-list: 3.0.0 + json5: 2.2.3 + local-pkg@0.5.0: dependencies: mlly: 1.7.2 @@ -8586,6 +9008,25 @@ snapshots: mkdirp@3.0.1: {} + ml-array-max@1.2.4: + dependencies: + is-any-array: 2.0.1 + + ml-array-min@1.2.3: + dependencies: + is-any-array: 2.0.1 + + ml-array-rescale@1.3.7: + dependencies: + is-any-array: 2.0.1 + ml-array-max: 1.2.4 + ml-array-min: 1.2.3 + + ml-matrix@6.12.0: + dependencies: + is-any-array: 2.0.1 + ml-array-rescale: 1.3.7 + mlly@1.7.2: dependencies: acorn: 8.12.1 @@ -8658,6 +9099,8 @@ snapshots: natural-compare@1.4.0: {} + neo-async@2.6.2: {} + next-tick@1.1.0: {} node-fetch-native@1.6.4: {} @@ -9028,6 +9471,10 @@ snapshots: quickselect@2.0.0: {} + randombytes@2.1.0: + dependencies: + safe-buffer: 5.2.1 + rate-limiter-flexible@5.0.3: {} rbush@3.0.1: @@ -9204,6 +9651,12 @@ snapshots: immutable: 4.3.7 source-map-js: 1.2.1 + schema-utils@3.3.0: + dependencies: + '@types/json-schema': 7.0.15 + ajv: 6.12.6 + ajv-keywords: 3.5.2(ajv@6.12.6) + seemly@0.3.9: {} select@1.1.2: {} @@ -9216,6 +9669,10 @@ snapshots: semver@7.6.3: {} + serialize-javascript@6.0.2: + dependencies: + randombytes: 2.1.0 + set-blocking@2.0.0: optional: true @@ -9347,6 +9804,11 @@ snapshots: dependencies: source-map: 0.1.32 + source-map-support@0.5.21: + dependencies: + buffer-from: 1.1.2 + source-map: 0.6.1 + source-map-url@0.4.1: {} source-map@0.1.32: @@ -9475,6 +9937,10 @@ snapshots: dependencies: has-flag: 4.0.0 + supports-color@8.1.1: + dependencies: + has-flag: 4.0.0 + supports-preserve-symlinks-flag@1.0.0: {} svg-baker@1.7.0: @@ -9548,6 +10014,24 @@ snapshots: mkdirp: 1.0.4 yallist: 4.0.0 + terser-webpack-plugin@5.3.10(esbuild@0.23.1)(webpack@5.95.0(esbuild@0.23.1)): + dependencies: + '@jridgewell/trace-mapping': 0.3.25 + jest-worker: 27.5.1 + schema-utils: 3.3.0 + serialize-javascript: 6.0.2 + terser: 5.36.0 + webpack: 5.95.0(esbuild@0.23.1) + optionalDependencies: + esbuild: 0.23.1 + + terser@5.36.0: + dependencies: + '@jridgewell/source-map': 0.3.6 + acorn: 8.12.1 + commander: 2.20.3 + source-map-support: 0.5.21 + text-table@0.2.0: {} tiny-emitter@2.1.0: {} @@ -9822,11 +10306,11 @@ snapshots: dependencies: diff-match-patch: 1.0.5 - vite-hot-client@0.2.3(vite@5.4.8(@types/node@22.7.5)(sass@1.79.4)): + vite-hot-client@0.2.3(vite@5.4.8(@types/node@22.7.5)(sass@1.79.4)(terser@5.36.0)): dependencies: - vite: 5.4.8(@types/node@22.7.5)(sass@1.79.4) + vite: 5.4.8(@types/node@22.7.5)(sass@1.79.4)(terser@5.36.0) - vite-plugin-inspect@0.8.7(rollup@4.24.0)(vite@5.4.8(@types/node@22.7.5)(sass@1.79.4)): + vite-plugin-inspect@0.8.7(rollup@4.24.0)(vite@5.4.8(@types/node@22.7.5)(sass@1.79.4)(terser@5.36.0)): dependencies: '@antfu/utils': 0.7.10 '@rollup/pluginutils': 5.1.2(rollup@4.24.0) @@ -9837,19 +10321,19 @@ snapshots: perfect-debounce: 1.0.0 picocolors: 1.1.0 sirv: 2.0.4 - vite: 5.4.8(@types/node@22.7.5)(sass@1.79.4) + vite: 5.4.8(@types/node@22.7.5)(sass@1.79.4)(terser@5.36.0) transitivePeerDependencies: - rollup - supports-color - vite-plugin-progress@0.0.7(vite@5.4.8(@types/node@22.7.5)(sass@1.79.4)): + vite-plugin-progress@0.0.7(vite@5.4.8(@types/node@22.7.5)(sass@1.79.4)(terser@5.36.0)): dependencies: picocolors: 1.1.0 progress: 2.0.3 rd: 2.0.1 - vite: 5.4.8(@types/node@22.7.5)(sass@1.79.4) + vite: 5.4.8(@types/node@22.7.5)(sass@1.79.4)(terser@5.36.0) - vite-plugin-svg-icons@2.0.1(vite@5.4.8(@types/node@22.7.5)(sass@1.79.4)): + vite-plugin-svg-icons@2.0.1(vite@5.4.8(@types/node@22.7.5)(sass@1.79.4)(terser@5.36.0)): dependencies: '@types/svgo': 2.6.4 cors: 2.8.5 @@ -9859,27 +10343,27 @@ snapshots: pathe: 0.2.0 svg-baker: 1.7.0 svgo: 2.8.0 - vite: 5.4.8(@types/node@22.7.5)(sass@1.79.4) + vite: 5.4.8(@types/node@22.7.5)(sass@1.79.4)(terser@5.36.0) transitivePeerDependencies: - supports-color - vite-plugin-vue-devtools@7.4.6(rollup@4.24.0)(vite@5.4.8(@types/node@22.7.5)(sass@1.79.4))(vue@3.5.11(typescript@5.6.3)): + vite-plugin-vue-devtools@7.4.6(rollup@4.24.0)(vite@5.4.8(@types/node@22.7.5)(sass@1.79.4)(terser@5.36.0))(vue@3.5.11(typescript@5.6.3)): dependencies: - '@vue/devtools-core': 7.4.6(vite@5.4.8(@types/node@22.7.5)(sass@1.79.4))(vue@3.5.11(typescript@5.6.3)) + '@vue/devtools-core': 7.4.6(vite@5.4.8(@types/node@22.7.5)(sass@1.79.4)(terser@5.36.0))(vue@3.5.11(typescript@5.6.3)) '@vue/devtools-kit': 7.4.6 '@vue/devtools-shared': 7.4.6 execa: 8.0.1 sirv: 2.0.4 - vite: 5.4.8(@types/node@22.7.5)(sass@1.79.4) - vite-plugin-inspect: 0.8.7(rollup@4.24.0)(vite@5.4.8(@types/node@22.7.5)(sass@1.79.4)) - vite-plugin-vue-inspector: 5.2.0(vite@5.4.8(@types/node@22.7.5)(sass@1.79.4)) + vite: 5.4.8(@types/node@22.7.5)(sass@1.79.4)(terser@5.36.0) + vite-plugin-inspect: 0.8.7(rollup@4.24.0)(vite@5.4.8(@types/node@22.7.5)(sass@1.79.4)(terser@5.36.0)) + vite-plugin-vue-inspector: 5.2.0(vite@5.4.8(@types/node@22.7.5)(sass@1.79.4)(terser@5.36.0)) transitivePeerDependencies: - '@nuxt/kit' - rollup - supports-color - vue - vite-plugin-vue-inspector@5.2.0(vite@5.4.8(@types/node@22.7.5)(sass@1.79.4)): + vite-plugin-vue-inspector@5.2.0(vite@5.4.8(@types/node@22.7.5)(sass@1.79.4)(terser@5.36.0)): dependencies: '@babel/core': 7.25.7 '@babel/plugin-proposal-decorators': 7.25.7(@babel/core@7.25.7) @@ -9890,11 +10374,11 @@ snapshots: '@vue/compiler-dom': 3.5.11 kolorist: 1.8.0 magic-string: 0.30.11 - vite: 5.4.8(@types/node@22.7.5)(sass@1.79.4) + vite: 5.4.8(@types/node@22.7.5)(sass@1.79.4)(terser@5.36.0) transitivePeerDependencies: - supports-color - vite@5.4.8(@types/node@22.7.5)(sass@1.79.4): + vite@5.4.8(@types/node@22.7.5)(sass@1.79.4)(terser@5.36.0): dependencies: esbuild: 0.21.5 postcss: 8.4.47 @@ -9903,6 +10387,7 @@ snapshots: '@types/node': 22.7.5 fsevents: 2.3.3 sass: 1.79.4 + terser: 5.36.0 vooks@0.2.12(vue@3.5.11(typescript@5.6.3)): dependencies: @@ -9990,6 +10475,11 @@ snapshots: '@babel/runtime-corejs3': 7.25.7 tslib: 2.7.0 + watchpack@2.4.2: + dependencies: + glob-to-regexp: 0.4.1 + graceful-fs: 4.2.11 + webidl-conversions@3.0.1: optional: true @@ -9997,6 +10487,36 @@ snapshots: webpack-virtual-modules@0.6.2: {} + webpack@5.95.0(esbuild@0.23.1): + dependencies: + '@types/estree': 1.0.6 + '@webassemblyjs/ast': 1.12.1 + '@webassemblyjs/wasm-edit': 1.12.1 + '@webassemblyjs/wasm-parser': 1.12.1 + acorn: 8.12.1 + acorn-import-attributes: 1.9.5(acorn@8.12.1) + browserslist: 4.24.0 + chrome-trace-event: 1.0.4 + enhanced-resolve: 5.17.1 + es-module-lexer: 1.5.4 + eslint-scope: 5.1.1 + events: 3.3.0 + glob-to-regexp: 0.4.1 + graceful-fs: 4.2.11 + json-parse-even-better-errors: 2.3.1 + loader-runner: 4.3.0 + mime-types: 2.1.35 + neo-async: 2.6.2 + schema-utils: 3.3.0 + tapable: 2.2.1 + terser-webpack-plugin: 5.3.10(esbuild@0.23.1)(webpack@5.95.0(esbuild@0.23.1)) + watchpack: 2.4.2 + webpack-sources: 3.2.3 + transitivePeerDependencies: + - '@swc/core' + - esbuild + - uglify-js + whatwg-url@5.0.0: dependencies: tr46: 0.0.3 @@ -10040,6 +10560,11 @@ snapshots: wordwrap@0.0.2: {} + workerize-loader@2.0.2(webpack@5.95.0(esbuild@0.23.1)): + dependencies: + loader-utils: 2.0.4 + webpack: 5.95.0(esbuild@0.23.1) + wrap-ansi@7.0.0: dependencies: ansi-styles: 4.3.0 diff --git a/src/locales/langs/en-us.ts b/src/locales/langs/en-us.ts index 4cf367bc..a6ebadb7 100644 --- a/src/locales/langs/en-us.ts +++ b/src/locales/langs/en-us.ts @@ -199,6 +199,7 @@ const local: App.I18n.Schema = { plugin_copy: 'Copy', plugin_charts: 'Charts', plugin_charts_echarts: 'ECharts', + plugin_charts_antv: 'AntV', plugin_editor: 'Editor', plugin_editor_quill: 'Quill', plugin_editor_markdown: 'Markdown', diff --git a/src/locales/langs/zh-cn.ts b/src/locales/langs/zh-cn.ts index 5bdbda26..4c16fca1 100644 --- a/src/locales/langs/zh-cn.ts +++ b/src/locales/langs/zh-cn.ts @@ -199,6 +199,7 @@ const local: App.I18n.Schema = { plugin_copy: '剪贴板', plugin_charts: '图表', plugin_charts_echarts: 'ECharts', + plugin_charts_antv: 'AntV', plugin_editor: '编辑器', plugin_editor_quill: '富文本编辑器', plugin_editor_markdown: 'MD 编辑器', diff --git a/src/router/elegant/imports.ts b/src/router/elegant/imports.ts index b06a9180..75f1b1fe 100644 --- a/src/router/elegant/imports.ts +++ b/src/router/elegant/imports.ts @@ -40,6 +40,7 @@ export const views: Record Promise import("@/views/multi-menu/first_child/index.vue"), "multi-menu_second_child_home": () => import("@/views/multi-menu/second_child_home/index.vue"), plugin_barcode: () => import("@/views/plugin/barcode/index.vue"), + plugin_charts_antv: () => import("@/views/plugin/charts/antv/index.vue"), plugin_charts_echarts: () => import("@/views/plugin/charts/echarts/index.vue"), plugin_copy: () => import("@/views/plugin/copy/index.vue"), plugin_editor_markdown: () => import("@/views/plugin/editor/markdown/index.vue"), diff --git a/src/router/elegant/routes.ts b/src/router/elegant/routes.ts index ed5a3dff..16b29a3e 100644 --- a/src/router/elegant/routes.ts +++ b/src/router/elegant/routes.ts @@ -405,6 +405,16 @@ export const generatedRoutes: GeneratedRoute[] = [ icon: 'mdi:chart-areaspline' }, children: [ + { + name: 'plugin_charts_antv', + path: '/plugin/charts/antv', + component: 'view.plugin_charts_antv', + meta: { + title: 'plugin_charts_antv', + i18nKey: 'route.plugin_charts_antv', + icon: 'hugeicons:flow-square' + } + }, { name: 'plugin_charts_echarts', path: '/plugin/charts/echarts', diff --git a/src/router/elegant/transform.ts b/src/router/elegant/transform.ts index 734197e6..47347a1b 100644 --- a/src/router/elegant/transform.ts +++ b/src/router/elegant/transform.ts @@ -211,6 +211,7 @@ const routeMap: RouteMap = { "plugin": "/plugin", "plugin_barcode": "/plugin/barcode", "plugin_charts": "/plugin/charts", + "plugin_charts_antv": "/plugin/charts/antv", "plugin_charts_echarts": "/plugin/charts/echarts", "plugin_copy": "/plugin/copy", "plugin_editor": "/plugin/editor", diff --git a/src/typings/components.d.ts b/src/typings/components.d.ts index 4a1ab6af..b9584588 100644 --- a/src/typings/components.d.ts +++ b/src/typings/components.d.ts @@ -22,10 +22,15 @@ declare module 'vue' { IconCarbonPlay: typeof import('~icons/carbon/play')['default'] IconCarbonStop: typeof import('~icons/carbon/stop')['default'] 'IconCharm:download': typeof import('~icons/charm/download')['default'] + 'IconF7:circleFill': typeof import('~icons/f7/circle-fill')['default'] + 'IconF7:flagCircleFill': typeof import('~icons/f7/flag-circle-fill')['default'] + 'IconFe:question': typeof import('~icons/fe/question')['default'] 'IconFileIcons:microsoftExcel': typeof import('~icons/file-icons/microsoft-excel')['default'] + 'IconGg:ratio': typeof import('~icons/gg/ratio')['default'] IconGridiconsFullscreen: typeof import('~icons/gridicons/fullscreen')['default'] IconGridiconsFullscreenExit: typeof import('~icons/gridicons/fullscreen-exit')['default'] 'IconIc:roundPlus': typeof import('~icons/ic/round-plus')['default'] + 'IconIconParkOutline:equalRatio': typeof import('~icons/icon-park-outline/equal-ratio')['default'] IconIcRoundDelete: typeof import('~icons/ic/round-delete')['default'] IconIcRoundPlus: typeof import('~icons/ic/round-plus')['default'] IconIcRoundRefresh: typeof import('~icons/ic/round-refresh')['default'] @@ -43,6 +48,8 @@ declare module 'vue' { IconMdiKeyboardEsc: typeof import('~icons/mdi/keyboard-esc')['default'] IconMdiKeyboardReturn: typeof import('~icons/mdi/keyboard-return')['default'] IconMdiRefresh: typeof import('~icons/mdi/refresh')['default'] + 'IconMingcute:zoomInLine': typeof import('~icons/mingcute/zoom-in-line')['default'] + 'IconMingcute:zoomOutLine': typeof import('~icons/mingcute/zoom-out-line')['default'] IconUilSearch: typeof import('~icons/uil/search')['default'] LangSwitch: typeof import('./../components/common/lang-switch.vue')['default'] LookForward: typeof import('./../components/custom/look-forward.vue')['default'] @@ -51,6 +58,7 @@ declare module 'vue' { NBreadcrumb: typeof import('naive-ui')['NBreadcrumb'] NBreadcrumbItem: typeof import('naive-ui')['NBreadcrumbItem'] NButton: typeof import('naive-ui')['NButton'] + NButtonGroup: typeof import('naive-ui')['NButtonGroup'] NCard: typeof import('naive-ui')['NCard'] NCheckbox: typeof import('naive-ui')['NCheckbox'] NCollapse: typeof import('naive-ui')['NCollapse'] @@ -66,6 +74,7 @@ declare module 'vue' { NDropdown: typeof import('naive-ui')['NDropdown'] NDynamicInput: typeof import('naive-ui')['NDynamicInput'] NEmpty: typeof import('naive-ui')['NEmpty'] + NFlex: typeof import('naive-ui')['NFlex'] NForm: typeof import('naive-ui')['NForm'] NFormItem: typeof import('naive-ui')['NFormItem'] NFormItemGi: typeof import('naive-ui')['NFormItemGi'] diff --git a/src/typings/elegant-router.d.ts b/src/typings/elegant-router.d.ts index 3dbe3e82..cf915cfe 100644 --- a/src/typings/elegant-router.d.ts +++ b/src/typings/elegant-router.d.ts @@ -65,6 +65,7 @@ declare module "@elegant-router/types" { "plugin": "/plugin"; "plugin_barcode": "/plugin/barcode"; "plugin_charts": "/plugin/charts"; + "plugin_charts_antv": "/plugin/charts/antv"; "plugin_charts_echarts": "/plugin/charts/echarts"; "plugin_copy": "/plugin/copy"; "plugin_editor": "/plugin/editor"; @@ -181,6 +182,7 @@ declare module "@elegant-router/types" { | "multi-menu_first_child" | "multi-menu_second_child_home" | "plugin_barcode" + | "plugin_charts_antv" | "plugin_charts_echarts" | "plugin_copy" | "plugin_editor_markdown" diff --git a/src/views/plugin/charts/antv/data.ts b/src/views/plugin/charts/antv/data.ts new file mode 100644 index 00000000..c8768edd --- /dev/null +++ b/src/views/plugin/charts/antv/data.ts @@ -0,0 +1,60 @@ +import type { CustomGraphData } from './modules/antv-g6-flow'; + +// 日期可以自己随便设置,就是字符串展示,也可以修改为业务需要的字段 +export function getFlowDatas(): CustomGraphData { + return { + nodes: [ + { + id: 'NS', + name: 'Start', + status: 'COMPLETED', + startDate: '2024-10-01', + endDate: '2024-10-07', + actualStartDate: '2024-10-01', + actualEndDate: '2024-10-07' + }, + { + id: 'N1', + name: 'Node1', + status: 'COMPLETED_EARLY', + startDate: '2024-10-08', + endDate: '2024-10-10', + actualStartDate: '2024-10-08', + actualEndDate: '2024-10-09', + milestone: true + }, + { + id: 'N2', + name: 'Node2', + status: 'COMPLETED_EARLY', + startDate: '2024-10-11', + endDate: '2024-10-13', + actualStartDate: '2024-10-11', + actualEndDate: '2024-10-12' + }, + { id: 'N3', name: 'Node3', status: 'IN_PROGRESS', isDeleted: true }, + { id: 'N4', name: 'Node4', status: 'COMPLETED_LATE' }, + { id: 'N5', name: 'Node5', status: 'DELAYED', isDelayed: true, milestone: true }, + { id: 'N6', name: 'Node6', status: 'PAUSED' }, + { id: 'N7', name: 'Node7', status: 'NOT_STARTED' }, + { id: 'N8', name: 'Node8', status: 'NOT_STARTED' }, + { id: 'N9', name: 'End', status: 'NOT_STARTED' }, + { id: 'NX', name: 'NodeX', status: 'NOT_STARTED', isDeleted: true } + ], + edges: [ + { id: 'E1', source: 'NS', target: 'N1' }, + { id: 'E2', source: 'N1', target: 'N2' }, + { id: 'E3', source: 'N1', target: 'N3', isDeleted: true }, + { id: 'E4', source: 'N1', target: 'N4' }, + { id: 'E5', source: 'N2', target: 'N5' }, + { id: 'E6', source: 'N3', target: 'N5', isDeleted: true }, + { id: 'E7', source: 'N4', target: 'N5' }, + { id: 'E8', source: 'N5', target: 'N6' }, + { id: 'E9', source: 'N6', target: 'N7' }, + { id: 'E10', source: 'N6', target: 'N8' }, + { id: 'E11', source: 'N7', target: 'N9' }, + { id: 'EX', source: 'N8', target: 'N9' }, + { id: 'EO', source: 'N5', target: 'NX', isDeleted: true } + ] + }; +} diff --git a/src/views/plugin/charts/antv/index.vue b/src/views/plugin/charts/antv/index.vue new file mode 100644 index 00000000..2727f7ec --- /dev/null +++ b/src/views/plugin/charts/antv/index.vue @@ -0,0 +1,59 @@ + + + diff --git a/src/views/plugin/charts/antv/modules/antv-flow.vue b/src/views/plugin/charts/antv/modules/antv-flow.vue new file mode 100644 index 00000000..790ac1c1 --- /dev/null +++ b/src/views/plugin/charts/antv/modules/antv-flow.vue @@ -0,0 +1,134 @@ + + + diff --git a/src/views/plugin/charts/antv/modules/antv-g6-flow.ts b/src/views/plugin/charts/antv/modules/antv-g6-flow.ts new file mode 100644 index 00000000..5602f704 --- /dev/null +++ b/src/views/plugin/charts/antv/modules/antv-g6-flow.ts @@ -0,0 +1,169 @@ +import type { CustomBehaviorOption, EdgeData, GraphData, NodeData } from '@antv/g6'; +import { Graph } from '@antv/g6'; +import type { Canvas } from '@antv/g6/lib/runtime/canvas'; +import { useThemeStore } from '@/store/modules/theme'; +import { getNodeIcon, nodeStatus } from './status'; + +const baseColor = 'rgb(158 163 171)'; + +export interface CustomNodeData extends NodeData { + isDelayed?: boolean; + isDeleted?: boolean; + milestone?: boolean; +} + +export interface CustomEdgeData extends EdgeData { + isDelayed?: boolean; + isDeleted?: boolean; +} + +export interface CustomGraphData extends GraphData { + nodes?: CustomNodeData[]; + edges?: CustomEdgeData[]; +} + +interface AntFlow { + container: string | HTMLElement | Canvas; + data: CustomGraphData; + behaviors?: CustomBehaviorOption[]; + autoFit?: 'view' | 'center'; +} + +export function useAntFlow(property: AntFlow) { + const themeStore = useThemeStore(); + const otherBehaviors = property.behaviors ? property.behaviors : []; + + const graph = new Graph({ + container: property.container, + animation: false, + padding: 16, + theme: 'light', + autoFit: property.autoFit || 'center', + data: property.data as GraphData, + node: { + type: 'rect', + + style: (node: any) => { + const iconS = getNodeIcon(node); + let labelFill = '#000000'; + if (node.taskState === 'NOT_STARTED') { + labelFill = '#787878'; + } + + return { + labelText: node.name, + size: [120, 26], + radius: 99, + fill: '#FFFFFF', + stroke: node.isDeleted ? themeStore.otherColor.error : baseColor, + lineDash: node.isDeleted ? 4 : 0, + lineWidth: 1, + labelFill, + labelX: 2, + labelY: 2, + labelTextBaseline: 'middle', + labelTextAlign: 'center', + labelLineHeight: 13, + labelWordWrap: true, + labelMaxWidth: 72, + iconSrc: iconS, + iconWidth: 16, + iconHeight: 16, + iconX: -45, + labelFontSize: 12, + labelPlacement: 'center', + badgeLineWidth: 6, + badgeFontSize: 8, + badges: [ + { text: '延期', placement: 'top', offsetY: -11, visibility: node.isDelayed ? 'visible' : 'hidden' }, + { text: '已删除', placement: 'bottom', offsetY: 11, visibility: node.isDeleted ? 'visible' : 'hidden' } + ], + badgePalette: [themeStore.otherColor.error, themeStore.otherColor.error], + ports: [{ placement: 'left' }, { placement: 'right' }] + }; + }, + state: { + selected: { + lineWidth: 2, + stroke: themeStore.themeColor, + labelFill: themeStore.themeColor, + halo: true, + haloStroke: themeStore.themeColor, + haloLineWidth: 6 + }, + active: (node: any) => ({ + halo: true, + haloStroke: node.isDeleted ? themeStore.otherColor.error : themeStore.themeColor, + haloLineWidth: 6, + zIndex: 2 + }) + } + }, + edge: { + type: 'cubic-horizontal', + style: (node: any) => ({ + curveOffset: 10, + curvePosition: 0.5, + stroke: node.isDeleted ? themeStore.otherColor.error : baseColor, + lineDash: node.isDeleted ? 4 : 0 + }), + state: { + active: (node: any) => ({ + lineWidth: 2, + stroke: node.isDeleted ? themeStore.otherColor.error : themeStore.themeColor, + halo: true, + haloStroke: node.isDeleted ? themeStore.otherColor.error : themeStore.themeColor, + haloLineWidth: 6, + zIndex: 2 + }) + } + }, + layout: { + type: 'antv-dagre', + rankdir: 'LR', + ranksep: 20, + nodesep: -20, + controlPoints: true + }, + behaviors: [ + { + key: 'hover-activate', + type: 'hover-activate', + degree: 1, + direction: 'both' + }, + 'drag-canvas', + ...otherBehaviors + ], + plugins: [ + { + type: 'tooltip', + enable: (event: any) => event.targetType === 'node', + getContent: (_event: any, items: any) => { + let result = '
'; + + // 弹出提示可以自定义各种内容,但是这里很奇怪,有的class不跟随uniocss的样式 + items?.forEach((item: any) => { + result += `

${item.name}

`; + result += `
状态:
${nodeStatus[item.status as keyof typeof nodeStatus].type}
`; + + result += `
`; + result += `
预计开始
${item.startDate || '-'}
`; + result += `
预计结束
${item.endDate || '-'}
`; + result += `
实际开始
${item.actualStartDate || '-'}
`; + result += `
实际结束
${item.actualEndDate || '-'}
`; + result += `
`; + }); + + result += '
'; + return result; + } + } + ] + }); + graph.render(); + + return { + graph + }; +} diff --git a/src/views/plugin/charts/antv/modules/status.ts b/src/views/plugin/charts/antv/modules/status.ts new file mode 100644 index 00000000..26812e34 --- /dev/null +++ b/src/views/plugin/charts/antv/modules/status.ts @@ -0,0 +1,99 @@ +import { h } from 'vue'; +import type { TagProps } from 'naive-ui'; +import { NTag } from 'naive-ui'; + +export const nodeStatus = { + MILESTONE: { + type: '里程碑', + color: '#5b5b5b', + textColor: '', + base64: '', + flag64: '' + }, + NOT_STARTED: { + type: '未开始', + color: '#CCCDD0', + textColor: '#5b5b5b', + base64: + 'data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIxZW0iIGhlaWdodD0iMWVtIiB2aWV3Qm94PSIwIDAgNTYgNTYiPjxwYXRoIGZpbGw9IiNDQ0NERDAiIGQ9Ik0yOCA1MS45MDZjMTMuMDU1IDAgMjMuOTA2LTEwLjgyOCAyMy45MDYtMjMuOTA2YzAtMTMuMDU1LTEwLjg3NS0yMy45MDYtMjMuOTMtMjMuOTA2QzE0Ljg5OSA0LjA5NCA0LjA5NSAxNC45NDUgNC4wOTUgMjhjMCAxMy4wNzggMTAuODI4IDIzLjkwNiAyMy45MDYgMjMuOTA2Ii8+PC9zdmc+', + flag64: + 'data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIxZW0iIGhlaWdodD0iMWVtIiB2aWV3Qm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i0xLjA3N1YxOS44MmMwLTEuMDA4LjQ5Mi0xLjc1OCAxLjQ1My0yLjE4Yy44NDQtLjM3NCAxLjU3LS41ODUgMy4zNzUtLjU4NWM0LjI0MiAwIDYuODkgMi4wODYgMTAuODc1IDIuMDg2YzEuOTIyIDAgMi45My0uNDkzIDMuNTQtLjQ5M2MuNzk2IDAgMS40MDYuNDkzIDEuNDA2IDEuMTcydjExLjU1NWMwIDEuMDU1LS40NDYgMS43MzQtMS40NTQgMi4xOGMtLjg2Ny4zOTgtMS42MTcuNjA5LTMuMzc1LjYwOWMtNC4wNzggMC02LjY4LTIuMDYyLTEwLjg3NS0yLjA2MmMtMS40MyAwLTIuMzY3LjI4LTIuNzg5LjQ2OHY3LjE0OWMwIC41ODYtLjQ0NSAxLjA3OC0xLjA1NCAxLjA3OCIvPjwvc3ZnPg==' + }, + COMPLETED: { + type: '已完成', + color: '#33C73D', + textColor: '#084e0c', + base64: + 'data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIxZW0iIGhlaWdodD0iMWVtIiB2aWV3Qm94PSIwIDAgNTYgNTYiPjxwYXRoIGZpbGw9IiMzM0M3M0QiIGQ9Ik0yOCA1MS45MDZjMTMuMDU1IDAgMjMuOTA2LTEwLjgyOCAyMy45MDYtMjMuOTA2YzAtMTMuMDU1LTEwLjg3NS0yMy45MDYtMjMuOTMtMjMuOTA2QzE0Ljg5OSA0LjA5NCA0LjA5NSAxNC45NDUgNC4wOTUgMjhjMCAxMy4wNzggMTAuODI4IDIzLjkwNiAyMy45MDYgMjMuOTA2Ii8+PC9zdmc+', + flag64: + 'data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIxZW0iIGhlaWdodD0iMWVtIiB2aWV3Qm94PSIwIDAgNTYgNTYiPjxwYXRoIGZpbGw9IiMzM0M3M0QiIGQ9Ik0yOCA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AxNC45NDUgNC4wOTUgMjhjMCAxMy4wNzggMTAuODI4IDIzLjkwNiAyMy45MDYgMjMuOTA2Ii8+PC9zdmc+', + flag64: + 'data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIxZW0iIGhlaWdodD0iMWVtIiB2aWV3Qm94PSIwIDAgNTYgNTYiPjxwYXRoIGZpbGw9IiNDQ0ZGOTkiIGQ9Ik0yOCA1MS45MDZjMTMuMDU1IDAgMjMuOTA2LTEwLjg1MSAyMy45MDYtMjMuOTA2YzAtMTMuMDc4LTEwLjg3NS0yMy45MDYtMjMuOTMtMjMuOTA2QzE0Ljg5OSA0LjA5NCA0LjA5NSAxNC45MjIgNC4wOTUgMjhjMCAxMy4wNTUgMTAuODI4IDIzLjkwNiAyMy45MDYgMjMuOTA2bS05LjA3LTExLjExYy0uNTg2IDAtMS4xMDItLjUxNS0xLjEwMi0xLjA3N1YxOS44MmMwLTEuMDA4LjQ5Mi0xLjc1OCAxLjQ1My0yLjE4Yy44NDQtLjM3NCAxLjU3LS41ODUgMy4zNzUtLjU4NWM0LjI0MiAwIDYuODkgMi4wODYgMTAuODc1IDIuMDg2YzEuOTIyIDAgMi45My0uNDkzIDMuNTQtLjQ5M2MuNzk2IDAgMS40MDYuNDkzIDEuNDA2IDEuMTcydjExLjU1NWMwIDEuMDU1LS40NDYgMS43MzQtMS40NTQgMi4xOGMtLjg2Ny4zOTgtMS42MTcuNjA5LTMuMzc1LjYwOWMtNC4wNzggMC02LjY4LTIuMDYyLTEwLjg3NS0yLjA2MmMtMS40MyAwLTIuMzY3LjI4LTIuNzg5LjQ2OHY3LjE0OWMwIC41ODYtLjQ0NSAxLjA3OC0xLjA1NCAxLjA3OCIvPjwvc3ZnPg==' + }, + COMPLETED_LATE: { + type: '延期完成', + color: '#CC6699', + textColor: '#4b092a', + base64: + 'data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy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zc1LjYwOWMtNC4wNzggMC02LjY4LTIuMDYyLTEwLjg3NS0yLjA2MmMtMS40MyAwLTIuMzY3LjI4LTIuNzg5LjQ2OHY3LjE0OWMwIC41ODYtLjQ0NSAxLjA3OC0xLjA1NCAxLjA3OCIvPjwvc3ZnPg==' + } +}; + +export function getNodeIcon(node: any) { + const type = node.milestone ? 'flag64' : 'base64'; + if (node.status) { + return nodeStatus[node.status as keyof typeof nodeStatus][type]; + } + return ''; +} + +export function getNodeStatusTag(state: keyof typeof nodeStatus, tagProperty?: TagProps) { + return h( + NTag, + { + color: { textColor: nodeStatus[state]?.textColor, color: nodeStatus[state]?.color }, + bordered: false, + size: 'small', + ...tagProperty + }, + { + default: () => nodeStatus[state]?.type + } + ); +}