flyerhq / flutter_link_previewer

Customizable link and URL preview extracted from the provided text with the ability to render from the cache. Ideal for chat applications.
MIT License
72 stars 75 forks source link

Cyrillic domains are not supported #60

Open xpolter opened 4 months ago

xpolter commented 4 months ago

/// Regex to find all links in the text. const regexLink = r'((http|ftp|https):\/\/)?([\w-]+(?:(?:.[\w-][a-zA-Z][\w-])+))([\w.,@?^=%&:/~+#-]*[\w@?^=%&/~+#-])?[^.\s]';

/// Regex to find all links in the text. const regexLink = r'https?://(?:[А-Яа-яA-Za-z0-9-]+.)+[А-Яа-яA-Za-z]{2,}(?:/[^/#?]+)+.(?:[A-Za-z0-9]+(?:.[A-Za-z0-9]+))?(?:\?[^#\s])?(?:#\S*)?'

nc-jeni commented 4 months ago

+1

Please apply this.

@demchenkoalex