nasa / fprime-gds

F´ Python Ground Data System (GDS).
https://github.com/nasa/fprime
Apache License 2.0
18 stars 37 forks source link

Fixes nasa/fprime#2312 by correcting scalar validation #147

Closed LeStarch closed 1 year ago

LeStarch commented 1 year ago
Originating Project/Creator
Affected Component
Affected Architectures(s)
Related Issue(s)
Has Unit Tests (y/n)
Builds Without Errors (y/n)
Unit Tests Pass (y/n)
Documentation Included (y/n)

Change Description

When validating complex (multi-field) command inputs, validity was set using getElementsByClassName()[0].setValidity. This meant for cases when the element being validated was a composition of smaller inputs, it would grab the first one and mark it invalid.

Now this is only performed on scalars such that the focus is not yanked to another element.

Fixes nasa/fprime#2312

Rationale

Annoying UI bugs get stomped 🥾🥾🥾.

Testing/Review Recommendations

Try working with multi-filed commands (SEND_SCALAR) and notice the difference!

Future Work

None known.