From 4f336960bde4faca2995f168967e0ae62b72f6a6 Mon Sep 17 00:00:00 2001 From: Thorsten Sommer Date: Tue, 18 Feb 2025 12:57:51 +0100 Subject: [PATCH] Ensure that RAG-related settings are hidden behind the RAG feature flag --- app/MindWork AI Studio/Pages/Settings.razor | 23 +++++++++++++++---- .../Pages/Settings.razor.cs | 3 +++ 2 files changed, 22 insertions(+), 4 deletions(-) diff --git a/app/MindWork AI Studio/Pages/Settings.razor b/app/MindWork AI Studio/Pages/Settings.razor index f8d90501..34a8a186 100644 --- a/app/MindWork AI Studio/Pages/Settings.razor +++ b/app/MindWork AI Studio/Pages/Settings.razor @@ -1,5 +1,6 @@ @attribute [Route(Routes.SETTINGS)] @using AIStudio.Components.Settings +@using AIStudio.Settings.DataModel
Settings @@ -7,8 +8,12 @@ - - + + @if (PreviewFeatures.PRE_RAG_2024.IsEnabled(this.SettingsManager)) + { + + + } @@ -16,7 +21,12 @@ - + + @if (PreviewFeatures.PRE_RAG_2024.IsEnabled(this.SettingsManager)) + { + + } + @@ -27,7 +37,12 @@ - + + @if (PreviewFeatures.PRE_RAG_2024.IsEnabled(this.SettingsManager)) + { + + } + diff --git a/app/MindWork AI Studio/Pages/Settings.razor.cs b/app/MindWork AI Studio/Pages/Settings.razor.cs index 600f4e93..aaf55c85 100644 --- a/app/MindWork AI Studio/Pages/Settings.razor.cs +++ b/app/MindWork AI Studio/Pages/Settings.razor.cs @@ -6,6 +6,9 @@ namespace AIStudio.Pages; public partial class Settings : ComponentBase, IMessageBusReceiver, IDisposable { + [Inject] + private SettingsManager SettingsManager { get; init; } = null!; + [Inject] private MessageBus MessageBus { get; init; } = null!;