UX: Correct tab selection in Wizard styling preview (#23639)

It seems like the intention is to update the tab selection at the bottom when the scrollable pane changes enough. In my testing (and I think by definition?), it doesn't seem like `scrollLeft` ever exceeds `offsetWidth`, so that tab-switching behavior doesn't ever happen
This commit is contained in:
Godfrey Chan 2023-09-26 04:02:09 -07:00 committed by GitHub
parent e3e94aec95
commit f576187d78
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -76,7 +76,7 @@ export default WizardPreviewBaseComponent.extend({
if (slider.scrollLeft < 50) {
this.set("previewTopic", true);
}
if (slider.scrollLeft > slider.offsetWidth) {
if (slider.scrollLeft > slider.offsetWidth - 50) {
this.set("previewTopic", false);
}
},