feat(StatusInput): add force argument to validate to force validation

This commit is contained in:
Jonathan Rainville 2022-07-28 13:26:47 -04:00 committed by Michał Cieślak
parent b3dfa02297
commit a05a35939a

View File

@ -249,9 +249,8 @@ Item {
\qmlmethod
This function validates the text input's text.
*/
function validate() {
if (!statusBaseInput.dirty && validationMode === StatusInput.ValidationMode.OnlyWhenDirty) {
function validate(force) {
if (!force && !statusBaseInput.dirty && validationMode === StatusInput.ValidationMode.OnlyWhenDirty) {
return
}
statusBaseInput.valid = true