[BUGFIX] Allow negative coordinates

The world is more than just the part east of the prime meridian and
north of the equator 😜

This allows deeplinks to have negative coordinates. Also fixes the
coordinate picker when selecting coordinates with negative values.

Signed-off-by: Felix Kaechele <felix@kaechele.ca>
This commit is contained in:
Felix Kaechele 2018-02-11 12:59:37 +01:00 committed by Xaver Maierhofer
parent 9212b0e427
commit 76fb09326e
1 changed files with 1 additions and 1 deletions

View File

@ -85,7 +85,7 @@ define(['Navigo'], function (Navigo) {
var router = new Navigo(null, true);
router
.on(/^\/?#?\/([\w]{2})?\/?(map|graph)?\/?([a-f\d]{12})?([a-f\d\-]{25})?\/?(?:(\d+)\/([\d.]+)\/([\d.]+))?$/, customRoute)
.on(/^\/?#?\/([\w]{2})?\/?(map|graph)?\/?([a-f\d]{12})?([a-f\d\-]{25})?\/?(?:(\d+)\/(-?[\d.]+)\/(-?[\d.]+))?$/, customRoute)
.on({
'*': function () {
router.fullUrl();