feat: WPF自动战斗对于作业描述的视频自动跳转增加av号支持

This commit is contained in:
status102
2023-09-14 17:35:41 +08:00
parent 7003063e96
commit 2123e37fe9

View File

@@ -266,7 +266,7 @@ namespace MaaWpfGui.ViewModels.UI
AddLog(details, detailsColor);
{
Url = CopilotUiUrl;
var linkParser = new Regex("(BV.*?).{10}", RegexOptions.Compiled | RegexOptions.IgnoreCase);
var linkParser = new Regex(@"AV\d+|(BV.*?).{10}", RegexOptions.Compiled | RegexOptions.IgnoreCase);
foreach (Match match in linkParser.Matches(details))
{
Url = "https://www.bilibili.com/video/" + match.Value;