mirror of
https://github.com/MindWorkAI/AI-Studio.git
synced 2026-11-25 23:53:49 +00:00
Added a notice naming the page when a source opens without it (#1233)
This commit is contained in:
1 parent
e63e70a5cf
commit
deb75c8dd1
18 files changed
+447
-57
No files matched your search
@@ -1,5 +1,6 @@
|
||||
using AIStudio.Dialogs;
|
||||
using AIStudio.Tools.RAG;
|
||||
using AIStudio.Tools.Rust;
|
||||
using AIStudio.Tools.Services;
|
||||
|
||||
using Microsoft.AspNetCore.Components;
|
||||
@@ -39,6 +40,9 @@ public partial class SourcesList : MSGComponentBase
|
||||
[Inject]
|
||||
private RustService RustService { get; init; } = null!;
|
||||
|
||||
[Inject]
|
||||
private RuntimeInfoResponse RuntimeInfo { get; init; }
|
||||
|
||||
[Inject]
|
||||
private IDialogService DialogService { get; init; } = null!;
|
||||
|
||||
@@ -112,6 +116,11 @@ public partial class SourcesList : MSGComponentBase
|
||||
|
||||
private async Task OpenDocument(SourceDocumentLocation document) => await document.OpenAsync(this.RustService);
|
||||
|
||||
/// <summary>
|
||||
/// Whether a page can reach the program which opens a document, see RuntimeInfoResponseExtensions.
|
||||
/// </summary>
|
||||
private bool CanOpenAtPage => this.RuntimeInfo.CanOpenDocumentsAtPage;
|
||||
|
||||
/// <summary>
|
||||
/// The files of sources which are no longer at their place, by their paths, as FileActions found out.
|
||||
/// </summary>
|
||||
|
||||
Reference in new issue
Block a user