Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve number input #313

Merged
merged 4 commits into from
Sep 26, 2024
Merged

Improve number input #313

merged 4 commits into from
Sep 26, 2024

Conversation

mark-prins
Copy link
Contributor

Fixes #287

I've removed the tight coupling between the text input and the value, which was also being limited by the min/max constraints.

This means that when you edit a numeric input, you can clear the input and type in a number larger or smaller than the allowable. When you save though, the value saved is the one entered which is in range. Hopefully if you try it you'll see what I mean.

For example, when editing a temperature (which has a minimum value of 1) this sequence can happen:

  1. the initial value is 30
  2. you backspace twice to clear the value
  3. you click OK
  4. the value of 3 is saved, as this is the last valid value

It is hard to explain but I think makes more sense when using it than the previous, which prevented the input value from changing.

The affected areas are:

  • Default logging interval
  • sensor logging interval
  • temperature breach settings (x4)
    • temperature
    • duration

You can test this and #296 with this apk

Copy link
Contributor

@jmbrunskill jmbrunskill left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Keen to see how the testers feel before we merge this one...

Sounds better, but could also feel quite buggy :(
Number inputs are much harder than I ever though in the past!

Base automatically changed from 296-temperature-units to v0.5.7 September 24, 2024 02:47
@mark-prins
Copy link
Contributor Author

@jmbrunskill thanks for review! have checked in with @marthakeezy and she has given her blessing 🙏

@mark-prins mark-prins merged commit a76f1e0 into v0.5.7 Sep 26, 2024
@mark-prins mark-prins deleted the 287-number-input branch September 26, 2024 00:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants