Skip to content

Commit f656ba8

Browse files
AlexbitsElderJames
andauthored
fix: BasicLayout. OnCollapse event callback not invoked (#27)
* fix: BasicLayout. OnCollapse event callback not invoked * Update src/layout/src/BasicLayout.razor Co-authored-by: James Yeung <[email protected]> Co-authored-by: James Yeung <[email protected]>
1 parent 1193393 commit f656ba8

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/layout/src/BasicLayout.razor.cs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
using System.Collections.Generic;
2+
using System.Threading.Tasks;
23
using Microsoft.AspNetCore.Components;
34
using Microsoft.AspNetCore.Components.Web;
45
using Microsoft.Extensions.Logging;
@@ -90,10 +91,11 @@ protected override void OnStateChanged()
9091
SetStyle();
9192
}
9293

93-
private void HandleCollapse(bool collapsed)
94+
private async Task HandleCollapse(bool collapsed)
9495
{
9596
Collapsed = collapsed;
9697
SetStyle();
98+
await OnCollapse.InvokeAsync(collapsed);
9799
}
98100
}
99101
}

0 commit comments

Comments
 (0)