dojo.require("esri.dijit.geoenrichment.InfographicsCarousel");
Description
(Added at v3.6)
Displays a set of
Infographic dijits in a carousel.
Note that a css stylesheet needs to be included:
<link rel="stylesheet" href="//js.arcgis.com/3.11/esri/dijit/geoenrichment/themes/common/main.css">
Samples
Search for
samples that use this class.
Constructors
CSS
esri/dijit/geoenrichment/InfographicsCarousel | Download source
Properties
Methods
startup() | None | Finalizes the creation of this dijit. |
Events
[ On Style Events | Connect Style Event ]
All On Style event listeners receive a single event object. Additionally, the event object also contains a 'target' property whose value is the object which fired the event.
Events
data-error | {
error: <Object >
} | Fires if an error occurs in retrieving data for the study area. |
data-load | | Fires when loading data for the study area. |
data-ready | {
provider: <Object >
} | Fires when data for the study area is ready. |
resize | {
size: <Number[] >
} | Fires when the InfographicsCarousel is resized. |
Constructor Details
Creates a new InfographicsCarousel
dijit using the given DOM node.
Parameters:
<Object > params |
Required |
Various optional parameters that can be used to configure the dijit. All properties can be passed into the constructor as options. studyArea is required when constructing an InfographicsCarousel . |
<Node | String > srcNodeRef |
Required |
Reference or id of an HTML element where the Directions widget should be rendered. |
Sample:
var infographics = new esri.dijit.geoenrichment.InfographicsCarousel({
returnGeometry: true,
studyArea: new esri.tasks.geoenrichment.GeometryStudyArea({
geometry: new esri.geometry.Point(-120.44,34.95)
})
}, "infographics");
infographics.startup();
Property Details
If true, the Infographic
will be displayed in its expanded state. The default value is true.
Known values: true | false
Default value: true
Describes the options used to configure the contents of the carousel.
When true, output geometry will be available as the geometry
property in the returned object of the "data-ready" event handler. If you do not intend to add the output geometry to the map, set it to false to improve performance.
Known values: true | false
Default value: false
The index of the currently selected InfoGraphic
in this InfographicsCarousel
.
The study area for this InfographicsCarousel
. Required when constructing an InfographicsCarousel
.
The name of the study area to be shown in this InfographicsCarousel
.
Method Details
Finalizes the creation of this dijit. This method should be called after the constructor for this dijit is called and before letting the users interact with it.
Event Details
[ On Style Events | Connect Style Event ]
Fires if an error occurs in retrieving data for the study area. Should be used in favor of onDataRequest.
Event Object Properties:
<Object > error |
The error message returned by the GeoEnrichment service. |
Fires when loading data for the study area. Should be used in favor of onDataLoad.
Fires when data for the study area is ready. Should be used in favor of onDataReady.
Event Object Properties:
<Object > provider |
A provider object containing GeoEnrichment results. When returnGeometry is set to true, you may use the provider.getGeometry() to get the returned geometry. |
Sample: require([
"esri/graphic", "esri/symbols/SimpleFillSymbol", ...
], function(Graphic, SimpleFillSymbol, ... ){
infographics.on("data-ready", function (evt) {
map.graphics.add(new Graphic(evt.provider.geometry, new SimpleFillSymbol()));
});
});
Fires when the InfographicsCarousel
is resized. Should be used in favor of onResize.
Event Object Properties:
<Number[] > size |
The size of the InfographicsCarousel .[460,106] |
Fires if an error occurs in retrieving data for the study area.
Event Object Properties:
<Object > error |
The error message returned by the GeoEnrichment service. |
Fires when loading data for the study area.
Fires when data for the study area is ready.
Event Object Properties:
<Object > provider |
A provider object containing GeoEnrichment results. When returnGeometry is set to true, you may use the provider.getGeometry() to get the returned geometry. |
Fires when the InfoGraphicsCarousel
is resized.
Event Object Properties:
<Number[] > size |
The size of the InfographicsCarousel .[460,106] |