Support for Tumblr mentions

This commit is contained in:
shinigami-eyes 2019-07-14 21:55:23 +02:00
parent eb95da3dc8
commit e88ad8cfb4
1 changed files with 3 additions and 0 deletions

View File

@ -347,6 +347,9 @@ function getIdentifierFromElementImpl(element: HTMLAnchorElement): string {
}
}
if (dataset && dataset.expandedUrl) return getIdentifierFromURLImpl(tryParseURL(dataset.expandedUrl));
if (element.classList.contains('tumblelog')) return element.textContent.substr(1) + '.tumblr.com';
const href = element.href;
if (href && !href.endsWith('#')) return getIdentifierFromURLImpl(tryParseURL(href));
return null;