Skip to content

Commit 947d6d2

Browse files
Reveal project with "built by" links (#10)
Fixes #9 by revealing and then scrolling to the linked project instance.
1 parent 3e53eea commit 947d6d2

3 files changed

Lines changed: 13 additions & 1 deletion

File tree

ParallelBuildDebuggingLogger/Javascript.js

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,3 +21,11 @@ function filter() {
2121
}
2222
}
2323
}
24+
25+
function show(id) {
26+
var destinationElement = document.getElementById(id);
27+
28+
destinationElement.style.display = "";
29+
30+
destinationElement.scrollIntoView({ behavior: "smooth", block: "end", inline: "nearest" });
31+
}

ParallelBuildDebuggingLogger/ProjectBuildInfo.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,7 @@ public string AnnotatedName
104104

105105
public string ProjectIdLink
106106
{
107-
get => $"<a href=\"#{ParentProjectInstanceId}\">{ParentProjectInstanceId}</a>";
107+
get => $"<a class=\"linktoproject\" onclick=\"show({ParentProjectInstanceId})\">{ParentProjectInstanceId}</a>";
108108
}
109109
}
110110
}

ParallelBuildDebuggingLogger/Stylesheet.css

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,10 @@ body {
99
margin-bottom: 12px;
1010
}
1111

12+
a.linktoproject {
13+
text-decoration-line: underline;
14+
}
15+
1216
.projectdescription {
1317
position: relative;
1418
display: inline-block;

0 commit comments

Comments
 (0)