mirror of
https://github.com/MindWorkAI/AI-Studio.git
synced 2025-08-21 01:52:57 +00:00
Update license URI and improve expansion panel structure
This commit is contained in:
parent
2c11619740
commit
08bd735ea9
@ -17,10 +17,22 @@
|
|||||||
</MudJustifiedText>
|
</MudJustifiedText>
|
||||||
</div>
|
</div>
|
||||||
<MudExpansionPanels Class="mb-3" MultiExpansion="@false" Outlined="false" Elevation="0">
|
<MudExpansionPanels Class="mb-3" MultiExpansion="@false" Outlined="false" Elevation="0">
|
||||||
|
<ExpansionPanel HeaderText="View GNU General Public License v2 (GPL)" MaxHeight="300" ExpandedChanged="this.OnExpandedChanged">
|
||||||
|
@if (this.isLoading)
|
||||||
|
{
|
||||||
|
<MudSkeleton />
|
||||||
|
<MudSkeleton Animation="Animation.Wave" />
|
||||||
|
<MudSkeleton />
|
||||||
|
}
|
||||||
|
else if (!string.IsNullOrWhiteSpace(this.licenseText))
|
||||||
|
{
|
||||||
|
<MudMarkdown Value="@this.licenseText" OverrideHeaderTypo="@Markdown.OverrideHeaderTypo"/>
|
||||||
|
}
|
||||||
|
</ExpansionPanel>
|
||||||
<ExpansionPanel HeaderIcon="@Icons.Material.Filled.AutoFixHigh" HeaderText="Automatic installation" IsExpanded="true">
|
<ExpansionPanel HeaderIcon="@Icons.Material.Filled.AutoFixHigh" HeaderText="Automatic installation" IsExpanded="true">
|
||||||
<MudText Typo="Typo.caption">
|
<MudText Typo="Typo.caption">
|
||||||
Pandoc is distributed under the
|
Pandoc is distributed under the
|
||||||
<MudLink Typo="Typo.caption" Href="https://github.com/jgm/pandoc/blob/main/COPYRIGHT" Target="_blank">GNU General Public License v2 (GPL)</MudLink>.
|
<MudLink Typo="Typo.caption" Href="https://github.com/jgm/pandoc/blob/main/COPYING.md" Target="_blank">GNU General Public License v2 (GPL)</MudLink>.
|
||||||
By clicking "Accept GPL and Install", you agree to the terms of the GPL license <br/> and Pandoc
|
By clicking "Accept GPL and Install", you agree to the terms of the GPL license <br/> and Pandoc
|
||||||
will be installed automatically for you. Software under GPL is <strong>free of charge</strong> and free to use.<br/>
|
will be installed automatically for you. Software under GPL is <strong>free of charge</strong> and free to use.<br/>
|
||||||
</MudText>
|
</MudText>
|
||||||
@ -49,7 +61,7 @@
|
|||||||
</MudListItem>
|
</MudListItem>
|
||||||
</MudList>
|
</MudList>
|
||||||
<MudText Class="mb-3" Typo="Typo.caption">
|
<MudText Class="mb-3" Typo="Typo.caption">
|
||||||
Pandoc is distributed under the <MudLink Typo="Typo.caption" Href="https://github.com/jgm/pandoc/blob/main/COPYRIGHT" Target="_blank">GNU General Public License v2 (GPL)</MudLink>.
|
Pandoc is distributed under the <MudLink Typo="Typo.caption" Href="https://github.com/jgm/pandoc/blob/main/COPYING.md" Target="_blank">GNU General Public License v2 (GPL)</MudLink>.
|
||||||
By clicking "Accept GPL and download installer", you agree to the terms of the GPL license. Software under GPL is <strong>free of charge</strong> and free to use.<br/>
|
By clicking "Accept GPL and download installer", you agree to the terms of the GPL license. Software under GPL is <strong>free of charge</strong> and free to use.<br/>
|
||||||
</MudText>
|
</MudText>
|
||||||
<MudButton OnClick="@this.GetInstaller" Color="Color.Secondary" Class="mt-4" Variant="Variant.Filled" Size="Size.Small" StartIcon="@Icons.Material.Filled.Downloading">
|
<MudButton OnClick="@this.GetInstaller" Color="Color.Secondary" Class="mt-4" Variant="Variant.Filled" Size="Size.Small" StartIcon="@Icons.Material.Filled.Downloading">
|
||||||
@ -90,7 +102,7 @@
|
|||||||
</MudListItem>
|
</MudListItem>
|
||||||
</MudList>
|
</MudList>
|
||||||
<MudText Class="mb-3" Typo="Typo.caption">
|
<MudText Class="mb-3" Typo="Typo.caption">
|
||||||
Pandoc is distributed under the <MudLink Typo="Typo.caption" Href="https://github.com/jgm/pandoc/blob/main/COPYRIGHT" Target="_blank">GNU General Public License v2 (GPL)</MudLink>.
|
Pandoc is distributed under the <MudLink Typo="Typo.caption" Href="https://github.com/jgm/pandoc/blob/main/COPYING.md" Target="_blank">GNU General Public License v2 (GPL)</MudLink>.
|
||||||
By clicking "Accept GPL and archive", you agree to the terms of the GPL license. Software under GPL is <strong>free of charge</strong> and free to use.<br/>
|
By clicking "Accept GPL and archive", you agree to the terms of the GPL license. Software under GPL is <strong>free of charge</strong> and free to use.<br/>
|
||||||
</MudText>
|
</MudText>
|
||||||
<MudButton OnClick="@this.GetArchive" Color="Color.Secondary" Class="mt-4" Variant="Variant.Filled" Size="Size.Small" StartIcon="@Icons.Material.Filled.Downloading">
|
<MudButton OnClick="@this.GetArchive" Color="Color.Secondary" Class="mt-4" Variant="Variant.Filled" Size="Size.Small" StartIcon="@Icons.Material.Filled.Downloading">
|
||||||
|
@ -21,8 +21,8 @@ public partial class PandocDialog : ComponentBase
|
|||||||
private IMudDialogInstance MudDialog { get; set; } = null!;
|
private IMudDialogInstance MudDialog { get; set; } = null!;
|
||||||
|
|
||||||
private static readonly ILogger LOG = Program.LOGGER_FACTORY.CreateLogger("PandocDialog");
|
private static readonly ILogger LOG = Program.LOGGER_FACTORY.CreateLogger("PandocDialog");
|
||||||
private static readonly string LICENCE_URI = "https://raw.githubusercontent.com/jgm/pandoc/master/COPYRIGHT";
|
private static readonly string LICENCE_URI = "https://raw.githubusercontent.com/jgm/pandoc/refs/heads/main/COPYING.md";
|
||||||
private static string PANDOC_VERSION = "1.0.0";
|
private static string PANDOC_VERSION = string.Empty;
|
||||||
|
|
||||||
private bool isPandocAvailable;
|
private bool isPandocAvailable;
|
||||||
private bool showSkeleton;
|
private bool showSkeleton;
|
||||||
@ -106,8 +106,6 @@ public partial class PandocDialog : ComponentBase
|
|||||||
this.isLoading = true;
|
this.isLoading = true;
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
await Task.Delay(600);
|
|
||||||
|
|
||||||
this.licenseText = await this.LoadLicenseTextAsync();
|
this.licenseText = await this.LoadLicenseTextAsync();
|
||||||
}
|
}
|
||||||
catch (Exception ex)
|
catch (Exception ex)
|
||||||
@ -122,7 +120,6 @@ public partial class PandocDialog : ComponentBase
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
await Task.Delay(350);
|
|
||||||
this.licenseText = string.Empty;
|
this.licenseText = string.Empty;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -131,7 +128,7 @@ public partial class PandocDialog : ComponentBase
|
|||||||
{
|
{
|
||||||
var response = await this.HttpClient.GetAsync(LICENCE_URI);
|
var response = await this.HttpClient.GetAsync(LICENCE_URI);
|
||||||
response.EnsureSuccessStatusCode();
|
response.EnsureSuccessStatusCode();
|
||||||
var content = await response.Content.ReadAsStringAsync();
|
|
||||||
return content;
|
return await response.Content.ReadAsStringAsync();
|
||||||
}
|
}
|
||||||
}
|
}
|
Loading…
Reference in New Issue
Block a user