make it work when `RestrictInputToSuggestions` is enabled. (Probably this case will never happen)
MODIFY
WalletWasabi.Fluent/Controls/TagsBox.axaml.cs
WalletWasabi.Fluent/Controls/TagsBox.axaml.cs
@@ -251,7 +251,21 @@ namespace WalletWasabi.Fluent.Controls
private void CheckIsCurrentTextValid()
{
- IsCurrentTextValid = !string.IsNullOrEmpty(CurrentText.ParseLabel());
+ var correctedInput = CurrentText.ParseLabel();
+
+ if (RestrictInputToSuggestions && Suggestions is { } suggestions )
+ {
+ IsCurrentTextValid = suggestions.Any(x => x.Equals(correctedInput, _stringComparison));
+ return;
+ }
+
+ if (!RestrictInputToSuggestions)
+ {
+ IsCurrentTextValid = !string.IsNullOrEmpty(correctedInput);
+ return;
+ }
+
+ throw new InvalidOperationException($"Invalid configuration! {nameof(Suggestions)} are not set!");
}
private void OnKeyDown(object? sender, KeyEventArgs e)

make it work when `RestrictInputToSuggestions` is enabled. (Probably this case will never happen)