You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When using the @PredicateConstraint in my config model, the value inside the input box appears green, even though the value does not satisfy the @PredicateConstraint. This gives the impression that the input is valid, which can be misleading for users. The only sign that the config value didn't get saved is a log message, that is probably overlooked by most users.
How it looks to the user
[Render thread/WARN] (owo) Option Key{path=[maxMediaSize]} in config 'mod' could not be updated, as the given value '-123' does not match its constraint: Predicate method maxMediaSizePredicate The only sign that the config didn't get saved. Probably overlooked by most users
Expected Behavior:
The input box should visually indicate when a @PredicateConstraint is not satisfied by turning the text red, similar to how other invalid inputs are indicated.
(I have only tested this with int values)
My Code:
@PredicateConstraint("maxMediaSizePredicate")
public int maxMediaSize = 30;
public static boolean maxMediaSizePredicate(int maxMediaSize) {
return maxMediaSize > 0;
}
The text was updated successfully, but these errors were encountered:
Zappic3
added a commit
to Zappic3/owo-lib
that referenced
this issue
Sep 21, 2024
owo_version=0.12.14+1.21
When using the @PredicateConstraint in my config model, the value inside the input box appears green, even though the value does not satisfy the @PredicateConstraint. This gives the impression that the input is valid, which can be misleading for users. The only sign that the config value didn't get saved is a log message, that is probably overlooked by most users.
How it looks to the user
[Render thread/WARN] (owo) Option Key{path=[maxMediaSize]} in config 'mod' could not be updated, as the given value '-123' does not match its constraint: Predicate method maxMediaSizePredicate
The only sign that the config didn't get saved. Probably overlooked by most users
Expected Behavior:
The input box should visually indicate when a @PredicateConstraint is not satisfied by turning the text red, similar to how other invalid inputs are indicated.
(I have only tested this with int values)
My Code:
The text was updated successfully, but these errors were encountered: