From c151bf3267906adc9a3d2e9d18678e29fae744f2 Mon Sep 17 00:00:00 2001 From: Andrew Harvey Date: Thu, 23 Jan 2025 21:19:03 +1100 Subject: [PATCH] update mapbox gl draw example (#5393) * update mapbox-gl-draw example description to match the example provided * update mapbox-gl-draw version in example since it exposes the canvas class which is necessary as it was renamed in maplibre-gl-js --- test/examples/mapbox-gl-draw.html | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/test/examples/mapbox-gl-draw.html b/test/examples/mapbox-gl-draw.html index 9d0b0fa813..194bb88075 100644 --- a/test/examples/mapbox-gl-draw.html +++ b/test/examples/mapbox-gl-draw.html @@ -1,8 +1,8 @@ - Draw polygon with maplibre-gl-draw - + Draw polygon with mapbox-gl-draw + @@ -31,10 +31,10 @@ font-size: 13px; } - +
@@ -47,9 +47,11 @@ import * as turf from 'https://esm.sh/@turf/turf@7.1.0'; + MapboxDraw.constants.classes.CANVAS = 'maplibregl-canvas'; MapboxDraw.constants.classes.CONTROL_BASE = 'maplibregl-ctrl'; MapboxDraw.constants.classes.CONTROL_PREFIX = 'maplibregl-ctrl-'; MapboxDraw.constants.classes.CONTROL_GROUP = 'maplibregl-ctrl-group'; + MapboxDraw.constants.classes.ATTRIBUTION = 'maplibregl-ctrl-attrib'; const map = new maplibregl.Map({ container: 'map', // container id