mirror of
https://github.com/MindWorkAI/AI-Studio.git
synced 2025-04-28 15:59:48 +00:00
Applied code fix
This commit is contained in:
parent
319d3f9b94
commit
5a8b5154c9
@ -2,9 +2,7 @@ namespace AIStudio.Assistants.ERI;
|
|||||||
|
|
||||||
public static class AllowedLLMProvidersExtensions
|
public static class AllowedLLMProvidersExtensions
|
||||||
{
|
{
|
||||||
public static string Description(this AllowedLLMProviders provider)
|
public static string Description(this AllowedLLMProviders provider) => provider switch
|
||||||
{
|
|
||||||
return provider switch
|
|
||||||
{
|
{
|
||||||
AllowedLLMProviders.NONE => "Please select what kind of LLM provider are allowed for this data source",
|
AllowedLLMProviders.NONE => "Please select what kind of LLM provider are allowed for this data source",
|
||||||
AllowedLLMProviders.ANY => "Any LLM provider is allowed: users might choose a cloud-based or a self-hosted provider",
|
AllowedLLMProviders.ANY => "Any LLM provider is allowed: users might choose a cloud-based or a self-hosted provider",
|
||||||
@ -13,4 +11,3 @@ public static class AllowedLLMProvidersExtensions
|
|||||||
_ => "Unknown option was selected"
|
_ => "Unknown option was selected"
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
|
@ -10,9 +10,7 @@ public static class DataSourceTypeExtension
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="type">The data source type.</param>
|
/// <param name="type">The data source type.</param>
|
||||||
/// <returns>The display name of the data source type.</returns>
|
/// <returns>The display name of the data source type.</returns>
|
||||||
public static string GetDisplayName(this DataSourceType type)
|
public static string GetDisplayName(this DataSourceType type) => type switch
|
||||||
{
|
|
||||||
return type switch
|
|
||||||
{
|
{
|
||||||
DataSourceType.LOCAL_FILE => "Local File",
|
DataSourceType.LOCAL_FILE => "Local File",
|
||||||
DataSourceType.LOCAL_DIRECTORY => "Local Directory",
|
DataSourceType.LOCAL_DIRECTORY => "Local Directory",
|
||||||
@ -21,4 +19,3 @@ public static class DataSourceTypeExtension
|
|||||||
_ => "None",
|
_ => "None",
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
|
@ -2,9 +2,7 @@ namespace AIStudio.Settings.DataModel;
|
|||||||
|
|
||||||
public static class ThemesExtensions
|
public static class ThemesExtensions
|
||||||
{
|
{
|
||||||
public static string GetName(this Themes theme)
|
public static string GetName(this Themes theme) => theme switch
|
||||||
{
|
|
||||||
return theme switch
|
|
||||||
{
|
{
|
||||||
Themes.SYSTEM => "Synchronized with the operating system settings",
|
Themes.SYSTEM => "Synchronized with the operating system settings",
|
||||||
Themes.LIGHT => "Always use light theme",
|
Themes.LIGHT => "Always use light theme",
|
||||||
@ -13,4 +11,3 @@ public static class ThemesExtensions
|
|||||||
_ => "Unknown setting",
|
_ => "Unknown setting",
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
|
Loading…
Reference in New Issue
Block a user