antvis / F2

📱📈An elegant, interactive and flexible charting library for mobile.
https://f2.antv.vision/zh
MIT License
7.89k stars 649 forks source link

折线图,只有一个数据的时候,iphone的safari浏览器不显示图表的点 #1198

Open yusongh opened 3 years ago

yusongh commented 3 years ago

Reproduction link

https://github.com/yusongH/antv-f2-problem-single-data-demo

Steps to reproduce

直接运行项目,然后用不同浏览器就可以访问就可以看出问题

Environment Info
f2 3.8.9
System IOS 14.7
Browser Mozilla/5.0 (iPhone; CPU iPhone OS 14_7 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/14.1.2 Mobile/15E148 Safari/604.1
Wzb3422 commented 2 years ago

I ran into the same issue.

onegaop commented 7 months ago

我也是,后面怎么解决的

iyanming commented 7 months ago

++1

MichealMai commented 3 months ago

If you want to solve this problem, I suggest you could draw a specific point which is match the data in safari! Here is demo code! if(isOnePoint) { chart.guide().point({ position: ['50%', '50%'], style: { stroke: '#F9C083', fill: '#fff', r: 2, fillOpacity: 1, }, }); }

中文: 解决这个问题方法就是在ios代码上直接就画一个点就好了,前提是判断一下是否只有一个数据点!目前官方好像无解!