Dreamscapes / linter-coverage

Show code coverage data in Atom's Linter/Diagnostics pane 👀
https://atom.io/packages/linter-coverage
BSD 3-Clause "New" or "Revised" License
3 stars 0 forks source link

Support atom-ide-ui #4

Open brettz9 opened 4 years ago

brettz9 commented 4 years ago

Though the repo has been archived, atom-ide-ui is still available and working, e.g., for ESLint.

It'd be cool if you could support its datatips so the coverage item could show in the gutter, as in this screenshot.

screen

Thanks!

Arcanemagus commented 4 years ago

Your screenshot is showing the tooltips for the "diagnostic" messages, not any specific datatip consumer usage.

robertrossmann commented 4 years ago

Thanks for the suggestion, but I do not think that the Datatip service is a good fit for this kind of package. The coverage reports are mapped into the Diagnostics/Linter UI and they should, therefore, display according to your Linter UI package. The IDE-UI's Diagnostics UI should actually show the messages in the gutter and also on mouse over, although, if I remember correctly, my current implementation for coverage messages only marks the first character on a line as "uncovered" so you only get the hover tooltip when you precisely aim your mouse onto that spot in the editor (not ideal 🤷‍♂).

I would love to have that weird behaviour fixed, though. Ideally the diagnostic message would be mapped onto the whole line, starting at the first non-whitespace character and ending on the last non-whitespace character. The code responsible for mapping a missed line to the editor is here - notice that 0 as the second parameter in both arguments.

Up for a challenge and a PR? 😇

brettz9 commented 4 years ago

Sorry, plate overflowing atm...