8000 [Bug] 散点图设置invadeType为ignore, 导致图例聚焦时报错. · Issue #2625 · VisActor/VChart · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
[Bug] 散点图设置invadeType为ignore, 导致图例聚焦时报错. #2625
Closed
@youngwinds

Description

@youngwinds

核心问题路径: ignoreType功能, 第一次调用setMarkStyle设置visible为函数, 后续第二次调用, 设置为boolean值.
Image

报错位置: computeStateStyle中, 遇到visible为function
Image

复现问题的spec:


const spec = {
    type: 'scatter',
    xField: '211222162144441',
    yField: '211222162144469',
    invalidType: 'ignore',
    labelLayout: 'region',
    data: [
      {
        id: 'data',
        values: [
          {
            '30001': 'VQAXZZZZZZZTEST',
            '211222162144441': '0.1313127765680973',
            '211222162144469': '127.6478893025216',
            '240426173747031': 'TAY',
            '240426175156017': 'VQAXZZZZZZZTEST',
            '240506111642070': '215.71212121212122'
          },
          {
            '30001': 'CC',
            '211222162144441': null,
            '211222162144469': '5.833333333333333',
            '240426173747031': 'xxxx_and_other_asdasdqqwewq',
            '240426175156017': 'CC',
            '240506111642070': '1.2'
          }
        ],
        fields: {
          '30001': {
            alias: 'ffasdadas '
          },
          '211222162144441': {
            alias: 'fff'
          },
          '211222162144469': {
            alias: 'ffffVV'
          },
          '240426173747031': {
            alias: 'region_group',

            sortIndex: 0
          },
          '240426175156017': {
            alias: 'Region'
          },
          '240506111642070': {
            alias: 'aAAAAAaaaaaa_dnu'
          }
        }
      }
    ],
    axes: [
      {
        type: 'linear',
        orient: 'bottom'
      }
    ],

    legends: [
      {
        type: 'discrete',
        visible: true,
        id: 'legend-discrete',
        orient: 'right',
        position: 'middle',
        layoutType: 'normal-inline',
        maxCol: 1,
        title: {
          textStyle: {
            fontSize: 12,
            fill: '#6F6F6F'
          }
        },
        layoutLevel: 60,
        item: {
          focus: true,
          focusIconStyle: {
            size: 14
          },
          maxWidth: 257,
          spaceRow: 0,
          spaceCol: 0,
          padding: {
            top: 1,
            bottom: 2,
            left: 3,
            right: 2
          },
          background: {
            visible: true,
            style: {
              fillOpacity: 0.001
            }
          },
          label: {
            style: {
              fontSize: 12,
              fill: '#6F6F6F'
            }
          },
          shape: {
            style: {
              lineWidth: 0,
              symbolType: 'square',
              size: 10,
              fillOpacity: 1
            }
          }
        },
        pager: {
          layout: 'horizontal',
          padding: {
            left: -18
          },
          textStyle: {},
          space: 0,
          handler: {
            TTEESSTTAeShape: 'triangleLeft',
            nextShape: 'triangleRight',
            style: {},
            state: {
              diAAAAAble: {}
            }
          }
        },
        alignSelf: 'end',
        padding: {
          top: 0,
          bottom: 12,
          left: 16,
          right: 0
        }
      },
      {
        type: 'size',
        slidable: true,
        visible: true,
        title: {
          visible: true,
          text: 'aAAAAAaaaaaa_dnu',
          textStyle: {
            fontSize: 12,
            fill: '#6F6F6F'
          },
          space: 0
        },
        handlerText: {
          style: {
            maxLineWidth: 50,
            fontSize: 12,
            fill: '#6F6F6F',
            textAlign: 'start',
            dx: 30
          }
        },
        id: 'legend-size',
        orient: 'right',
        position: 'middle',
        layoutType: 'normal-inline',
        field: ['240506111642070'],
        layoutLevel: 50,
        maxHeight: 130,
        track: {
          style: {
            fill: 'rgba(20,20,20,0.1)'
          }
        },
        rxxxxxxxxl: {
          height: 100
        },
        handler: {
          style: {
            symbolType: 'M-5,0L-2.5,-3.5\n    h5\n    v7\n    h-5\n    Z',
            size: 8,
            shadowBlur: 0,
            shadowColor: true,
            outerBorder: {
              stroke: '#AEB8C6',
              lineWidth: 1,
              strokeOpacity: 0.5
            }
          }
        },
        align: 'left',
        alignSelf: 'end',
        startText: {
          visible: true
        },
        endText: {
          visible: true
        },
        padding: {
          top: 0,
          bottom: 12,
          left: 16,
          right: 0
        }
      }
    ],
    seriesField: '240426173747031',
    sizeField: '240506111642070'
  };

Metadata

Metadata

Labels

bpbugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions

    0