mirror of
https://github.com/Stone-Red-Code/Decho.git
synced 2026-09-04 08:56:14 +02:00
Fix ChannelRegex to support hyphens in channel names
This commit is contained in:
@@ -22,7 +22,7 @@ namespace Decho.Views;
|
|||||||
public partial class MessageItemView : UserControl
|
public partial class MessageItemView : UserControl
|
||||||
{
|
{
|
||||||
private static readonly Regex MentionRegex = new(@"@(\w+)", RegexOptions.Compiled);
|
private static readonly Regex MentionRegex = new(@"@(\w+)", RegexOptions.Compiled);
|
||||||
private static readonly Regex ChannelRegex = new(@"(?<!\w)#(\w+)", RegexOptions.Compiled);
|
private static readonly Regex ChannelRegex = new(@"(?<!\w)#([\w-]+)", RegexOptions.Compiled);
|
||||||
private static readonly Regex UrlRegex = new(@"https?://[^\s]+", RegexOptions.Compiled);
|
private static readonly Regex UrlRegex = new(@"https?://[^\s]+", RegexOptions.Compiled);
|
||||||
private CancellationTokenSource? _loadCts;
|
private CancellationTokenSource? _loadCts;
|
||||||
private string? _loadedMessageId;
|
private string? _loadedMessageId;
|
||||||
|
|||||||
Reference in New Issue
Block a user