mirror of
https://gitee.com/LongbowEnterprise/BootstrapBlazor.git
synced 2024-12-05 05:29:47 +08:00
!2356 doc(#I4S1KP): add ValidateRules doc of BootstrapInput
* doc: 增加 ValidateRules 文档 * doc: 更新资源文件
This commit is contained in:
parent
2f10e9b55d
commit
7b02a81683
@ -1230,7 +1230,8 @@
|
||||
"Att9": "The user presses the Esc key to call back the delegate",
|
||||
"Att10": "Whether to disable Fasle by default",
|
||||
"Att11": "Whether to get the focus automatically Default is fasle",
|
||||
"IsSelectAllTextOnFocus": "Whether auto select the all text after focus"
|
||||
"IsSelectAllTextOnFocus": "Whether auto select the all text after focus",
|
||||
"ValidateRules": "Customer validation collection"
|
||||
},
|
||||
"BootstrapBlazor.Shared.Samples.InputNumbers": {
|
||||
"Title": "InputNumber",
|
||||
|
@ -1231,7 +1231,8 @@
|
||||
"Att9": "用户按下 Esc 键回调委托",
|
||||
"Att10": "是否禁用",
|
||||
"Att11": "是否自动获取焦点",
|
||||
"IsSelectAllTextOnFocus": "获得焦点后自动选择输入框内所有字符串"
|
||||
"IsSelectAllTextOnFocus": "获得焦点后自动选择输入框内所有字符串",
|
||||
"ValidateRules": "自定义验证集合"
|
||||
},
|
||||
"BootstrapBlazor.Shared.Samples.InputNumbers": {
|
||||
"Title": "InputNumber 组件",
|
||||
|
@ -56,101 +56,109 @@ public partial class Inputs
|
||||
|
||||
private IEnumerable<AttributeItem> GetAttributes() => new[]
|
||||
{
|
||||
new AttributeItem() {
|
||||
Name = "ChildContent",
|
||||
Description = Localizer["Att1"],
|
||||
Type = "RenderFragment",
|
||||
ValueList = " — ",
|
||||
DefaultValue = " — "
|
||||
},
|
||||
new AttributeItem() {
|
||||
Name = "ShowLabel",
|
||||
Description = Localizer["Att2"],
|
||||
Type = "bool",
|
||||
ValueList = "true|false",
|
||||
DefaultValue = "false"
|
||||
},
|
||||
new AttributeItem() {
|
||||
Name = "DisplayText",
|
||||
Description = Localizer["Att3"],
|
||||
Type = "string",
|
||||
ValueList = " — ",
|
||||
DefaultValue = " — "
|
||||
},
|
||||
new AttributeItem() {
|
||||
Name = "Color",
|
||||
Description = Localizer["Att4"],
|
||||
Type = "Color",
|
||||
ValueList = "Primary / Secondary / Success / Danger / Warning / Info / Dark",
|
||||
DefaultValue = "Primary"
|
||||
},
|
||||
new AttributeItem() {
|
||||
Name = "FormatString",
|
||||
Description = Localizer["Att5"],
|
||||
Type = "string",
|
||||
ValueList = " — ",
|
||||
DefaultValue = " — "
|
||||
},
|
||||
new AttributeItem() {
|
||||
Name = "Formatter",
|
||||
Description = Localizer["Att6"],
|
||||
Type = "RenderFragment<TItem>",
|
||||
ValueList = " — ",
|
||||
DefaultValue = " — "
|
||||
},
|
||||
new AttributeItem()
|
||||
{
|
||||
Name = "type",
|
||||
Description = Localizer["Att7"],
|
||||
Type = "string",
|
||||
ValueList = "text / number / email / url / password",
|
||||
DefaultValue = "text"
|
||||
},
|
||||
new AttributeItem() {
|
||||
Name = "OnEnterAsync",
|
||||
Description = Localizer["Att8"],
|
||||
Type = "Func<TValue, Task>",
|
||||
ValueList = " — ",
|
||||
DefaultValue = " — "
|
||||
},
|
||||
new AttributeItem() {
|
||||
Name = "OnEscAsync",
|
||||
Description = Localizer["Att9"],
|
||||
Type = "Func<TValue, Task>",
|
||||
ValueList = " — ",
|
||||
DefaultValue = " — "
|
||||
},
|
||||
new AttributeItem()
|
||||
{
|
||||
Name = "IsDisabled",
|
||||
Description = Localizer["Att10"],
|
||||
Type = "bool",
|
||||
ValueList = "true|false",
|
||||
DefaultValue = "false"
|
||||
},
|
||||
new AttributeItem()
|
||||
{
|
||||
Name = "IsAutoFocus",
|
||||
Description = Localizer["Att11"],
|
||||
Type = "bool",
|
||||
ValueList = "true|false",
|
||||
DefaultValue = "false"
|
||||
},
|
||||
new AttributeItem()
|
||||
{
|
||||
Name = nameof(BootstrapInput<string>.IsSelectAllTextOnFocus),
|
||||
Description = Localizer[nameof(BootstrapInput<string>.IsSelectAllTextOnFocus)].Value,
|
||||
Type = "bool",
|
||||
ValueList = "true|false",
|
||||
DefaultValue = "false"
|
||||
},
|
||||
new AttributeItem()
|
||||
{
|
||||
Name = nameof(BootstrapInput<string>.IsTrim),
|
||||
Description = Localizer[nameof(BootstrapInput<string>.IsTrim)].Value,
|
||||
Type = "bool",
|
||||
ValueList = "true|false",
|
||||
DefaultValue = "false"
|
||||
}
|
||||
};
|
||||
new AttributeItem() {
|
||||
Name = "ChildContent",
|
||||
Description = Localizer["Att1"],
|
||||
Type = "RenderFragment",
|
||||
ValueList = " — ",
|
||||
DefaultValue = " — "
|
||||
},
|
||||
new AttributeItem() {
|
||||
Name = "ShowLabel",
|
||||
Description = Localizer["Att2"],
|
||||
Type = "bool",
|
||||
ValueList = "true|false",
|
||||
DefaultValue = "false"
|
||||
},
|
||||
new AttributeItem() {
|
||||
Name = "DisplayText",
|
||||
Description = Localizer["Att3"],
|
||||
Type = "string",
|
||||
ValueList = " — ",
|
||||
DefaultValue = " — "
|
||||
},
|
||||
new AttributeItem() {
|
||||
Name = "Color",
|
||||
Description = Localizer["Att4"],
|
||||
Type = "Color",
|
||||
ValueList = "Primary / Secondary / Success / Danger / Warning / Info / Dark",
|
||||
DefaultValue = "Primary"
|
||||
},
|
||||
new AttributeItem() {
|
||||
Name = "FormatString",
|
||||
Description = Localizer["Att5"],
|
||||
Type = "string",
|
||||
ValueList = " — ",
|
||||
DefaultValue = " — "
|
||||
},
|
||||
new AttributeItem() {
|
||||
Name = "Formatter",
|
||||
Description = Localizer["Att6"],
|
||||
Type = "RenderFragment<TItem>",
|
||||
ValueList = " — ",
|
||||
DefaultValue = " — "
|
||||
},
|
||||
new AttributeItem()
|
||||
{
|
||||
Name = "type",
|
||||
Description = Localizer["Att7"],
|
||||
Type = "string",
|
||||
ValueList = "text / number / email / url / password",
|
||||
DefaultValue = "text"
|
||||
},
|
||||
new AttributeItem() {
|
||||
Name = "OnEnterAsync",
|
||||
Description = Localizer["Att8"],
|
||||
Type = "Func<TValue, Task>",
|
||||
ValueList = " — ",
|
||||
DefaultValue = " — "
|
||||
},
|
||||
new AttributeItem() {
|
||||
Name = "OnEscAsync",
|
||||
Description = Localizer["Att9"],
|
||||
Type = "Func<TValue, Task>",
|
||||
ValueList = " — ",
|
||||
DefaultValue = " — "
|
||||
},
|
||||
new AttributeItem()
|
||||
{
|
||||
Name = "IsDisabled",
|
||||
Description = Localizer["Att10"],
|
||||
Type = "bool",
|
||||
ValueList = "true|false",
|
||||
DefaultValue = "false"
|
||||
},
|
||||
new AttributeItem()
|
||||
{
|
||||
Name = "IsAutoFocus",
|
||||
Description = Localizer["Att11"],
|
||||
Type = "bool",
|
||||
ValueList = "true|false",
|
||||
DefaultValue = "false"
|
||||
},
|
||||
new AttributeItem()
|
||||
{
|
||||
Name = nameof(BootstrapInput<string>.IsSelectAllTextOnFocus),
|
||||
Description = Localizer[nameof(BootstrapInput<string>.IsSelectAllTextOnFocus)].Value,
|
||||
Type = "bool",
|
||||
ValueList = "true|false",
|
||||
DefaultValue = "false"
|
||||
},
|
||||
new AttributeItem()
|
||||
{
|
||||
Name = nameof(BootstrapInput<string>.IsTrim),
|
||||
Description = Localizer[nameof(BootstrapInput<string>.IsTrim)].Value,
|
||||
Type = "bool",
|
||||
ValueList = "true|false",
|
||||
DefaultValue = "false"
|
||||
},
|
||||
new AttributeItem()
|
||||
{
|
||||
Name = nameof(BootstrapInput<string>.ValidateRules),
|
||||
Description = Localizer[nameof(BootstrapInput<string>.ValidateRules)].Value,
|
||||
Type = "List<IValidator>",
|
||||
ValueList = " — ",
|
||||
DefaultValue = " — "
|
||||
}
|
||||
};
|
||||
}
|
||||
|
File diff suppressed because one or more lines are too long
Loading…
Reference in New Issue
Block a user