G6
G6 copied to clipboard
Unable to parse color from object [247,249.7,255]
Describe the bug
Only import G6 from '@antv/g6', then cause the error below:
Your Example Website or App
Above
Steps to Reproduce the Bug or Issue
Above
Expected behavior
Above
Screenshots or Videos
No response
Platform
- OS: macOS
- Browser: Chrome
- Vue version: 2.5.17
- g6 version: 4.6.0
Additional context
No response
How did you assign color?
We support string like 'rgb(rvalue, gvalue, bvalue)' or hexadecimal string format
@shangeyao 老哥解决了吗,我按照官方案例也是报这个错
在线复现 demo 给下呢?
我预估的没错的话好像是color.js这个包搞的鬼
我预估的没错的话好像是color.js这个包搞的鬼
请问一下怎么解决的?
我预估的没错的话好像是color.js这个包搞的鬼
请问一下怎么解决的?
发个在线复现 demo 看下?
我预估的没错的话好像是color.js这个包搞的鬼
请问一下怎么解决的?
发个在线复现 demo 看下?
vue版本:2.5.2 g6版本:4.7.14 引入g6即报错。import G6 from "@antv/g6"; 报错:vue-router.esm.js:2113 Error: Unable to parse color from object [247,249.7,255] at new Color (index.js:49:1) at Color (index.js:11:1) at mixColor (color.js:12:15) at getColorsWithDefaultTheme (color.js:21:1) at getColorsWithSubjectColor (color.js:154:1) at ./node_modules/@[email protected]@@antv/g6-pc/es/global.js (global.js:5:41) at webpack_require (bootstrap 48dee3b9b7a5536a6709:707:1) at fn (bootstrap 48dee3b9b7a5536a6709:112:1) at ./node_modules/@[email protected]@@antv/g6-pc/es/graph/graph.js (graph.js:1:1)
我预估的没错的话好像是color.js这个包搞的鬼
请问一下怎么解决的?
发个在线复现 demo 看下?
@Yanyan-Wang
在react中是正常的哦
需要看下这个颜色的数组一开始是怎么传进去的,大家给个在线复现 case 吧?
我也遇到了同样的问题,换个版本重新安装一下就好了
这个问题还没修好吗,我装的4.8.23版本还存在这个问题,哪个版本是好的