Added website button for plugins

This commit is contained in:
Thorsten Sommer 2026-02-08 18:04:56 +01:00
parent 891b90819b
commit 198d31e7af
Signed by untrusted user who does not match committer: tsommer
GPG Key ID: 371BBA77A02C0108
6 changed files with 45 additions and 9 deletions

View File

@ -5317,6 +5317,9 @@ UI_TEXT_CONTENT["AISTUDIO::PAGES::PLUGINS::T2738444034"] = "Enabled Plugins"
-- Actions -- Actions
UI_TEXT_CONTENT["AISTUDIO::PAGES::PLUGINS::T3865031940"] = "Actions" UI_TEXT_CONTENT["AISTUDIO::PAGES::PLUGINS::T3865031940"] = "Actions"
-- Open website
UI_TEXT_CONTENT["AISTUDIO::PAGES::PLUGINS::T4239378936"] = "Open website"
-- Settings -- Settings
UI_TEXT_CONTENT["AISTUDIO::PAGES::SETTINGS::T1258653480"] = "Settings" UI_TEXT_CONTENT["AISTUDIO::PAGES::SETTINGS::T1258653480"] = "Settings"

View File

@ -63,6 +63,7 @@
</MudStack> </MudStack>
</MudTd> </MudTd>
<MudTd> <MudTd>
<MudStack Row="true" Spacing="1" AlignItems="AlignItems.Center">
@if (context is { IsInternal: false, Type: not PluginType.CONFIGURATION }) @if (context is { IsInternal: false, Type: not PluginType.CONFIGURATION })
{ {
var isEnabled = this.SettingsManager.IsPluginEnabled(context); var isEnabled = this.SettingsManager.IsPluginEnabled(context);
@ -70,6 +71,14 @@
<MudSwitch T="bool" Value="@isEnabled" ValueChanged="@(_ => this.PluginActivationStateChanged(context))"/> <MudSwitch T="bool" Value="@isEnabled" ValueChanged="@(_ => this.PluginActivationStateChanged(context))"/>
</MudTooltip> </MudTooltip>
} }
@if (context is { IsInternal: false } && this.TryGetSourceWebsite(context, out var sourceUrl))
{
<MudTooltip Text="@T("Open website")">
<MudIconButton Icon="@Icons.Material.Filled.OpenInBrowser" Href="@sourceUrl" Target="_blank" Size="Size.Medium"/>
</MudTooltip>
}
</MudStack>
</MudTd> </MudTd>
</RowTemplate> </RowTemplate>
</MudTable> </MudTable>

View File

@ -50,6 +50,23 @@ public partial class Plugins : MSGComponentBase
await this.MessageBus.SendMessage<bool>(this, Event.CONFIGURATION_CHANGED); await this.MessageBus.SendMessage<bool>(this, Event.CONFIGURATION_CHANGED);
} }
private bool TryGetSourceWebsite(IPluginMetadata pluginMeta, out string sourceUrl)
{
sourceUrl = string.Empty;
if (string.IsNullOrWhiteSpace(pluginMeta.SourceURL))
return false;
var normalizedSourceUrl = pluginMeta.SourceURL.Trim();
if (!Uri.TryCreate(normalizedSourceUrl, UriKind.Absolute, out var sourceUri))
return false;
if (sourceUri.Scheme is not ("http" or "https"))
return false;
sourceUrl = sourceUri.ToString();
return true;
}
#region Overrides of MSGComponentBase #region Overrides of MSGComponentBase
protected override async Task ProcessIncomingMessage<T>(ComponentBase? sendingComponent, Event triggeredEvent, T? data) where T : default protected override async Task ProcessIncomingMessage<T>(ComponentBase? sendingComponent, Event triggeredEvent, T? data) where T : default

View File

@ -5319,6 +5319,9 @@ UI_TEXT_CONTENT["AISTUDIO::PAGES::PLUGINS::T2738444034"] = "Aktivierte Plugins"
-- Actions -- Actions
UI_TEXT_CONTENT["AISTUDIO::PAGES::PLUGINS::T3865031940"] = "Aktionen" UI_TEXT_CONTENT["AISTUDIO::PAGES::PLUGINS::T3865031940"] = "Aktionen"
-- Open website
UI_TEXT_CONTENT["AISTUDIO::PAGES::PLUGINS::T4239378936"] = "Website öffnen"
-- Settings -- Settings
UI_TEXT_CONTENT["AISTUDIO::PAGES::SETTINGS::T1258653480"] = "Einstellungen" UI_TEXT_CONTENT["AISTUDIO::PAGES::SETTINGS::T1258653480"] = "Einstellungen"

View File

@ -5319,6 +5319,9 @@ UI_TEXT_CONTENT["AISTUDIO::PAGES::PLUGINS::T2738444034"] = "Enabled Plugins"
-- Actions -- Actions
UI_TEXT_CONTENT["AISTUDIO::PAGES::PLUGINS::T3865031940"] = "Actions" UI_TEXT_CONTENT["AISTUDIO::PAGES::PLUGINS::T3865031940"] = "Actions"
-- Open website
UI_TEXT_CONTENT["AISTUDIO::PAGES::PLUGINS::T4239378936"] = "Open website"
-- Settings -- Settings
UI_TEXT_CONTENT["AISTUDIO::PAGES::SETTINGS::T1258653480"] = "Settings" UI_TEXT_CONTENT["AISTUDIO::PAGES::SETTINGS::T1258653480"] = "Settings"

View File

@ -5,5 +5,6 @@
- Added an option in the app settings to create an encryption secret, which is required to encrypt values (for example, API keys) in configuration plugins. This feature only shows up when administration options are enabled. - Added an option in the app settings to create an encryption secret, which is required to encrypt values (for example, API keys) in configuration plugins. This feature only shows up when administration options are enabled.
- Improved the document analysis assistant (in beta) by hiding the export functionality by default. Enable the administration options in the app settings to show and use the export functionality. This streamlines the usage for regular users. - Improved the document analysis assistant (in beta) by hiding the export functionality by default. Enable the administration options in the app settings to show and use the export functionality. This streamlines the usage for regular users.
- Improved the workspaces experience by using a different color for the delete button to avoid confusion. - Improved the workspaces experience by using a different color for the delete button to avoid confusion.
- Improved the plugins page by adding a button to open the plugin's website. The action opens the plugin website in an external browser and is hidden for internal plugins.
- Fixed an issue where manually saving chats in workspace manual-storage mode could appear unreliable during response streaming. The save button is now disabled while streaming to prevent partial saves. - Fixed an issue where manually saving chats in workspace manual-storage mode could appear unreliable during response streaming. The save button is now disabled while streaming to prevent partial saves.
- Upgraded dependencies. - Upgraded dependencies.