Skip to content

Commit e3e03e7

Browse files
committed
refactor: 更新示例
1 parent f268da5 commit e3e03e7

File tree

2 files changed

+1
-12
lines changed

2 files changed

+1
-12
lines changed

src/BootstrapBlazor.Server/Components/Samples/TreeViews.razor

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -39,9 +39,6 @@
3939
<div>@((MarkupString)Localizer["TreeViewCheckboxTips2"].Value)</div>
4040
</section>
4141
<section ignore class="row form-inline">
42-
<div class="col-12 col-lg-auto">
43-
<RadioList IsButton="true" @bind-Value="@IsReset" Items="@ResetItems" Color="Color.Success" ShowLabel="true" DisplayText="@Localizer["TreeViewNormalRadioListDisplayText"]"></RadioList>
44-
</div>
4542
<div class="col-12 col-lg-auto">
4643
<Checkbox DisplayText="@Localizer["TreeViewCheckboxCheckBoxDisplayText1"]" ShowAfterLabel="true" @bind-Value="@AutoCheckChildren"></Checkbox>
4744
<Checkbox DisplayText="@Localizer["TreeViewCheckboxCheckBoxDisplayText2"]" ShowAfterLabel="true" @bind-Value="@AutoCheckParent" class="ms-3"></Checkbox>
@@ -50,7 +47,7 @@
5047
<Button Text="@Localizer["TreeViewCheckboxButtonText"]" OnClick="@OnRefresh"></Button>
5148
</div>
5249
</section>
53-
<TreeView TItem="TreeFoo" Items="@CheckedItems" ShowCheckbox="true" OnTreeItemChecked="@OnTreeItemChecked" IsReset="@IsReset" AutoCheckChildren="@AutoCheckChildren" AutoCheckParent="@AutoCheckParent"></TreeView>
50+
<TreeView TItem="TreeFoo" Items="@CheckedItems" ShowCheckbox="true" OnTreeItemChecked="@OnTreeItemChecked" AutoCheckChildren="@AutoCheckChildren" AutoCheckParent="@AutoCheckParent"></TreeView>
5451
<ConsoleLogger @ref="Logger2"></ConsoleLogger>
5552
</DemoBlock>
5653

src/BootstrapBlazor.Server/Components/Samples/TreeViews.razor.cs

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -93,14 +93,6 @@ private static List<TreeViewItem<TreeFoo>> GetCheckedItems()
9393
return ret;
9494
}
9595

96-
private bool IsReset { get; set; }
97-
98-
private List<SelectedItem> ResetItems { get; } =
99-
[
100-
new("True", "Reset"),
101-
new("False", "Keep")
102-
];
103-
10496
[Inject, NotNull]
10597
private ToastService? ToastService { get; set; }
10698

0 commit comments

Comments
 (0)