Known是基于C#和Blazor开发的前后端分离快速开发框架,开箱即用,跨平台,一处代码,多处运行。
如果对您有帮助,点击⭐Star⭐关注 ,感谢支持开源!
1. 分页组件
2. Tabs组件
builder.Component<Tabs>()
.Set(c => c.CurItem, items[0])
.Set(c => c.Items, items)
.Set(c => c.Body, (b, m) => b.DynamicComponent(m.ComType))
.Build();
3. Steps组件
//分步表单项
private readonly List<MenuItem> items = new()
{
new MenuItem{Icon="fa fa-home",Name="步骤一"},
new MenuItem{Icon="fa fa-home",Name="步骤二"},
new MenuItem{Icon="fa fa-home",Name="步骤三"}
};
//构建分步表单
builder.Component<Steps>()
.Set(c => c.Items, items)
.Set(c => c.OnChanged, OnChanged) //每步切换事件
.Set(c => c.OnFinished, OnFinished) //最后完成按钮事件
.Set(c => c.Body, BuildStep) //构建每步内容
.Build();