Skip to content

Commit

Permalink
Remove apparently redundant code in Mermaid plugin
Browse files Browse the repository at this point in the history
As far as I can see this code serves no purpose for our use case.
  • Loading branch information
mrmanc committed Jan 6, 2025
1 parent cdb2eaa commit a2c3b86
Showing 1 changed file with 1 addition and 12 deletions.
13 changes: 1 addition & 12 deletions assets/js/mermaid/reveal-js-mermaid-plugin.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,18 +22,7 @@
return element.nodeName === 'SPAN';
});

var diagramSource = slide.getAttribute('data-diagram-source');
if (diagramSource) {
var diagramSlides = document.getElementsByClassName('diagram-slide');

var sourceSlides = Array.prototype.filter.call(diagramSlides, function(slide) {
return slide.getAttribute('data-state') === diagramSource;
});

return getDataElem(sourceSlides[0]);
} else {
return spans[0];
}
return spans[0];
}

function getDisplayDiv(slide) {
Expand Down

0 comments on commit a2c3b86

Please sign in to comment.