!3660 doc(#I67AH3): update Editors doc

* 使用 PackageTips 组件简化文档代码
This commit is contained in:
alex_zou 2022-12-24 05:46:01 +00:00 committed by Argo
parent 3fd53d2bc2
commit f4bfc1e795
2 changed files with 1 additions and 20 deletions

View File

@ -9,14 +9,7 @@
<p>@((MarkupString)Localizer["P1"].Value)</p>
<div class="code-label">.NET CLI</div>
<Pre class="no-highlight">dotnet add package BootstrapBlazor.SummerNote --version @Version</Pre>
<div class="code-label">PackageReference</div>
<Pre class="no-highlight">&lt;PackageReference Include="BootstrapBlazor.SummerNote" Version="@Version" /&gt;</Pre>
<div class="code-label">Package Manager</div>
<Pre class="no-highlight">Install-Package BootstrapBlazor.SummerNote -Version @Version</Pre>
<PackageTips Name="BootstrapBlazor.SummerNote" />
<DemoBlock Title="@Localizer["Block1Title"]" Introduction="@Localizer["Block1Intro"]" Name="Normal">
<p>@((MarkupString)Localizer["P2"].Value)</p>

View File

@ -9,24 +9,12 @@ namespace BootstrapBlazor.Shared.Samples;
/// </summary>
public sealed partial class Editors
{
/// <summary>
/// 获得/设置 版本号字符串
/// </summary>
private string Version { get; set; } = "fetching";
private string? EditorValue { get; set; }
[NotNull]
private Editor? Editor { get; set; }
/// <summary>
/// OnInitializedAsync 方法
/// </summary>
/// <returns></returns>
protected override async Task OnInitializedAsync()
{
Version = await VersionManager.GetVersionAsync("bootstrapblazor.summernote");
}
private Task OnValueChanged(string val)
{