-
Name Type Description optionsOptions.
Name Type Description svgPathstring | undefined String with SVG path.
https://developer.mozilla.org/en-US/docs/Web/SVG/Element/path. Programs as Adobe Illustrator can generate icons done with SVG.
Default:M19 13h-6v6h-2v-6H5v-2h6V5h2v6h6v2z.
If you need help, you can send us which icon you want to convert to SVG.clickFunctionfunction | undefined Function to execute on click the control.
namestring | undefined Control name. You can get this control throught
getControlByNamemethod fromcercalia.Mapclass.titlestring | undefined Tooltip. Default '' (empty).
twoStateboolean | undefined Two state button if
true. Defaultfalse. In callback function you can get its state usingisEnabled()function.
Extends
Methods
-
Disable control
-
Enable control
-
Returns
cercaliaMap objectReturns:
Cercalia map.
-
Get class name.
Returns:
Class name.
-
Get control HTML Element
Returns:
HTML Element
-
Get control id.
Returns:
Id.
-
Returns
mapboxglMap object -
Get control name. Null if control has not defined name.
Returns:
Class name.
-
Hide control.
-
Return if control is enabled. Only works when
twoStateoption istrue.Returns:
Returntrueif button is enabled.
-
Show control.