Summary: | Web Inspector: REGRESSION(?): alpha slider doesn't match alpha input for `transparent` in color picker | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | Devin Rousso <hi> | ||||||||
Component: | Web Inspector | Assignee: | Nikita Vasilyev <nvasilyev> | ||||||||
Status: | RESOLVED FIXED | ||||||||||
Severity: | Normal | CC: | hi, inspector-bugzilla-changes, nvasilyev, webkit-bug-importer | ||||||||
Priority: | P2 | Keywords: | InRadar | ||||||||
Version: | WebKit Nightly Build | ||||||||||
Hardware: | All | ||||||||||
OS: | All | ||||||||||
Attachments: |
|
Description
Devin Rousso
2021-07-13 22:11:26 PDT
Reduction: data:text/html,<p%20style="color:transparent">color Created attachment 433799 [details]
Patch
Comment on attachment 433799 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=433799&action=review > Source/WebInspectorUI/ChangeLog:11 > + When the initial value was set to 0, the `set value` was exiting early when the passed value was 0. Based on this, it seems like the real issue is that the initial value of `_knobY` is really the incorrect value? Changing to `NaN` seems a bit scary since there's no handling of `isNaN` anywhere in this file. Perhaps we just need to add a `recalculateKnobY` call inside the early return in `set value`? This works as well. Created attachment 433801 [details]
Patch
Comment on attachment 433801 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=433801&action=review > Source/WebInspectorUI/UserInterface/Views/Slider.js:61 > + this.recalculateKnobY(); We should only need to do this inside the `if (value === this._value)`. As you have it now, we'd call `set knobY` twice in the non-early-return path. Created attachment 433804 [details]
Patch
Comment on attachment 433804 [details]
Patch
r=me
Committed r280045 (239780@main): <https://commits.webkit.org/239780@main> All reviewed patches have been landed. Closing bug and clearing flags on attachment 433804 [details]. |