Improved workspaces by highlighting the current chat

This commit is contained in:
Thorsten Sommer 2026-06-08 12:51:59 +02:00
parent 0a4208d91d
commit a981d28dde
Signed by untrusted user who does not match committer: tsommer
GPG Key ID: 371BBA77A02C0108
3 changed files with 15 additions and 1 deletions

View File

@ -65,7 +65,7 @@ else
<MudTreeViewItem T="ITreeItem" Icon="@this.GetTreeItemIcon(treeItem)" Value="@item.Value" Expanded="@item.Expanded" CanExpand="@treeItem.Expandable" Items="@(treeItem.Children!)" OnClick="@(() => this.LoadChatAsync(treeItem.Path, true))">
<BodyContent>
<div style="display: grid; grid-template-columns: 1fr auto; align-items: center; width: 100%">
<MudText Style="justify-self: start;">
<MudText Style="@this.GetChatTreeItemTextStyle(treeItem)">
@if (string.IsNullOrWhiteSpace(treeItem.Text))
{
@T("Empty chat")

View File

@ -379,6 +379,19 @@ public partial class Workspaces : MSGComponentBase
return treeItem.Type is TreeItemType.CHAT && this.AIJobService.IsChatGenerationActive(treeItem.ChatId);
}
private string GetChatTreeItemTextStyle(TreeItemData treeItem)
{
return this.IsCurrentChatTreeItem(treeItem) ? "justify-self: start; font-weight: 700;" : "justify-self: start;";
}
private bool IsCurrentChatTreeItem(TreeItemData treeItem)
{
return treeItem.Type is TreeItemType.CHAT
&& this.CurrentChatThread is not null
&& treeItem.ChatId == this.CurrentChatThread.ChatId
&& treeItem.WorkspaceId == this.CurrentChatThread.WorkspaceId;
}
private string GetChatTreeIcon(Guid chatId, string defaultIcon)
{
var snapshot = this.AIJobService.TryGetChatSnapshot(chatId);

View File

@ -5,6 +5,7 @@
- Added support for reading enterprise policy files from a Flatpak provisioning extension.
- Added startup path and Linux package type details to the information page to make support easier.
- Added the option to search for chats in all workspaces.
- Improved workspaces by highlighting the currently open chat in the workspace view.
- Improved workspaces by adding a shortcut to start a new chat directly from each workspace row.
- Improved workspaces by allowing new workspaces to be created while moving a chat.
- Improved the enterprise configuration details on the information page by showing where each configuration comes from and which configuration slot was used.