Open cranium opened 1 year ago
My observation from this is that it doesn't properly autolink unless the domain is 7 characters long. The link also has to be manually typed instead of pasted at once.
In the playground, https://www.123456.com
skips the .com as part of the link, but https://1234567.com
properly links fine.
Is there any progress on this?
As in the mention above, this bug completely ruins the experience with urls that have a subdomain, such as .co.uk
in https://playground.lexical.dev/
action | working as expected |
---|---|
manually type https://www.google.com |
NOT working as expected |
manually type https://google.com |
working as expected |
copy & paste https://www.google.com |
working as expected |
manually type google.com |
NOT working as expected |
copy & paste google.com |
NOT working as expected |
manually type www.google.com |
working as expected |
copy & paste www.google.com |
working as expected |
I resorted to making my own plugin to solve this and improve the URL matching in my project.
I have now stumbled over this bug in my project. Thanks for the fix, @redstar504. Using your package solved that issue for me.
Are you planning to move your fix into this repository here?
Lexical version: 0.11.1
Steps To Reproduce
I have an example here which appears to match the problem in the playground:
The current behavior
When typing https://www.google.com -> https://www.google is linked and .com is not.
The expected behavior
https://www.google.com would be linked.
Seems like in the autolink plugin there is a need to check existing links that are not separated by a whitespace.