Skip to content

Commit

Permalink
feat: Threads
Browse files Browse the repository at this point in the history
  • Loading branch information
Thomas Junk committed Sep 13, 2023
1 parent e8ab41e commit ee89080
Show file tree
Hide file tree
Showing 4 changed files with 57 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,5 @@
}
p {
margin-left: 4rem;
font-size: small;
font-family: monospace;
}
</style>
6 changes: 4 additions & 2 deletions src/lib/singleview/vulnerabilities/vulnerability/Flags.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@

<Collapsible header="Flags" level="4">
{#each vulnerability.flags as flag}
<div class="spacer" />
{#if flag.date}
<div class="">
<h6>Date</h6>
Expand Down Expand Up @@ -39,14 +40,15 @@
</Collapsible>

<style>
.spacer {
margin-top: 1em;
}
h6 {
line-height: 0.3em;
font-size: large;
}
p {
margin-left: 4rem;
font-size: small;
font-family: monospace;
}
ul {
list-style-type: none;
Expand Down
2 changes: 0 additions & 2 deletions src/lib/singleview/vulnerabilities/vulnerability/Notes.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,5 @@
}
p {
margin-left: 4rem;
font-size: small;
font-family: monospace;
}
</style>
53 changes: 53 additions & 0 deletions src/lib/singleview/vulnerabilities/vulnerability/Threats.svelte
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
<script lang="ts">
import Collapsible from "$lib/Collapsible.svelte";
export let vulnerability: any;
</script>

<Collapsible header="Threats" level="4">
{#each vulnerability.threats as threat}
<div class="note">
<h6>Category</h6>
<p>{threat.category}</p>
</div>
{#if threat.date}
<div class="">
<h6>Date</h6>
<p>{threat.date}</p>
</div>
{/if}
<div class="note">
<h6>Details</h6>
<p>{threat.details}</p>
</div>
{#if threat.group_ids}
<div class="">
<h6>Group IDs</h6>
<ul>
{#each threat.group_ids as gid}
<li>{gid}</li>
{/each}
</ul>
</div>
{/if}
{#if threat.product_ids}
<div class="">
<h6>Product IDs</h6>
<ul>
{#each threat.product_ids as pid}
<li>{pid}</li>
{/each}
</ul>
</div>
{/if}
{/each}
</Collapsible>

<style>
.note {
text-align: justify;
}
h6 {
line-height: 0.3em;
font-size: large;
}
</style>

0 comments on commit ee89080

Please sign in to comment.