create Custom Tooltip
Create a tooltip with no default styling that the MapView will attempt to position in 3D space. The tooltip will be anchored to a specified node or coordinate in one of eight anchor orientations.
Unlike createTooltip, a custom tooltip is rendered without any additional wrappers, leaving styling entirely up to the external developer. The top-most element will be injected with a class in the form of .tooltip--anchor-{type}
that indicates the current anchor type.
Return
Parameters
The MPIMap.MPICoordinate on which the tooltip will be displayed. Represents the target of the tooltip.
The HTML content to be displayed within the tooltip. Allows for rich formatted text and images.
A CSS selector string that allows the SDK to target the tooltip. This is required because we do not inject any default styling.
Configuration options for the tooltip, defined by MPIOptions.Tooltip.
A callback function that is called after the tooltip is created. It receives the tooltip's ID as a parameter, which can be used for further reference. If the tooltip could not be created, null
is passed to the callback.
Create a tooltip with no default styling that the MapView will attempt to position in 3D space. The tooltip will be anchored to a specified node or coordinate in one of eight anchor orientations.
Unlike createTooltip, a custom tooltip is rendered without any additional wrappers, leaving styling entirely up to the external developer. The top-most element will be injected with a class in the form of .tooltip--anchor-{type}
that indicates the current anchor type.
Return
Parameters
The MPINavigatable.MPINode on which the tooltip will be displayed. Represents the target of the tooltip.
The HTML content to be displayed within the tooltip. Allows for rich formatted text and images.
A CSS selector string that allows the SDK to target the tooltip. This is required because we do not inject any default styling.
Configuration options for the tooltip, defined by MPIOptions.Tooltip.
A callback function that is called after the tooltip is created. It receives the tooltip's ID as a parameter, which can be used for further reference. If the tooltip could not be created, null
is passed to the callback.