itsthejoker / filamentcolors.xyz

The source code for a small website to compare pieces of printed filament.
MIT License
59 stars 5 forks source link

Update color match logic to respect last field touched #74

Closed itsthejoker closed 6 months ago

itsthejoker commented 7 months ago

Problem: when entering a LAB color, it jumps around and changes the values.

Reason: When entering any color, it immediately tries to cast that to RGB and then copies the casted values back down to each of the fields after re-converting. This works for some, but not all.

What it should do is keep a running tally of what color input method you were using and "lock" those values in to prevent them from changing. For LAB, it'd be:

itsthejoker commented 6 months ago

fixed in https://github.com/itsthejoker/filamentcolors.xyz/commit/3282dda7eaba8ff5d02a865e07b5fe10e4a798c4