[openstreetmap/openstreetmap-website] Add social profile links (PR #5439)
David Tsiklauri
notifications at github.com
Fri Dec 27 08:05:28 UTC 2024
@nertc commented on this pull request.
> + :substack => %r{substack\.com/@([a-zA-Z0-9_-]+)},
+ :telegram => %r{t\.me/([a-zA-Z0-9_]+)},
+ :threads => %r{threads\.net/@([a-zA-Z0-9_]+)},
+ :tiktok => %r{tiktok\.com/@([a-zA-Z0-9_]+)},
+ :twitch => %r{twitch\.tv/([a-zA-Z0-9_]+)},
+ :twitter_x => %r{(?:twitter|x)\.com/([a-zA-Z0-9_]+)},
+ :vimeo => %r{vimeo.com/([a-zA-Z0-9_]+)},
+ :whatsapp => %r{wa\.me/(\d+)},
+ :youtube => %r{youtube\.com/@([a-zA-Z0-9_-]+)}
+ }.freeze
+
+ NO_USERNAME_PLATFORMS = %w[discord line skype slack].freeze
+
+ def parsed
+ URL_PATTERNS.each do |platform, pattern|
+ username = url.match(pattern)
It's a user's name shown in the URL of some websites' profile page (for example, in the `https://github.com/nertc` `nertc` is a `username`)
--
Reply to this email directly or view it on GitHub:
https://github.com/openstreetmap/openstreetmap-website/pull/5439#discussion_r1898344770
You are receiving this because you are subscribed to this thread.
Message ID: <openstreetmap/openstreetmap-website/pull/5439/review/2523800820 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/rails-dev/attachments/20241227/8ee5a074/attachment-0001.htm>
More information about the rails-dev
mailing list