Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

🐛[BUG]当使用scale>y>domain的时候,图表会出现偏移 #2826

Open
remyyang717 opened this issue Jan 3, 2025 · 0 comments
Open

🐛[BUG]当使用scale>y>domain的时候,图表会出现偏移 #2826

remyyang717 opened this issue Jan 3, 2025 · 0 comments

Comments

@remyyang717
Copy link

remyyang717 commented Jan 3, 2025

🐛 bug 描述 [详细地描述 bug,让大家都能理解]

当使用scale linear domain的时候,图形会遮挡x轴
Domain issue
Domain issue2

📷 复现步骤 [清晰描述复现步骤,让别人也能看到问题]

在创建图表config里面运用:
scale: {
y: {
type: 'linear',
domain: [50, 300]
}
},
然后在创建图表以后, 图表会遮挡住x轴和label
不只限于 Column 和Line
而且只要min domain 大于0 以后, 图表就会出现向下偏移

🏞 期望结果 [描述你原本期望看到的结果]

我希望在使用domain的时候,当min domain大于0的时候,图形不要出现偏移而遮挡x轴
最好是让domain不要影响到图表的正常显示

💻 复现代码 [提供可复现的代码,仓库,或线上示例]

// TempContentComponent.js
import React from 'react';
import { Column } from '@ant-design/plots';

