横向刻度尺完整配置

{
    "backgroundColor": "#fff",
    "color": [
        "#88AAFF",
        "#9AE9A1",
        "#6FD4D6",
        "#F5D45F",
        "#F4928B",
        "#DAA78E",
        "#FB7293",
        "#E062AE",
        "#E690D1",
        "#E7BCF3",
        "#9D96F5",
        "#8378EA"
    ],
    "title": {
        "show": true,
        "text": "横向刻度尺",
        "textStyle": {
            "fontSize": 14,
            "fontFamily": "Microsoft YaHei,PingFang SC Regular",
            "fontWeight": "800",
            "color": "#666"
        },
        "left": "left",
        "top": "top"
    },
    "tooltip": {
        "show": true,
        "textStyle": {
            "fontSize": 12,
            "color": "#666"
        },
        "confine": true,
        "backgroundColor": "#fff",
        "borderColor": "#fff",
        "triggerOn": "mousemove"
    },
    "grid": {
        "top": 60,
        "left": 20,
        "right": 100,
        "bottom": 0
    },
    "splitLine": {
        "show": true,
        "color": "#ccc",
        "length": 12
    },
    "axisTick": {
        "length": 8
    },
    "axisLabel": {
        "show": true,
        "distance": 15,
        "fontSize": 12
    },
    "markPoint": {
        "color": "#fff",
        "symbolSize": 60,
        "fontSize": 16,
        "min": false,
        "max": false
    },
    "xAxis": [
        {
            "show": true,
            "gridIndex": 0,
            "offset": 0,
            "max": 124,
            "position": "top",
            "axisLine": {
                "show": true,
                "margin": 8,
                "lineStyle": {
                    "textAlign": "left",
                    "color": "#cccccc"
                }
            },
            "splitLine": {
                "show": false
            },
            "minorTick": {
                "show": true,
                "length": -8
            },
            "axisTick": {
                "show": true,
                "inside": true,
                "length": -12
            },
            "axisLabel": {
                "show": true,
                "margin": 15,
                "textStyle": {
                    "fontSize": 12,
                    "color": "#666"
                }
            }
        }
    ],
    "yAxis": [
        {
            "type": "category",
            "gridIndex": 0,
            "axisPointer": {
                "type": "false"
            },
            "show": false
        }
    ],
    "series": [
        {
            "data": [
                {
                    "value": 124,
                    "name": "量程"
                }
            ],
            "type": "bar",
            "barGap": "-100%",
            "barWidth": 15,
            "z": 1,
            "itemStyle": {
                "normal": {
                    "color": {
                        "x": "0",
                        "y": "0",
                        "x2": "1",
                        "y2": "0",
                        "type": "linear",
                        "global": false,
                        "colorStops": [
                            {
                                "offset": 0,
                                "color": "rgba(154,233,161,1)"
                            },
                            {
                                "offset": 1,
                                "color": "rgba(154,233,161,1)"
                            }
                        ]
                    },
                    "barBorderRadius": [
                        50,
                        50,
                        50,
                        50
                    ]
                }
            },
            "label": {
                "show": false,
                "fontSize": 12,
                "lineHeight": 16,
                "position": "right",
                "textStyle": {
                    "color": "#333333"
                }
            }
        },
        {
            "data": [
                {
                    "value": 82,
                    "name": "产线3"
                }
            ],
            "type": "bar",
            "barGap": "-100%",
            "barWidth": 15,
            "itemStyle": {
                "normal": {
                    "color": {
                        "x": "0",
                        "y": "0",
                        "x2": "1",
                        "y2": "0",
                        "type": "linear",
                        "global": false,
                        "colorStops": [
                            {
                                "offset": 0,
                                "color": "rgba(136,170,255,1)"
                            },
                            {
                                "offset": 1,
                                "color": "rgba(136,170,255,1)"
                            }
                        ]
                    },
                    "barBorderRadius": [
                        50,
                        50,
                        50,
                        50
                    ]
                }
            }
        }
    ]
}
©著作权归作者所有,转载或内容合作请联系作者
平台声明:文章内容(如有图片或视频亦包括在内)由作者上传并发布,文章内容仅代表作者本人观点,简书系信息发布平台,仅提供信息存储服务。

推荐阅读更多精彩内容