Improve measure example ux
- Pass click events on measure tooltips through to the map - Put the tooltip for the currently drawn geometry on top - Disable text selection in the tooltips so clicking to draw does not select
This commit is contained in:
@@ -7,6 +7,8 @@
|
||||
opacity: 0.7;
|
||||
white-space: nowrap;
|
||||
font-size: 12px;
|
||||
cursor: default;
|
||||
user-select: none;
|
||||
}
|
||||
.ol-tooltip-measure {
|
||||
opacity: 1;
|
||||
|
||||
@@ -248,6 +248,8 @@ function createMeasureTooltip() {
|
||||
element: measureTooltipElement,
|
||||
offset: [0, -15],
|
||||
positioning: 'bottom-center',
|
||||
stopEvent: false,
|
||||
insertFirst: false,
|
||||
});
|
||||
map.addOverlay(measureTooltip);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user