mirror of
https://github.com/status-im/codimd.git
synced 2025-02-18 23:08:48 +00:00
Merge pull request #1437 from hackmdio/fix/geo-map-not-support-minus
Fix west longitude and south latitude not parsed correctly in geo map
This commit is contained in:
commit
0c919381c3
@ -450,7 +450,7 @@ export function finishView (view) {
|
|||||||
|
|
||||||
try {
|
try {
|
||||||
let position, zoom
|
let position, zoom
|
||||||
if (content.match(/^[\d.,\s]+$/)) {
|
if (content.match(/^[-\d.,\s]+$/)) {
|
||||||
const [lng, lat, zoo] = content.split(',').map(parseFloat)
|
const [lng, lat, zoo] = content.split(',').map(parseFloat)
|
||||||
zoom = zoo
|
zoom = zoo
|
||||||
position = [lat, lng]
|
position = [lat, lng]
|
||||||
|
Loading…
x
Reference in New Issue
Block a user