bluehalo / ngx-leaflet-draw

MIT License
88 stars 29 forks source link

How to enable white square on polygon vertexes? #69

Closed maihannijat closed 5 years ago

maihannijat commented 5 years ago

I am implemented the latest package on Angular 7 project but I do not see white squares on the vertexes of polygons (on start and end paths). I could not find any options to set it or style it through CSS.

The demo has enable it by default for all shapes: http://leaflet.github.io/Leaflet.draw/docs/examples/full.html

maihannijat commented 5 years ago
/deep/ .vertex {
  width: 20px;
  height: 20px;
  background: white;
  border: 1px solid black;
}

And the options:

drawOptions = {
  position: 'topright',
  draw: {
    marker: false,
    polyline: false,
    polygon: {
      icon: new L.DivIcon({
        className: 'vertex',
      }),
    },
    circle: false,
    circlemarker: false,
    rectangle: false,
  },
};