Skip to content

Commit e8e3e69

Browse files
committed
feat: 增加 FooterContentTemplate 参数
1 parent a6e14bd commit e8e3e69

2 files changed

Lines changed: 12 additions & 0 deletions

File tree

src/BootstrapBlazor/Components/Modal/ModalDialog.razor

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,12 @@
5050
@if (ShowFooter)
5151
{
5252
<div class="modal-footer">
53+
@if (FooterContentTemplate != null)
54+
{
55+
<div class="modal-footer-content">
56+
@FooterContentTemplate
57+
</div>
58+
}
5359
@if (ShowCloseButton)
5460
{
5561
<Button Color="Color.Secondary" Text="@CloseButtonText" Icon="@CloseButtonIcon" OnClickWithoutRender="OnClickCloseAsync"></Button>

src/BootstrapBlazor/Components/Modal/ModalDialog.razor.cs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -200,6 +200,12 @@ public partial class ModalDialog : IHandlerException
200200
[Parameter]
201201
public RenderFragment? FooterTemplate { get; set; }
202202

203+
/// <summary>
204+
/// Gets or sets the footer content template. Default is null.
205+
/// </summary>
206+
[Parameter]
207+
public RenderFragment? FooterContentTemplate { get; set; }
208+
203209
/// <summary>
204210
/// 获得/设置 ModalHeader 组件
205211
/// </summary>

0 commit comments

Comments
 (0)