mirror of
https://github.com/gpxstudio/gpx.studio.git
synced 2025-08-30 23:30:04 +00:00
fix xml output for osm attributes
This commit is contained in:
@@ -155,7 +155,7 @@
|
||||
let surface = point.extensions.surface ? point.extensions.surface : 'unknown';
|
||||
let highway = point.extensions.highway ? point.extensions.highway : 'unknown';
|
||||
let sacScale = point.extensions.sac_scale;
|
||||
let mtbScale = point.extensions['mtb:scale'];
|
||||
let mtbScale = point.extensions.mtb_scale;
|
||||
|
||||
let labels = [
|
||||
` ${$_('quantities.distance')}: ${getDistanceWithUnits(point.x, false)}`,
|
||||
@@ -455,7 +455,7 @@
|
||||
return getHighwayColor(
|
||||
context.p0.raw.extensions.highway,
|
||||
context.p0.raw.extensions.sac_scale,
|
||||
context.p0.raw.extensions['mtb:scale']
|
||||
context.p0.raw.extensions.mtb_scale
|
||||
);
|
||||
}
|
||||
|
||||
|
@@ -96,8 +96,9 @@ function getTags(message: string): { [key: string]: string } {
|
||||
const fields = message.split(" ");
|
||||
let tags: { [key: string]: string } = {};
|
||||
for (let i = 0; i < fields.length; i++) {
|
||||
let tag = fields[i].split("=");
|
||||
tags[tag[0]] = tag[1];
|
||||
let [key, value] = fields[i].split("=");
|
||||
key = key.replace(/:/g, '_');
|
||||
tags[key] = value;
|
||||
}
|
||||
return tags;
|
||||
}
|
||||
|
Reference in New Issue
Block a user