Composer: Prevent URL links converting to text lings when editing

This commit is contained in:
Alexander Zinchuk 2021-06-19 02:17:56 +03:00
parent b6abe0ee7c
commit 8102342412

View File

@ -142,6 +142,9 @@ function getEntityTypeFromNode(node: ChildNode) {
if (anchor.dataset.entityType === ApiMessageEntityTypes.MentionName) {
return ApiMessageEntityTypes.MentionName;
}
if (anchor.dataset.entityType === ApiMessageEntityTypes.Url) {
return ApiMessageEntityTypes.Url;
}
if (anchor.href.startsWith('mailto:')) {
return ApiMessageEntityTypes.Email;
}