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

[Feature] can we draw an area based on the points of a serie type "lines" #19706

Open
krabouilleur opened this issue Mar 11, 2024 · 1 comment
Labels
en This issue is in English new-feature pending We are not sure about whether this is a bug/new feature.

Comments

@krabouilleur
Copy link

krabouilleur commented Mar 11, 2024

What problem does this feature solve?

Is there a way to fill the area between each points of a serie type "lines" ?

for exemple :
image

example with code:
https://echarts.apache.org/examples/en/editor.html?c=geo-svg-lines&code=CQOg5gpgLgFAUAAgQJQPKoCoH0AKBBDACQQGoEByAegBMBDKWy2gZ2eksgHtKBZWgY1TUATgFcAtgFoAMgDUArJIBmAG06dhABxW0AdpIDuEAEYhmANzDkANIgRLRu_lACWnXQhgWwASgQBvOyQIfgALWmEoZhBhCDAXZigIYT5NGHI-QREJGQVlNQ1tPUMTGwCEbwAuCssEAF8fAG4ghE5NV3cEAF4AlqQuasCkYeHxWk1qjIEhMSk5RVV1LR19I2MbPuHhTlpxaqgxCE262xGkNmEXCGZqgG1NpCGzkd1diEnkTlEkjeeRqAAnpp3hQVC5dNdfn8kPwltRwfQIABlAGJCB7ChcKHQrgASV01AgAA9qgAGU7QhDozThZgJQYPM46YwQFQMylnZihTgGapKWgqNiMkZ1YX1CnQzScFQAsEQ_aHCV_OXIwEqEFPDkGFzUKCharyMUnMV0Bh3MWPC3DWEaag3BD3DnPW4ARlJ5IQABZ3QBdJVOh0AZnd1i9vv9TtuwY9ADZfVakD6raKOUnoSmzmnhnVmiNxACAMLhSJmaCodpuXQwNodXRNOyippAA

$.get(
  ROOT_PATH + '/data/asset/geo/MacOdrum-LV5-floorplan-web.svg',
  function (svg) {
    echarts.registerMap('MacOdrum-LV5-floorplan-web', { svg: svg });
    option = {
      geo: {
        map: 'MacOdrum-LV5-floorplan-web',
        roam: true
      },
      series: [
        {
          name: 'Route',
          type: 'lines',
          coordinateSystem: 'geo',
          geoIndex: 0,
          emphasis: {
            label: {
              show: false
            }
          },
          polyline: true,
          lineStyle: {
            width: 5,
          },
          data: [
            {
              coords: [
                [100, 400],
                [300, 400],
                [300, 600],
              ]
            }
          ]
        }
      ]
    };
    myChart.setOption(option);
  }
);

What does the proposed API look like?

is there a "areaBackground" or a boolean to activate it ?

@echarts-bot echarts-bot bot added en This issue is in English pending We are not sure about whether this is a bug/new feature. labels Mar 11, 2024
@helgasoft
Copy link

please take a look at custom.polygon, it has color fill

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
en This issue is in English new-feature pending We are not sure about whether this is a bug/new feature.
Projects
None yet
Development

No branches or pull requests

2 participants