Skip to content

Commit

Permalink
initialized tooltip in the report.html (#1581)
Browse files Browse the repository at this point in the history
return non-empty string when getting comment for field in NoticeView

Co-authored-by: jcpitre <[email protected]>
Co-authored-by: David Gamez <[email protected]>
  • Loading branch information
3 people committed Sep 20, 2023
1 parent 7264f75 commit 38717fa
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,11 @@ public SeverityLevel getSeverityLevel() {
* @return description text
*/
public String getCommentForField(String field) {
return comments.getFieldComment(field);
if (field.isBlank()) {
return field;
} else {
return comments.getFieldComment(field);
}
}
/**
* Returns the description text for the notice.
Expand Down
7 changes: 6 additions & 1 deletion main/src/main/resources/report.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,12 @@
<title>GTFS Schedule Validation Report</title>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8; width=device-width, initial-scale=1"/>
<script src="https://code.jquery.com/jquery-3.6.0.min.js"></script>
<script src="https://code.jquery.com/ui/1.12.1/jquery-ui.js"></script>
<script>
$(document).ready(function () {
$(document).tooltip();
});
</script>
<style>
body {
font-family: Helvetica, Arial, sans-serif;
Expand Down Expand Up @@ -122,7 +128,6 @@
}

.tooltip .tooltiptext {
visibility: hidden;
background-color: #555;
color: #fff;
text-align: center;
Expand Down

0 comments on commit 38717fa

Please sign in to comment.