shapeMouseLeave

Fired when the mouse leaves a shape.

Important This event will fire reliably only for shapes that have set fill color. The opacity can still be set to 0 so the shapes appear to have no fill.

Event Data

e.layer kendo.dataviz.map.layer.Shape

The parent layer instance.

e.shape kendo.drawing.Element

The the shape instance.

e.sender kendo.dataviz.ui.Map

The source widget instance.

e.originalEvent Object

The source jQuery event instance

Example - bind to the map shapeMouseLeave event on initialization

<div id="map"></div>
<script>
    $("#map").kendoMap({
        zoom: 3,
        center: [0, 0],
        layers: [{
          type: "shape",
          dataSource: {
            type: "geojson",
            data: [{
              "type": "Polygon",
              "coordinates": [
                [[0, 10], [0, 20], [10, 20], [10, 10], [0, 10]]
              ]
            }, {
              "type": "Polygon",
              "coordinates": [
                [[0, 0], [0, 10], [10, 10], [10, 0], [0,0]]
              ]
            }]
          },
          style: {
            fill: {
              color: "#aaa"
            }
          }
        }],
        shapeMouseLeave: function() {
/* The result can be observed in the DevTools(F12) console of the browser. */
            console.log("shape mouseleave");
        }
    });
</script>

Example - bind to the map shapeMouseLeave event after initialization

<div id="map"></div>
<script>
    $("#map").kendoMap({
        zoom: 3,
        center: [0, 0],
        layers: [{
          type: "shape",
          dataSource: {
            type: "geojson",
            data: [{
              "type": "Polygon",
              "coordinates": [
                [[0, 10], [0, 20], [10, 20], [10, 10], [0, 10]]
              ]
            }, {
              "type": "Polygon",
              "coordinates": [
                [[0, 0], [0, 10], [10, 10], [10, 0], [0,0]]
              ]
            }]
          },
          style: {
            fill: {
              color: "#aaa"
            }
          }
        }]
    });

    var map = $("#map").data("kendoMap");
    map.bind("shapeMouseLeave", function(e) {
/* The result can be observed in the DevTools(F12) console of the browser. */
        console.log("shape mouseleave");
    });
</script>
In this article