fix: do not append HTML element as title in GeoRSSLink popup

This commit is contained in:
Yohan Boniface 2024-08-15 10:17:43 +02:00
parent 5a33709cc9
commit bc34851def

View file

@ -137,14 +137,15 @@ class GeoRSSImage extends TitleMixin(PopupTemplate) {
} }
} }
class GeoRSSLink extends TitleMixin(PopupTemplate) { class GeoRSSLink extends PopupTemplate {
renderBody(feature, container) { renderBody(feature, container) {
const title = this.renderTitle(feature, container) if (feature.properties.link) {
return Utils.loadTemplate( return Utils.loadTemplate(
`<a href="${feature.properties.link}" target="_blank">${title}</a>` `<a href="${feature.properties.link}" target="_blank"><h3>${feature.getDisplayName()}</h3></a>`
) )
} }
} }
}
class OSM extends TitleMixin(PopupTemplate) { class OSM extends TitleMixin(PopupTemplate) {
getName(feature) { getName(feature) {