Compare commits

...

10 Commits

Author SHA1 Message Date
estrogen elf 4948946f84 chore: increment version 2026-05-25 13:56:01 -05:00
estrogen elf 3a1c7376c1 fix: exception when opening latest update 2026-05-25 13:55:35 -05:00
estrogen elf c93093c0ea chore: increment version 2026-05-25 13:32:11 -05:00
estrogen elf cc14d4ee04 fix: trim titles of Hextech Docs posts 2026-05-25 13:31:04 -05:00
estrogen elf f3cf177409 Merge pull request #10 from DarkIntaqt/ft/hextechdocs-fix
Fix: Object reference not set to an instance of an object
2026-05-19 16:27:45 -05:00
DarkIntaqt 226eb6ccb3 fix: change hextechdocs html parsing to adapt for new format
It works on my machine
2026-05-19 23:21:42 +02:00
estrogen elf 94902c635e Increment version 2025-12-18 08:35:12 -06:00
estrogen elf d005e5ac56 Update thingies in about page 2025-12-18 08:34:32 -06:00
estrogen elf 221f21caa9 Merge pull request #9 from AoshiW/fix-Oopsies-Dialog-Spam 2025-12-18 08:26:01 -06:00
AoshiW b9f1b5a51e fix Oopsies Dialog Spam 2025-12-18 00:09:48 +01:00
6 changed files with 33 additions and 8 deletions
Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.1 KiB

After

Width:  |  Height:  |  Size: 72 KiB

+1 -1
View File
@@ -11,7 +11,7 @@
<AvaloniaXamlIlDebuggerLaunch>False</AvaloniaXamlIlDebuggerLaunch> <AvaloniaXamlIlDebuggerLaunch>False</AvaloniaXamlIlDebuggerLaunch>
<ApplicationIcon>app.ico</ApplicationIcon> <ApplicationIcon>app.ico</ApplicationIcon>
<AssemblyName>NeedleworkDotNet</AssemblyName> <AssemblyName>NeedleworkDotNet</AssemblyName>
<AssemblyVersion>0.14.0.0</AssemblyVersion> <AssemblyVersion>0.14.3.0</AssemblyVersion>
<FileVersion>$(AssemblyVersion)</FileVersion> <FileVersion>$(AssemblyVersion)</FileVersion>
<AvaloniaXamlVerboseExceptions>False</AvaloniaXamlVerboseExceptions> <AvaloniaXamlVerboseExceptions>False</AvaloniaXamlVerboseExceptions>
</PropertyGroup> </PropertyGroup>
@@ -32,8 +32,8 @@ namespace Needlework.Net.Services
foreach (var element in elements) foreach (var element in elements)
{ {
var path = element.QuerySelector("a.post-card-content-link")!.GetAttribute("href")!; var path = element.QuerySelector("a.post-card-content-link")!.GetAttribute("href")!;
var title = element.QuerySelector(".post-card-title")!.TextContent; var title = element.QuerySelector(".post-card-title")!.TextContent.Trim();
var excerpt = element.QuerySelector(".post-card-excerpt > p")!.TextContent; var excerpt = element.QuerySelector(".post-card-excerpt")!.TextContent;
var post = new HextechDocsPost() var post = new HextechDocsPost()
{ {
Path = path, Path = path,
@@ -1,11 +1,12 @@
using CommunityToolkit.Mvvm.ComponentModel; using CommunityToolkit.Mvvm.ComponentModel;
using CommunityToolkit.Mvvm.Input; using CommunityToolkit.Mvvm.Input;
using Needlework.Net.Extensions;
using Needlework.Net.Models; using Needlework.Net.Models;
using System.Diagnostics; using System.Diagnostics;
namespace Needlework.Net.ViewModels.MainWindow namespace Needlework.Net.ViewModels.MainWindow
{ {
public partial class NotificationViewModel : ObservableObject public partial class NotificationViewModel : ObservableObject, IEnableLogger
{ {
public NotificationViewModel(Notification notification) public NotificationViewModel(Notification notification)
{ {
@@ -20,8 +21,17 @@ namespace Needlework.Net.ViewModels.MainWindow
[RelayCommand] [RelayCommand]
public void OpenUrl() public void OpenUrl()
{ {
var process = new Process() { StartInfo = new() { UseShellExecute = true } }; try
{
var url = Notification?.Url ?? "https://github.com/BlossomiShymae/Needlework.Net/releases/latest";
var process = new Process() { StartInfo = new(url) { UseShellExecute = true } };
process.Start(); process.Start();
} }
catch (System.Exception exception)
{
this.Log()
.Error("Failed to open URL for notification: {@exception}", exception);
}
}
} }
} }
@@ -29,6 +29,8 @@ public partial class WebSocketViewModel : PageBase, IEnableLogger
{ {
private Dictionary<string, EventMessage> _events = []; private Dictionary<string, EventMessage> _events = [];
private readonly AvaloniaList<EventViewModel> _filteredEventLog = new();
private readonly IFlurlClient _githubUserContentClient; private readonly IFlurlClient _githubUserContentClient;
private readonly NotificationService _notificationService; private readonly NotificationService _notificationService;
@@ -53,7 +55,20 @@ public partial class WebSocketViewModel : PageBase, IEnableLogger
public CancellationTokenSource TokenSource { get; set; } = new(); public CancellationTokenSource TokenSource { get; set; } = new();
public IReadOnlyList<EventViewModel> FilteredEventLog => string.IsNullOrWhiteSpace(Search) ? EventLog : [.. EventLog.Where(x => x.Key.Contains(Search, StringComparison.InvariantCultureIgnoreCase))]; public IReadOnlyList<EventViewModel> FilteredEventLog
{
get
{
IEnumerable<EventViewModel> events = EventLog;
if (!string.IsNullOrWhiteSpace(Search))
{
events = events.Where(x => x.Key.Contains(Search, StringComparison.InvariantCultureIgnoreCase));
}
_filteredEventLog.Clear();
_filteredEventLog.AddRange(events);
return _filteredEventLog;
}
}
[ObservableProperty] [ObservableProperty]
private Vector _eventLogOffset = new(); private Vector _eventLogOffset = new();
@@ -46,7 +46,7 @@
<controls:UserCard UserImage="/Assets/Users/aoshiw.png" <controls:UserCard UserImage="/Assets/Users/aoshiw.png"
UserName="AoshiW" UserName="AoshiW"
UserGithub="AoshiW"> UserGithub="AoshiW">
For PR. For PRs that we needed the most.
</controls:UserCard> </controls:UserCard>
</WrapPanel> </WrapPanel>
</ScrollViewer> </ScrollViewer>