new FeaturePopup(options)
A class to display popups on a map that display feature data
Parameters:
| Name | Type | Description |
|---|---|---|
options |
module:nyc/FeaturePopup~FeaturePopup.Options | Constructor options |
- Source:
Extends
Members
-
margin :Array.<number>
-
Type:
- Array.<number>
- Inherited From:
- Source:
Methods
-
addLayer(layer)
-
Add a layer
Parameters:
Name Type Description layerol.layer.Vector The layer to add
- Source:
-
addLayers(layers)
-
Add a layer
Parameters:
Name Type Description layersArray.<ol.layer.Vector> The layers to add
- Source:
-
cssClass(css)
-
Add a css class to the popup content
Parameters:
Name Type Description cssstring A css class
- Inherited From:
- Source:
-
hide()
-
Hide the popup
- Inherited From:
- Source:
-
<protected> mapClick(event)
-
Parameters:
Name Type Description eventol.MapBrowserEvent - Source:
-
show(options)
-
Show the popup
Parameters:
Name Type Description optionsmodule:nyc/ol/Popup~Popup.ShowOptions Overlay options
- Inherited From:
- Source:
-
showFeature(feature [, coordinate])
-
Show the popup
Parameters:
Name Type Argument Description featureol.Feature The feature
coordinateol.Coordinate <optional>
The coordinate
- Source:
Type Definitions
-
Options
-
Constructor option for module:nyc/FeaturePopup~FeaturePopup
Type:
- Object
- Source:
Properties:
Name Type Description mapol.Map The map
layersArray.<ol.layer.Vector> The layers for which the popup will report feature properties