@@ -500,11 +500,12 @@ public String renderClassGraphDotImage() {
500
500
501
501
StringBuilder stringBuilder = new StringBuilder ();
502
502
stringBuilder .append ("<h1 align=\" center\" >Class Map</h1>" );
503
- stringBuilder .append ("<div align=\" center\" >Excludes classes that have no incoming and outgoing edges<br>" );
503
+ stringBuilder .append (
504
+ "<div align=\" center\" >Excludes classes that have no incoming and outgoing edges<br></div>" );
504
505
stringBuilder .append ("<script>\n " );
505
506
stringBuilder .append ("const " + classGraphName + "_dot = " + dot + "\n " );
506
507
stringBuilder .append ("</script>\n " );
507
- stringBuilder .append (generateForce3DPopup (classGraphName + "3D" ));
508
+ stringBuilder .append (generateForce3DPopup (classGraphName ));
508
509
509
510
stringBuilder .append (generate2DPopup (classGraphName ));
510
511
@@ -588,7 +589,8 @@ public String renderCycleDotImage(RankedCycle cycle) {
588
589
stringBuilder .append ("<script>\n " );
589
590
stringBuilder .append ("const " + cycleName + "_dot = " + dot + "\n " );
590
591
stringBuilder .append ("</script>\n " );
591
- stringBuilder .append (generateForce3DPopup (cycleName + "3D" ));
592
+ stringBuilder .append (generateForce3DPopup (cycleName ));
593
+ stringBuilder .append (generate2DPopup (cycleName ));
592
594
593
595
stringBuilder .append ("<div align=\" center\" >\n " );
594
596
stringBuilder .append ("Red lines represent back edges to remove.<br>\n " );
@@ -609,7 +611,6 @@ public String renderCycleDotImage(RankedCycle cycle) {
609
611
} else {
610
612
// revisit and add D3 popup button as well
611
613
612
- stringBuilder .append (generate2DPopup (cycleName ));
613
614
}
614
615
615
616
stringBuilder .append ("<br/>\n " );
@@ -681,9 +682,8 @@ String generate2DPopup(String cycleName) {
681
682
682
683
String generateForce3DPopup (String cycleName ) {
683
684
// Created by generative AI and modified
684
- String correctName = cycleName .replace ("3D" , "" );
685
685
return "<button style=\" display: block; margin: 0 auto;\" onclick=\" createForceGraph('popup-" + cycleName
686
- + "', 'graph-container-" + cycleName + "'," + correctName + "_dot )\" >Show " + correctName
686
+ + "', 'graph-container-" + cycleName + "'," + cycleName + "_dot )\" >Show " + cycleName
687
687
+ " 3D Popup</button>\n " + "\n "
688
688
+ "<div class=\" popup\" id=\" popup-"
689
689
+ cycleName + "\" >\n " + " <span class=\" close-btn\" onclick=\" hidePopup()\" >×</span>\n "
0 commit comments