ui.Map
A Google map.
Usage | Returns | ui.Map(center, onClick, style) | ui.Map |
Argument | Type | Details | center | Object, optional | An object containing the latitude ('lat'), longitude ('lon') and optionally the zoom level ('zoom') for the map. |
onClick | Function, optional | A callback fired when the map is clicked. The callback is passed an object containing the coordinates of the clicked point on the map (with keys lon and lat) and the map widget itself. |
style | Object, optional | An object of allowed CSS styles with their values to be set for this map. See style() documentation. |
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2023-10-06 UTC.
[null,null,["Last updated 2023-10-06 UTC."],[[["The `ui.Map` function creates an interactive map widget within your Earth Engine app, accepting optional arguments to define its center, click behavior, and visual style."],["The map's initial center is adjustable by specifying a `center` object containing latitude (`lat`), longitude (`lon`), and optionally zoom (`zoom`)."],["Clicking the map triggers an optional `onClick` callback function, providing coordinates (`lon`, `lat`) of the clicked point and the map widget for custom interactions."],["The map's appearance can be customized using a `style` object with valid CSS properties, analogous to the `style()` function's capabilities."]]],[]]