- 验证码组件支持短信和图片
- 图标是用
js
实现的,图片还支持后端生成的URL
@inherits BaseComponent
<KCaptcha Option="@Option" />
@code {
private CaptchaOption Option;
}
class Test : BaseComponent
{
protected override void BuildRender(RenderTreeBuilder builder)
{
builder.Component<KCaptcha>()
.Set(c => c.Option, option) //option为CaptchaOption对象
.Build();
}
}