- Add the package
dotnet add PROJECT package NV.UI.Bootstrap- Add configuration settings appsettings.json
{
"BootstrapSettings": {
"ComponentStyles": {
}
},
}- Add startup registration Startup.cs
public void ConfigureServices(IServiceCollection services)
{
// Your configuration
services.AddUIBootstrap(Configuration.GetSection(BootstrapSettingsOptions.BootstrapSettings));
}You can change the default style of any component using the configuration in appsettings.json, for example appsettings.json
{
"BootstrapSettings": {
"ComponentStyles": {
"Card": {
"BorderWidth": "One",
"BorderColour": "Light",
"Shadow": "Small"
},
"Card-Header": {
"BackgroundColour": "White"
},
"List-Group": {
"Shadow": "Small"
}
}
},
}For example:
<BootstrapSelect OnChangeCallback=HandleChange Value=@Value IsDirty=@IsDirty IsInvalid=@IsInvalid>
<option></option>
<option value=@value.Key>@value.Value</option>
</BootstrapSelect>