Skip to content

Commit ff33fa8

Browse files
committed
Cleaned code
1 parent dc5357b commit ff33fa8

5 files changed

Lines changed: 22 additions & 9 deletions

File tree

src/app/component/matrix/matrix.component.css

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,10 +26,12 @@
2626
font-size: 16px;
2727
font-weight: bold;
2828
}
29+
2930
.table-small-width{
3031
width: 5%;
3132
max-width: 9%;
3233
}
34+
3335
button{
3436
background-color: white;
3537
border: none;

src/app/component/matrix/matrix.component.html

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,9 @@
3535
class="mat-elevation-z8 matrix-table">
3636
<!-- Dimension Column -->
3737
<ng-container matColumnDef="Dimension">
38-
<th mat-header-cell *matHeaderCellDef class="table-small-width">Dimension</th>
38+
<th mat-header-cell *matHeaderCellDef class="table-small-width">
39+
Dimension
40+
</th>
3941
<td mat-cell *matCellDef="let element" class="table-small-width">
4042
<img
4143
src="assets/images/{{ element.Dimension }}.png"
@@ -47,8 +49,12 @@
4749

4850
<!-- Sub Dimension Column -->
4951
<ng-container matColumnDef="SubDimension">
50-
<th mat-header-cell *matHeaderCellDef class="table-small-width">Sub-Dimension</th>
51-
<td mat-cell *matCellDef="let element" class="table-small-width">{{ element.SubDimension }}</td>
52+
<th mat-header-cell *matHeaderCellDef class="table-small-width">
53+
Sub-Dimension
54+
</th>
55+
<td mat-cell *matCellDef="let element" class="table-small-width">
56+
{{ element.SubDimension }}
57+
</td>
5258
</ng-container>
5359

5460
<div *ngFor="let lvl of lvlColumn; index as i">

src/app/component/readme-to-html/readme-to-html.component.ts

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,14 +14,20 @@ export class ReadmeToHtmlComponent implements OnInit {
1414
toRender: string = '';
1515
constructor(private http: HttpClient) {}
1616

17-
async ngOnInit() {
17+
ngOnInit(): void {
18+
this.loadMarkdownFiles(this.MDFile);
19+
}
20+
21+
async loadMarkdownFiles(MDFile: string): Promise<boolean> {
1822
try {
1923
this.markdownURI = await this.http
20-
.get(this.MDFile, { responseType: 'text' })
24+
.get(MDFile, { responseType: 'text' })
2125
.toPromise();
2226
this.toRender = this.markdown.render(this.markdownURI);
27+
return true;
2328
} catch {
2429
this.toRender = 'Markdown file could not be found';
30+
return false;
2531
}
2632
}
2733
}
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
<app-top-header section="Usage"></app-top-header>
2-
<app-readme-to-html
3-
MDFile="./assets/Markdown Files/USAGE.md"></app-readme-to-html>
2+
<app-readme-to-html MDFile="./assets/Markdown Files/USAGE.md">
3+
</app-readme-to-html>

src/assets/Markdown Files/README.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -143,8 +143,7 @@ Multilanguage support is not given currently and not planned.
143143

144144
[![Timo Pagel IT-Consulting](https://raw.githubusercontent.com/DefectDojo/Documentation/master/doc/img/timo-pagel-logo.png)](https://pagel.pro)
145145

146-
[![Apprio Inc](https://github.com/wurstbrot/DevSecOps-MaturityModel/raw/master/assets/images/Apiiro_black_logo.png)](https://apiiro.com/)
147-
146+
[![Apprio Inc](https://github.com/wurstbrot/DevSecOps-MaturityModel/raw/master-old/assets/images/Apiiro_black_logo.png)](https://apiiro.com/)
148147

149148
# Donations
150149

0 commit comments

Comments
 (0)