function TempContentComponent()
{

const config = {
    colorField: 'location',
    group: true,
    width: 500,
    height: 500,
    title: 'yo',
    data: [
        {
            "location": "Auckland",
            "date": "01-01-2024",
            "value": 90.2
        },
        {
            "location": "Auckland",
            "date": "02-01-2024",
            "value": 26.8
        },
        {
            "location": "Auckland",
            "date": "03-01-2024",
            "value": 5.2
        },
        {
            "location": "Auckland",
            "date": "04-01-2024",
            "value": 95.2
        },
        {
            "location": "Auckland",
            "date": "05-01-2024",
            "value": 9.0
        },
        {
            "location": "Auckland",
            "date": "06-01-2024",
            "value": 28.7
        },
        {
            "location": "Auckland",
            "date": "07-01-2024",
            "value": 50.3
        },
        {
            "location": "Auckland",
            "date": "08-01-2024",
            "value": 3.2
        },
        {
            "location": "Auckland",
            "date": "09-01-2024",
            "value": 43.4
        },
        {
            "location": "Auckland",
            "date": "10-01-2024",
            "value": 96.0
        },
        {
            "location": "Auckland",
            "date": "11-01-2024",
            "value": 37.7
        },
        {
            "location": "Auckland",
            "date": "12-01-2024",
            "value": 32.4
        },
        {
            "location": "Auckland",
            "date": "13-01-2024",
            "value": 32.9
        },
        {
            "location": "Auckland",
            "date": "14-01-2024",
            "value": 46.1
        },
        {
            "location": "Auckland",
            "date": "15-01-2024",
            "value": 83.0
        },
        {
            "location": "Auckland",
            "date": "16-01-2024",
            "value": 34.1
        },
        {
            "location": "Auckland",
            "date": "17-01-2024",
            "value": 95.1
        },
        {
            "location": "Auckland",
            "date": "18-01-2024",
            "value": 83.3
        },
        {
            "location": "Auckland",
            "date": "19-01-2024",
            "value": 15.8
        },
        {
            "location": "Auckland",
            "date": "20-01-2024",
            "value": 80.3
        },
        {
            "location": "Auckland",
            "date": "21-01-2024",
            "value": 44.0
        },
        {
            "location": "Auckland",
            "date": "22-01-2024",
            "value": 69.6
        },
        {
            "location": "Auckland",
            "date": "23-01-2024",
            "value": 50.3
        },
        {
            "location": "Auckland",
            "date": "24-01-2024",
            "value": 6.5
        },
        {
            "location": "Auckland",
            "date": "25-01-2024",
            "value": 63.1
        },
        {
            "location": "Auckland",
            "date": "26-01-2024",
            "value": 15.0
        },
        {
            "location": "Auckland",
            "date": "27-01-2024",
            "value": 55.8
        },
        {
            "location": "Auckland",
            "date": "28-01-2024",
            "value": 45.1
        },
        {
            "location": "Auckland",
            "date": "29-01-2024",
            "value": 14.4
        },
        {
            "location": "Auckland",
            "date": "30-01-2024",
            "value": 1.9
        },
        {
            "location": "Wellington",
            "date": "01-01-2024",
            "value": 90.4
        },
        {
            "location": "Wellington",
            "date": "02-01-2024",
            "value": 32.2
        },
        {
            "location": "Wellington",
            "date": "03-01-2024",
            "value": 0.1
        },
        {
            "location": "Wellington",
            "date": "04-01-2024",
            "value": 87.3
        },
        {
            "location": "Wellington",
            "date": "05-01-2024",
            "value": 17.7
        },
        {
            "location": "Wellington",
            "date": "06-01-2024",
            "value": 7.1
        },
        {
            "location": "Wellington",
            "date": "07-01-2024",
            "value": 22.0
        },
        {
            "location": "Wellington",
            "date": "08-01-2024",
            "value": 30.8
        },
        {
            "location": "Wellington",
            "date": "09-01-2024",
            "value": 15.5
        },
        {
            "location": "Wellington",
            "date": "10-01-2024",
            "value": 92.8
        },
        {
            "location": "Wellington",
            "date": "11-01-2024",
            "value": 60.4
        },
        {
            "location": "Wellington",
            "date": "12-01-2024",
            "value": 77.8
        },
        {
            "location": "Wellington",
            "date": "13-01-2024",
            "value": 42.5
        },
        {
            "location": "Wellington",
            "date": "14-01-2024",
            "value": 60.0
        },
        {
            "location": "Wellington",
            "date": "15-01-2024",
            "value": 33.4
        },
        {
            "location": "Wellington",
            "date": "16-01-2024",
            "value": 37.2
        },
        {
            "location": "Wellington",
            "date": "17-01-2024",
            "value": 65.5
        },
        {
            "location": "Wellington",
            "date": "18-01-2024",
            "value": 94.1
        },
        {
            "location": "Wellington",
            "date": "19-01-2024",
            "value": 42.2
        },
        {
            "location": "Wellington",
            "date": "20-01-2024",
            "value": 96.2
        },
        {
            "location": "Wellington",
            "date": "21-01-2024",
            "value": 30.7
        },
        {
            "location": "Wellington",
            "date": "22-01-2024",
            "value": 4.7
        },
        {
            "location": "Wellington",
            "date": "23-01-2024",
            "value": 93.7
        },
        {
            "location": "Wellington",
            "date": "24-01-2024",
            "value": 95.5
        },
        {
            "location": "Wellington",
            "date": "25-01-2024",
            "value": 89.7
        },
        {
            "location": "Wellington",
            "date": "26-01-2024",
            "value": 57.1
        },
        {
            "location": "Wellington",
            "date": "27-01-2024",
            "value": 42.7
        },
        {
            "location": "Wellington",
            "date": "28-01-2024",
            "value": 73.0
        },
        {
            "location": "Wellington",
            "date": "29-01-2024",
            "value": 41.4
        },
        {
            "location": "Wellington",
            "date": "30-01-2024",
            "value": 97.3
        },
        {
            "location": "Hamilton",
            "date": "01-01-2024",
            "value": 52.9
        },
        {
            "location": "Hamilton",
            "date": "02-01-2024",
            "value": 77.8
        },
        {
            "location": "Hamilton",
            "date": "03-01-2024",
            "value": 17.0
        },
        {
            "location": "Hamilton",
            "date": "04-01-2024",
            "value": 7.5
        },
        {
            "location": "Hamilton",
            "date": "05-01-2024",
            "value": 78.3
        },
        {
            "location": "Hamilton",
            "date": "06-01-2024",
            "value": 6.5
        },
        {
            "location": "Hamilton",
            "date": "07-01-2024",
            "value": 0.8
        },
        {
            "location": "Hamilton",
            "date": "08-01-2024",
            "value": 45.9
        },
        {
            "location": "Hamilton",
            "date": "09-01-2024",
            "value": 28.0
        },
        {
            "location": "Hamilton",
            "date": "10-01-2024",
            "value": 90.7
        },
        {
            "location": "Hamilton",
            "date": "11-01-2024",
            "value": 52.8
        },
        {
            "location": "Hamilton",
            "date": "12-01-2024",
            "value": 36.7
        },
        {
            "location": "Hamilton",
            "date": "13-01-2024",
            "value": 66.1
        },
        {
            "location": "Hamilton",
            "date": "14-01-2024",
            "value": 75.6
        },
        {
            "location": "Hamilton",
            "date": "15-01-2024",
            "value": 4.7
        },
        {
            "location": "Hamilton",
            "date": "16-01-2024",
            "value": 64.8
        },
        {
            "location": "Hamilton",
            "date": "17-01-2024",
            "value": 68.7
        },
        {
            "location": "Hamilton",
            "date": "18-01-2024",
            "value": 33.9
        },
        {
            "location": "Hamilton",
            "date": "19-01-2024",
            "value": 99.0
        },
        {
            "location": "Hamilton",
            "date": "20-01-2024",
            "value": 44.5
        },
        {
            "location": "Hamilton",
            "date": "21-01-2024",
            "value": 44.7
        },
        {
            "location": "Hamilton",
            "date": "22-01-2024",
            "value": 4.6
        },
        {
            "location": "Hamilton",
            "date": "23-01-2024",
            "value": 42.4
        },
        {
            "location": "Hamilton",
            "date": "24-01-2024",
            "value": 91.8
        },
        {
            "location": "Hamilton",
            "date": "25-01-2024",
            "value": 17.8
        },
        {
            "location": "Hamilton",
            "date": "26-01-2024",
            "value": 33.1
        },
        {
            "location": "Hamilton",
            "date": "27-01-2024",
            "value": 12.0
        },
        {
            "location": "Hamilton",
            "date": "28-01-2024",
            "value": 230
        },
        {
            "location": "Hamilton",
            "date": "29-01-2024",
            "value": 99.6
        },
        {
            "location": "Hamilton",
            "date": "30-01-2024",
            "value": 79.1
        },
        {
            "location": "Lower Hutt",
            "date": "01-01-2024",
            "value": 39.8
        },
        {
            "location": "Lower Hutt",
            "date": "02-01-2024",
            "value": 66.6
        },
        {
            "location": "Lower Hutt",
            "date": "03-01-2024",
            "value": 15.9
        },
        {
            "location": "Lower Hutt",
            "date": "04-01-2024",
            "value": 54.2
        },
        {
            "location": "Lower Hutt",
            "date": "05-01-2024",
            "value": 16.8
        },
        {
            "location": "Lower Hutt",
            "date": "06-01-2024",
            "value": 70.2
        },
        {
            "location": "Lower Hutt",
            "date": "07-01-2024",
            "value": 99.3
        },
        {
            "location": "Lower Hutt",
            "date": "08-01-2024",
            "value": 83.2
        },
        {
            "location": "Lower Hutt",
            "date": "09-01-2024",
            "value": 16.7
        },
        {
            "location": "Lower Hutt",
            "date": "10-01-2024",
            "value": 45.9
        },
        {
            "location": "Lower Hutt",
            "date": "11-01-2024",
            "value": 35.1
        },
        {
            "location": "Lower Hutt",
            "date": "12-01-2024",
            "value": 54.7
        },
        {
            "location": "Lower Hutt",
            "date": "13-01-2024",
            "value": 0.3
        },
        {
            "location": "Lower Hutt",
            "date": "14-01-2024",
            "value": 57.0
        },
        {
            "location": "Lower Hutt",
            "date": "15-01-2024",
            "value": 42.9
        },
        {
            "location": "Lower Hutt",
            "date": "16-01-2024",
            "value": 60.9
        },
        {
            "location": "Lower Hutt",
            "date": "17-01-2024",
            "value": 8.4
        },
        {
            "location": "Lower Hutt",
            "date": "18-01-2024",
            "value": 41.3
        },
        {
            "location": "Lower Hutt",
            "date": "19-01-2024",
            "value": 17.8
        },
        {
            "location": "Lower Hutt",
            "date": "20-01-2024",
            "value": 79.0
        },
        {
            "location": "Lower Hutt",
            "date": "21-01-2024",
            "value": 1.6
        },
        {
            "location": "Lower Hutt",
            "date": "22-01-2024",
            "value": 35.5
        },
        {
            "location": "Lower Hutt",
            "date": "23-01-2024",
            "value": 61.3
        },
        {
            "location": "Lower Hutt",
            "date": "24-01-2024",
            "value": 89.7
        },
        {
            "location": "Lower Hutt",
            "date": "25-01-2024",
            "value": 3.0
        },
        {
            "location": "Lower Hutt",
            "date": "26-01-2024",
            "value": 78.8
        },
        {
            "location": "Lower Hutt",
            "date": "27-01-2024",
            "value": 92.9
        },
        {
            "location": "Lower Hutt",
            "date": "28-01-2024",
            "value": 74.6
        },
        {
            "location": "Lower Hutt",
            "date": "29-01-2024",
            "value": 219
        },
        {
            "location": "Lower Hutt",
            "date": "30-01-2024",
            "value": 17.0
        },
        {
            "location": "Lower Hutt",
            "date": "31-01-2024",
            "value": 51.4
        },
        {
            "location": "Queenstown",
            "date": "01-01-2024",
            "value": 151.8
        },
        {
            "location": "Queenstown",
            "date": "02-01-2024",
            "value": 180.0
        },
        {
            "location": "Queenstown",
            "date": "03-01-2024",
            "value": 175.0
        },
        {
            "location": "Queenstown",
            "date": "04-01-2024",
            "value": 120.3
        },
        {
            "location": "Queenstown",
            "date": "05-01-2024",
            "value": 94.3
        },
        {
            "location": "Queenstown",
            "date": "06-01-2024",
            "value": 129.4
        },
        {
            "location": "Queenstown",
            "date": "07-01-2024",
            "value": 167.7
        },
        {
            "location": "Queenstown",
            "date": "08-01-2024",
            "value": 151.7
        },
        {
            "location": "Queenstown",
            "date": "09-01-2024",
            "value": 49.3
        },
        {
            "location": "Queenstown",
            "date": "10-01-2024",
            "value": 25.6
        },
        {
            "location": "Queenstown",
            "date": "11-01-2024",
            "value": 123.9
        },
        {
            "location": "Queenstown",
            "date": "12-01-2024",
            "value": 76.0
        },
        {
            "location": "Queenstown",
            "date": "13-01-2024",
            "value": 136.3
        },
        {
            "location": "Queenstown",
            "date": "14-01-2024",
            "value": 152.8
        },
        {
            "location": "Queenstown",
            "date": "15-01-2024",
            "value": 184.6
        },
        {
            "location": "Queenstown",
            "date": "16-01-2024",
            "value": 4.8
        },
        {
            "location": "Queenstown",
            "date": "17-01-2024",
            "value": 78.5
        },
        {
            "location": "Queenstown",
            "date": "18-01-2024",
            "value": 185.9
        },
        {
            "location": "Queenstown",
            "date": "19-01-2024",
            "value": 192.7
        },
        {
            "location": "Queenstown",
            "date": "20-01-2024",
            "value": 151.3
        },
        {
            "location": "Queenstown",
            "date": "21-01-2024",
            "value": 92.1
        },
        {
            "location": "Queenstown",
            "date": "22-01-2024",
            "value": 5.6
        },
        {
            "location": "Queenstown",
            "date": "23-01-2024",
            "value": 127.0
        },
        {
            "location": "Queenstown",
            "date": "24-01-2024",
            "value": 69.8
        },
        {
            "location": "Queenstown",
            "date": "25-01-2024",
            "value": 67.8
        },
        {
            "location": "Queenstown",
            "date": "26-01-2024",
            "value": 112.0
        },
        {
            "location": "Queenstown",
            "date": "27-01-2024",
            "value": 74.3
        },
        {
            "location": "Queenstown",
            "date": "28-01-2024",
            "value": 198.8
        },
        {
            "location": "Queenstown",
            "date": "29-01-2024",
            "value": 183.0
        },
        {
            "location": "Queenstown",
            "date": "30-01-2024",
            "value": 72.2
        },
        {
            "location": "Queenstown",
            "date": "31-01-2024",
            "value": 59.7
        },
        {
            "location": "New Plymouth",
            "date": "01-01-2024",
            "value": 77.6
        },
        {
            "location": "New Plymouth",
            "date": "02-01-2024",
            "value": 196.4
        },
        {
            "location": "New Plymouth",
            "date": "03-01-2024",
            "value": 136.1
        },
        {
            "location": "New Plymouth",
            "date": "04-01-2024",
            "value": 64.9
        },
        {
            "location": "New Plymouth",
            "date": "05-01-2024",
            "value": 0.5
        },
        {
            "location": "New Plymouth",
            "date": "06-01-2024",
            "value": 77.6
        },
        {
            "location": "New Plymouth",
            "date": "07-01-2024",
            "value": 33.9
        },
        {
            "location": "New Plymouth",
            "date": "08-01-2024",
            "value": 146.9
        },
        {
            "location": "New Plymouth",
            "date": "09-01-2024",
            "value": 167.6
        },
        {
            "location": "New Plymouth",
            "date": "10-01-2024",
            "value": 199.1
        },
        {
            "location": "New Plymouth",
            "date": "11-01-2024",
            "value": 163.0
        },
        {
            "location": "New Plymouth",
            "date": "12-01-2024",
            "value": 14.0
        },
        {
            "location": "New Plymouth",
            "date": "13-01-2024",
            "value": 125.9
        },
        {
            "location": "New Plymouth",
            "date": "14-01-2024",
            "value": 36.4
        },
        {
            "location": "New Plymouth",
            "date": "15-01-2024",
            "value": 63.0
        },
        {
            "location": "New Plymouth",
            "date": "16-01-2024",
            "value": 88.1
        },
        {
            "location": "New Plymouth",
            "date": "17-01-2024",
            "value": 57.2
        },
        {
            "location": "New Plymouth",
            "date": "18-01-2024",
            "value": 89.9
        },
        {
            "location": "New Plymouth",
            "date": "19-01-2024",
            "value": 147.3
        },
        {
            "location": "New Plymouth",
            "date": "20-01-2024",
            "value": 145.9
        },
        {
            "location": "New Plymouth",
            "date": "21-01-2024",
            "value": 109.4
        },
        {
            "location": "New Plymouth",
            "date": "22-01-2024",
            "value": 18.7
        },
        {
            "location": "New Plymouth",
            "date": "23-01-2024",
            "value": 196.8
        },
        {
            "location": "New Plymouth",
            "date": "24-01-2024",
            "value": 21.1
        },
        {
            "location": "New Plymouth",
            "date": "25-01-2024",
            "value": 20.3
        },
        {
            "location": "New Plymouth",
            "date": "26-01-2024",
            "value": 35.5
        },
        {
            "location": "New Plymouth",
            "date": "27-01-2024",
            "value": 99.5
        },
        {
            "location": "New Plymouth",
            "date": "28-01-2024",
            "value": 83.1
        },
        {
            "location": "New Plymouth",
            "date": "29-01-2024",
            "value": 83.0
        },
        {
            "location": "New Plymouth",
            "date": "30-01-2024",
            "value": 56.1
        },
        {
            "location": "New Plymouth",
            "date": "31-01-2024",
            "value": 104.5
        },
        {
            "location": "Rotorua",
            "date": "01-01-2024",
            "value": 116.2
        },
        {
            "location": "Rotorua",
            "date": "02-01-2024",
            "value": 169.7
        },
        {
            "location": "Rotorua",
            "date": "03-01-2024",
            "value": 189.2
        },
        {
            "location": "Rotorua",
            "date": "04-01-2024",
            "value": 92.8
        },
        {
            "location": "Rotorua",
            "date": "05-01-2024",
            "value": 0.6
        },
        {
            "location": "Rotorua",
            "date": "06-01-2024",
            "value": 192.3
        },
        {
            "location": "Rotorua",
            "date": "07-01-2024",
            "value": 12.3
        },
        {
            "location": "Rotorua",
            "date": "08-01-2024",
            "value": 132.3
        },
        {
            "location": "Rotorua",
            "date": "09-01-2024",
            "value": 183.3
        },
        {
            "location": "Rotorua",
            "date": "10-01-2024",
            "value": 177.9
        },
        {
            "location": "Rotorua",
            "date": "11-01-2024",
            "value": 131.8
        },
        {
            "location": "Rotorua",
            "date": "12-01-2024",
            "value": 8.7
        },
        {
            "location": "Rotorua",
            "date": "13-01-2024",
            "value": 33.2
        },
        {
            "location": "Rotorua",
            "date": "14-01-2024",
            "value": 194.5
        },
        {
            "location": "Rotorua",
            "date": "15-01-2024",
            "value": 115.1
        },
        {
            "location": "Rotorua",
            "date": "16-01-2024",
            "value": 1.7
        },
        {
            "location": "Rotorua",
            "date": "17-01-2024",
            "value": 118.4
        },
        {
            "location": "Rotorua",
            "date": "18-01-2024",
            "value": 140.1
        },
        {
            "location": "Rotorua",
            "date": "19-01-2024",
            "value": 38.5
        },
        {
            "location": "Rotorua",
            "date": "20-01-2024",
            "value": 6.8
        },
        {
            "location": "Rotorua",
            "date": "21-01-2024",
            "value": 135.0
        },
        {
            "location": "Rotorua",
            "date": "22-01-2024",
            "value": 161.5
        },
        {
            "location": "Rotorua",
            "date": "23-01-2024",
            "value": 52.7
        },
        {
            "location": "Rotorua",
            "date": "24-01-2024",
            "value": 158.9
        },
        {
            "location": "Rotorua",
            "date": "25-01-2024",
            "value": 120.9
        },
        {
            "location": "Rotorua",
            "date": "26-01-2024",
            "value": 84.9
        },
        {
            "location": "Rotorua",
            "date": "27-01-2024",
            "value": 6.2
        },
        {
            "location": "Rotorua",
            "date": "28-01-2024",
            "value": 199.1
        },
        {
            "location": "Rotorua",
            "date": "29-01-2024",
            "value": 66.3
        },
        {
            "location": "Rotorua",
            "date": "30-01-2024",
            "value": 42.7
        },
        {
            "location": "Rotorua",
            "date": "31-01-2024",
            "value": 21.6
        },
        {
            "location": "Tauranga",
            "date": "01-01-2024",
            "value": 79.8
        },
        {
            "location": "Tauranga",
            "date": "02-01-2024",
            "value": 25.2
        },
        {
            "location": "Tauranga",
            "date": "03-01-2024",
            "value": 26.2
        },
        {
            "location": "Tauranga",
            "date": "04-01-2024",
            "value": 178.5
        },
        {
            "location": "Tauranga",
            "date": "05-01-2024",
            "value": 185.5
        },
        {
            "location": "Tauranga",
            "date": "06-01-2024",
            "value": 86.5
        },
        {
            "location": "Tauranga",
            "date": "07-01-2024",
            "value": 114.2
        },
        {
            "location": "Tauranga",
            "date": "08-01-2024",
            "value": 149.4
        },
        {
            "location": "Tauranga",
            "date": "09-01-2024",
            "value": 82.1
        },
        {
            "location": "Tauranga",
            "date": "10-01-2024",
            "value": 43.9
        },
        {
            "location": "Tauranga",
            "date": "11-01-2024",
            "value": 5.9
        },
        {
            "location": "Tauranga",
            "date": "12-01-2024",
            "value": 56.7
        },
        {
            "location": "Tauranga",
            "date": "13-01-2024",
            "value": 8.5
        },
        {
            "location": "Tauranga",
            "date": "14-01-2024",
            "value": 47.3
        },
        {
            "location": "Tauranga",
            "date": "15-01-2024",
            "value": 82.2
        },
        {
            "location": "Tauranga",
            "date": "16-01-2024",
            "value": 49.2
        },
        {
            "location": "Tauranga",
            "date": "17-01-2024",
            "value": 118.9
        },
        {
            "location": "Tauranga",
            "date": "18-01-2024",
            "value": 187.5
        },
        {
            "location": "Tauranga",
            "date": "19-01-2024",
            "value": 96.8
        },
        {
            "location": "Tauranga",
            "date": "20-01-2024",
            "value": 79.5
        },
        {
            "location": "Tauranga",
            "date": "21-01-2024",
            "value": 76.7
        },
        {
            "location": "Tauranga",
            "date": "22-01-2024",
            "value": 197.4
        },
        {
            "location": "Tauranga",
            "date": "23-01-2024",
            "value": 22.9
        },
        {
            "location": "Tauranga",
            "date": "24-01-2024",
            "value": 153.4
        },
        {
            "location": "Tauranga",
            "date": "25-01-2024",
            "value": 75.6
        },
        {
            "location": "Tauranga",
            "date": "26-01-2024",
            "value": 37.1
        },
        {
            "location": "Tauranga",
            "date": "27-01-2024",
            "value": 61.2
        },
        {
            "location": "Tauranga",
            "date": "28-01-2024",
            "value": 39.5
        },
        {
            "location": "Tauranga",
            "date": "29-01-2024",
            "value": 101.0
        },
        {
            "location": "Tauranga",
            "date": "30-01-2024",
            "value": 5.3
        },
        {
            "location": "Tauranga",
            "date": "31-01-2024",
            "value": 166.9
        },
        {
            "location": "Palmerston North",
            "date": "01-01-2024",
            "value": 156.2
        },
        {
            "location": "Palmerston North",
            "date": "02-01-2024",
            "value": 51.8
        },
        {
            "location": "Palmerston North",
            "date": "03-01-2024",
            "value": 50.6
        },
        {
            "location": "Palmerston North",
            "date": "04-01-2024",
            "value": 9.4
        },
        {
            "location": "Palmerston North",
            "date": "05-01-2024",
            "value": 57.4
        },
        {
            "location": "Palmerston North",
            "date": "06-01-2024",
            "value": 52.3
        },
        {
            "location": "Palmerston North",
            "date": "07-01-2024",
            "value": 73.8
        },
        {
            "location": "Palmerston North",
            "date": "08-01-2024",
            "value": 164.5
        },
        {
            "location": "Palmerston North",
            "date": "09-01-2024",
            "value": 87.0
        },
        {
            "location": "Palmerston North",
            "date": "10-01-2024",
            "value": 127.0
        },
        {
            "location": "Palmerston North",
            "date": "11-01-2024",
            "value": 159.7
        },
        {
            "location": "Palmerston North",
            "date": "12-01-2024",
            "value": 93.9
        },
        {
            "location": "Palmerston North",
            "date": "13-01-2024",
            "value": 199.0
        },
        {
            "location": "Palmerston North",
            "date": "14-01-2024",
            "value": 80.1
        },
        {
            "location": "Palmerston North",
            "date": "15-01-2024",
            "value": 40.8
        },
        {
            "location": "Palmerston North",
            "date": "16-01-2024",
            "value": 82.1
        },
        {
            "location": "Palmerston North",
            "date": "17-01-2024",
            "value": 132.7
        },
        {
            "location": "Palmerston North",
            "date": "18-01-2024",
            "value": 172.4
        },
        {
            "location": "Palmerston North",
            "date": "19-01-2024",
            "value": 128.0
        },
        {
            "location": "Palmerston North",
            "date": "20-01-2024",
            "value": 189.5
        },
        {
            "location": "Palmerston North",
            "date": "21-01-2024",
            "value": 191.2
        },
        {
            "location": "Palmerston North",
            "date": "22-01-2024",
            "value": 121.8
        },
        {
            "location": "Palmerston North",
            "date": "23-01-2024",
            "value": 25.0
        },
        {
            "location": "Palmerston North",
            "date": "24-01-2024",
            "value": 106.2
        },
        {
            "location": "Palmerston North",
            "date": "25-01-2024",
            "value": 199.3
        },
        {
            "location": "Palmerston North",
            "date": "26-01-2024",
            "value": 142.2
        },
        {
            "location": "Palmerston North",
            "date": "27-01-2024",
            "value": 37.5
        },
        {
            "location": "Palmerston North",
            "date": "28-01-2024",
            "value": 86.6
        },
        {
            "location": "Palmerston North",
            "date": "29-01-2024",
            "value": 25.8
        },
        {
            "location": "Palmerston North",
            "date": "30-01-2024",
            "value": 32.5
        },
        {
            "location": "Palmerston North",
            "date": "31-01-2024",
            "value": 19.4
        },
        {
            "location": "Gisborne",
            "date": "01-01-2024",
            "value": 145.3
        },
        {
            "location": "Gisborne",
            "date": "02-01-2024",
            "value": 100.5
        },
        {
            "location": "Gisborne",
            "date": "03-01-2024",
            "value": 175.5
        },
        {
            "location": "Gisborne",
            "date": "04-01-2024",
            "value": 199.3
        },
        {
            "location": "Gisborne",
            "date": "05-01-2024",
            "value": 123.7
        },
        {
            "location": "Gisborne",
            "date": "06-01-2024",
            "value": 138.6
        },
        {
            "location": "Gisborne",
            "date": "07-01-2024",
            "value": 66.4
        },
        {
            "location": "Gisborne",
            "date": "08-01-2024",
            "value": 43.0
        },
        {
            "location": "Gisborne",
            "date": "09-01-2024",
            "value": 91.6
        },
        {
            "location": "Gisborne",
            "date": "10-01-2024",
            "value": 58.4
        },
        {
            "location": "Gisborne",
            "date": "11-01-2024",
            "value": 123.1
        },
        {
            "location": "Gisborne",
            "date": "12-01-2024",
            "value": 16.9
        },
        {
            "location": "Gisborne",
            "date": "13-01-2024",
            "value": 120.7
        },
        {
            "location": "Gisborne",
            "date": "14-01-2024",
            "value": 39.7
        },
        {
            "location": "Gisborne",
            "date": "15-01-2024",
            "value": 194.1
        },
        {
            "location": "Gisborne",
            "date": "16-01-2024",
            "value": 49.9
        },
        {
            "location": "Gisborne",
            "date": "17-01-2024",
            "value": 56.2
        },
        {
            "location": "Gisborne",
            "date": "18-01-2024",
            "value": 169.2
        },
        {
            "location": "Gisborne",
            "date": "19-01-2024",
            "value": 145.1
        },
        {
            "location": "Gisborne",
            "date": "20-01-2024",
            "value": 99.0
        },
        {
            "location": "Gisborne",
            "date": "21-01-2024",
            "value": 182.8
        },
        {
            "location": "Gisborne",
            "date": "22-01-2024",
            "value": 41.3
        },
        {
            "location": "Gisborne",
            "date": "23-01-2024",
            "value": 173.7
        },
        {
            "location": "Gisborne",
            "date": "24-01-2024",
            "value": 34.3
        },
        {
            "location": "Gisborne",
            "date": "25-01-2024",
            "value": 59.1
        },
        {
            "location": "Gisborne",
            "date": "26-01-2024",
            "value": 60.5
        },
        {
            "location": "Gisborne",
            "date": "27-01-2024",
            "value": 136.6
        },
        {
            "location": "Gisborne",
            "date": "28-01-2024",
            "value": 147.7
        },
        {
            "location": "Gisborne",
            "date": "29-01-2024",
            "value": 8.1
        },
        {
            "location": "Gisborne",
            "date": "30-01-2024",
            "value": 81.8
        },
        {
            "location": "Gisborne",
            "date": "31-01-2024",
            "value": 139.9
        }
    ],
    xField: 'date',
    yField: 'value',

    scale: {
        y: {
            type: 'linear',
            domain: [50, 300]
        }
    },
};


return (
    <>
        <div>
            <Column {...config} />
        </div>
    </>
)

};

export default TempContentComponent;

© 版本信息

  • ant-design-charts 版本: "@ant-design/charts": "^2.2.6",
  • 浏览器环境: Chrome
  • 开发环境 mac OS Version 14.6.1 (23G93)

🚑 其他信息 [如截图等其他信息可以贴在这里]

@remyyang717 remyyang717 changed the title 🐛[BUG] 🐛[BUG]当使用scale>y>domain的时候,图表会出现偏移 Jan 3, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant