Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ public partial class BootstrapInputNumber<TValue>

[Inject]
[NotNull]
private IOptions<BootstrapBlazorOptions>? StepOption { get; set; }
private IOptionsMonitor<BootstrapBlazorOptions>? StepOption { get; set; }

private string? _lastInputValueString;

Expand Down Expand Up @@ -123,7 +123,7 @@ protected override void OnParametersSet()
MinusIcon ??= IconTheme.GetIconByKey(ComponentIcons.InputNumberMinusIcon);
PlusIcon ??= IconTheme.GetIconByKey(ComponentIcons.InputNumberPlusIcon);

StepString = Step ?? StepOption.Value.GetStep<TValue>() ?? "any";
StepString = Step ?? StepOption.CurrentValue.GetStep<TValue>() ?? "any";

if (Value is null)
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ public partial class ValidateForm

[Inject]
[NotNull]
private IOptions<JsonLocalizationOptions>? Options { get; set; }
private IOptionsMonitor<JsonLocalizationOptions>? Options { get; set; }

[Inject]
[NotNull]
Expand Down Expand Up @@ -388,7 +388,7 @@ private void ValidateDataAnnotations(object? value, ValidationContext context, L
var find = false;
if (!string.IsNullOrEmpty(rule.ErrorMessage))
{
var resourceType = Options.Value.ResourceManagerStringLocalizerType;
var resourceType = Options.CurrentValue.ResourceManagerStringLocalizerType;
if (resourceType != null && LocalizerFactory.Create(resourceType).TryGetLocalizerString(rule.ErrorMessage, out var text))
{
rule.ErrorMessage = text;
Expand Down
Loading