Skip to content

Commit

Permalink
Merge pull request #376 from tonyhallett/delete-unused-code
Browse files Browse the repository at this point in the history
delete unused code
  • Loading branch information
tonyhallett authored Jan 13, 2024
2 parents 711e115 + 7c23109 commit eb2ad6d
Showing 1 changed file with 0 additions and 48 deletions.
48 changes: 0 additions & 48 deletions SharedProject/Core/ReportGenerator/ReportGeneratorUtil.cs
Original file line number Diff line number Diff line change
Expand Up @@ -836,54 +836,6 @@ private string ObserveAndHideFullyCovered()
{
return "";
}
var old = @"
var targetNode = document;//document.querySelector('table.overview.table-fixed.stripped');
var config = { attributes: false, childList: true, subtree: true };
var callback = function(mutationsList, observer) {
var fullyCoveredTds = document.querySelectorAll('td.covered100.green')
for (var i = 0; i < fullyCoveredTds.length; i++)
{
var td = fullyCoveredTds[i];
var parent = td.parentNode;
if (parent.nodeName === 'TABLE')
{
parent = parent.parentNode;
if (parent.nodeName === 'COVERAGE-BAR')
{
parent = parent.parentNode;
if (parent.nodeName === 'TD' || parent.nodeName === 'TH')
{
parent = parent.parentNode;
var coverageBars = parent.querySelectorAll('td>coverage-bar');
if(coverageBars.length == 0){
coverageBars = parent.querySelectorAll('th>coverage-bar');
}
var shouldHide = true;
// currently there is no option to hide branch coverage.
if(coverageBars.length === 2){
var branchCoverageBar = coverageBars[1];
// includes gray
var td = branchCoverageBar.querySelector('table>td.covered100');
if(!td){
shouldHide = false;
}
}
if(shouldHide){
parent.style.setProperty('display', 'none');
}
}
}
}
}
};
var observer = new MutationObserver(callback);
observer.observe(targetNode, config);
";
var code = $@"
function getCellValue(row, index){{
return parseInt(row.cells[index].innerText);
Expand Down

0 comments on commit eb2ad6d

Please sign in to comment.