1
0
Fork 0
mirror of https://github.com/jellyfin/jellyfin-web synced 2025-03-30 19:56:21 +00:00

Update index.js

This commit is contained in:
Niels van Velzen 2021-01-05 15:40:07 +01:00 committed by GitHub
parent 4e5c8cd918
commit 99d584b21b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -697,12 +697,12 @@ function reloadFromItem(instance, page, params, item, user) {
const itemBirthLocation = page.querySelector('#itemBirthLocation');
if (item.Type == 'Person' && item.ProductionLocations && item.ProductionLocations.length) {
let gmap = item.ProductionLocations[0];
const location = item.ProductionLocations[0];
if (!layoutManager.tv && appHost.supports('externallinks')) {
gmap = `<a is="emby-linkbutton" class="button-link textlink" target="_blank" href="https://maps.google.com/maps?q=${gmap}">${gmap}</a>`;
gmap = `<a is="emby-linkbutton" class="button-link textlink" target="_blank" href="https://www.openstreetmap.org/search?query=${encodeURIComponent(location)}">${location}</a>`;
}
itemBirthLocation.classList.remove('hide');
itemBirthLocation.innerHTML = globalize.translate('BirthPlaceValue', gmap);
itemBirthLocation.innerHTML = globalize.translate('BirthPlaceValue', location);
} else {
itemBirthLocation.classList.add('hide');
}