fix(source): fix link detection (#243)

* 3.0.97

* 3.0.98

* 3.0.99

* fixed markdown link detection

* Update src/Components/Map/Subcomponents/ItemPopupComponents/TextView.tsx

Co-authored-by: Ulf Gebhardt <ulf.gebhardt@webcraft-media.de>

* css fix

* fix linting

---------

Co-authored-by: Ulf Gebhardt <ulf.gebhardt@webcraft-media.de>
This commit is contained in:
Anton Tranelis 2025-06-11 12:38:19 +02:00 committed by GitHub
parent 6327ae7788
commit a7a50af896
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 92 additions and 80 deletions

View File

@ -53,6 +53,13 @@ export const TextView = ({
if (innerText) replacedText = fixUrls(innerText)
if (replacedText) {
replacedText = replacedText.replace(
/(?<!\]?\()(?<!<)https?:\/\/[^\s)]+(?!\))(?!>)/g,
(url) => `[${url.replace(/https?:\/\/w{3}\./gi, '')}](${url})`,
)
}
if (replacedText) {
replacedText = replacedText.replace(mailRegex, (url) => {
return `[${url}](mailto:${url})`

View File

@ -19,13 +19,15 @@
overflow-x: hidden;
}
.leaflet-popup-content-wrapper, .leaflet-popup-tip{
.leaflet-popup-content-wrapper,
.leaflet-popup-tip {
background-color: var(--color-base-100);
color: var(--color-base-content);
border-radius: var(--radius-box);
}
.leaflet-popup-tip-container, .leaflet-popup-tip{
.leaflet-popup-tip-container,
.leaflet-popup-tip {
border-radius: 0;
}
@ -96,3 +98,6 @@
line-height: 40px !important;
}
.leaflet-popup-content p {
margin: calc(var(--tw-spacing) * 1) !important
}