Skip to content

Commit

Permalink
Add visual indicators for collapsing
Browse files Browse the repository at this point in the history
  • Loading branch information
Anthirian committed Feb 7, 2020
1 parent 96195fb commit f323523
Showing 1 changed file with 9 additions and 3 deletions.
12 changes: 9 additions & 3 deletions nmap-bootstrap.xsl
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,9 @@ Andreas Hontzia (@honze_net)
height: 180px;
background-color: #f5f5f5;
}
.clickable {
cursor: pointer;
}
</style>
<title>Scan Report Nmap <xsl:value-of select="/nmaprun/@version"/></title>
</head>
Expand Down Expand Up @@ -126,14 +129,17 @@ Andreas Hontzia (@honze_net)
<script>
$(document).ready(function() {
$('#table-overview').DataTable();
$('h3.panel-title').click(function() {
$(this).find("i.glyphicon").toggleClass("glyphicon-chevron-down glyphicon-chevron-right");
});
});
</script>
<h2 id="onlinehosts" class="target">Online Hosts</h2>
<xsl:for-each select="/nmaprun/host[status/@state='up']">
<div class="panel panel-default">
<div class="panel-heading" data-toggle="collapse">
<xsl:attribute name="href">#<xsl:value-of select="translate(address/@addr, '.', '-')"/></xsl:attribute>
<h3 class="panel-title"><xsl:value-of select="address/@addr"/><xsl:if test="count(hostnames/hostname) > 0"> - <xsl:value-of select="hostnames/hostname/@name"/></xsl:if></h3>
<div class="panel-heading clickable" data-toggle="collapse">
<xsl:attribute name="data-target">#<xsl:value-of select="translate(address/@addr, '.', '-')"/></xsl:attribute>
<h3 class="panel-title"><i class="glyphicon glyphicon glyphicon-chevron-right"></i><xsl:value-of select="address/@addr"/><xsl:if test="count(hostnames/hostname) > 0"> - <xsl:value-of select="hostnames/hostname/@name"/></xsl:if></h3>
</div>
<div class="panel-body collapse in">
<xsl:attribute name="id"><xsl:value-of select="translate(address/@addr, '.', '-')"/></xsl:attribute>
Expand Down

0 comments on commit f323523

Please sign in to comment.