mirror of
https://github.com/cds-astro/aladin-lite.git
synced 2025-12-12 07:40:26 -08:00
Fix: fix link on feature name for planetary pointer, when body is earth
This commit is contained in:
@@ -104,16 +104,17 @@ export let PlanetaryFeaturesPointer = (function() {
|
||||
const featureFieldIdx = fields.findIndex((element) => element.includes('feature_name'));
|
||||
const featureName = values[featureFieldIdx];
|
||||
const featureId = values[fields.indexOf('feature_id')];
|
||||
const title = '<div class="aladin-sp-title"><a target="_blank" href="https://planetarynames.wr.usgs.gov/Feature/' + featureId + '">' + featureName + '</a></div>';
|
||||
const featureType = values[fields.indexOf('feature_type')]
|
||||
let content = '<div class="aladin-sp-content">' + ' ' + '</div>';
|
||||
content += '<em>Type: </em>' + featureType + '<br><br>';
|
||||
let moreInfoURL = 'https://planetarynames.wr.usgs.gov/Feature/' + featureId;
|
||||
if (body === 'earth') {
|
||||
const placeId = values[fields.indexOf('place_id')];
|
||||
moreInfoURL = 'https://nominatim.openstreetmap.org/ui/details.html?place_id=' + placeId;
|
||||
}
|
||||
|
||||
const title = '<div class="aladin-sp-title"><a target="_blank" href=" ' + moreInfoURL + '">' + featureName + '</a></div>';
|
||||
const featureType = values[fields.indexOf('feature_type')]
|
||||
let content = '<div class="aladin-sp-content">' + ' ' + '</div>';
|
||||
content += '<em>Type: </em>' + featureType + '<br><br>';
|
||||
|
||||
content += '<a target="_blank" href="' + moreInfoURL + '">More information</a>';
|
||||
|
||||
let lon = parseFloat(values[lonFieldIdx]);
|
||||
|
||||
Reference in New Issue
Block a user