Skip to content
This repository has been archived by the owner on Jan 11, 2023. It is now read-only.

Fixes Line Highlight Bug #7768

Merged
merged 10 commits into from
Jan 23, 2019
Merged

Fixes Line Highlight Bug #7768

merged 10 commits into from
Jan 23, 2019

Conversation

zerefwayne
Copy link
Contributor

Fixes #7757

Summary of Change

  • Fixed the issue of breakpoint line getting highlighted whenever it came into view.

Test Plan

There wasn't any major change in the UI so I am planning to modify the tests later if required.

Demo

7757-line-highlight

src/components/Editor/HighlightLine.js Outdated Show resolved Hide resolved
src/components/Editor/HighlightLine.js Outdated Show resolved Hide resolved
@zerefwayne
Copy link
Contributor Author

@wldcordeiro Passed both the checks. 👍

Copy link
Contributor

@wldcordeiro wldcordeiro left a comment

Choose a reason for hiding this comment

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

Minor note about a CSS variable but this looks good. I wonder if adding a test would be possible to avoid a regression. 🤔

const durationString = style.getPropertyValue(
"--highlight-line-duration"
);
const duration =
Copy link
Contributor

Choose a reason for hiding this comment

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

Idea, avoid the parseFloat(...) mess by changing the CSS var to 1500ms then just strip out the ms.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@wldcordeiro But the stripped of "1500" would require a parseInt(...) right?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@wldcordeiro If it's not a big problem, are we good to go ahead with merging this? 💯

Copy link
Contributor

Choose a reason for hiding this comment

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

I really like that idea @wldcordeiro! WIth that we can just do a string replacement of ms

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@darkwing @wldcordeiro On it 👍

@zerefwayne
Copy link
Contributor Author

@darkwing @wldcordeiro Have a look at the changes. I've replaced it with 1500ms and stripped off the last two characters.

@darkwing darkwing merged commit eb0db35 into firefox-devtools:master Jan 23, 2019
@zerefwayne zerefwayne deleted the 7757-line-highlight-bug branch January 23, 2019 21:53
jasonLaster pushed a commit that referenced this pull request Jan 28, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants