Skip to content

Commit 50a2884

Browse files
authored
Merge pull request #248 from wurstbrot/chore/renameTaskToActivity
rename task to activity
2 parents 0606313 + dcf100c commit 50a2884

14 files changed

+348
-304
lines changed

src/app/app-routing.module.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,13 @@ import { AboutUsComponent } from './component/about-us/about-us.component';
44
import { CircularHeatmapComponent } from './component/circular-heatmap/circular-heatmap.component';
55
import { MappingComponent } from './component/mapping/mapping.component';
66
import { MatrixComponent } from './component/matrix/matrix.component';
7-
import { TaskDescriptionComponent } from './component/task-description/task-description.component';
7+
import { ActivityDescriptionComponent } from './component/activity-description/activity-description.component';
88
import { UsageComponent } from './component/usage/usage.component';
99

1010
const routes: Routes = [
1111
{ path: '', component: MatrixComponent },
1212
{ path: 'circular-heatmap', component: CircularHeatmapComponent },
13-
{ path: 'task-description', component: TaskDescriptionComponent },
13+
{ path: 'activity-description', component: ActivityDescriptionComponent },
1414
{ path: 'mapping', component: MappingComponent },
1515
{ path: 'usage', component: UsageComponent },
1616
{ path: 'about', component: AboutUsComponent },

src/app/app.module.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ import { LogoComponent } from './component/logo/logo.component';
1010
import { MatrixComponent } from './component/matrix/matrix.component';
1111
import { SidenavButtonsComponent } from './component/sidenav-buttons/sidenav-buttons.component';
1212
import { TopHeaderComponent } from './component/top-header/top-header.component';
13-
import { TaskDescriptionComponent } from './component/task-description/task-description.component';
13+
import { ActivityDescriptionComponent } from './component/activity-description/activity-description.component';
1414
import { ymlService } from './service/yaml-parser/yaml-parser.service';
1515
import { HttpClientModule } from '@angular/common/http';
1616
import { CircularHeatmapComponent } from './component/circular-heatmap/circular-heatmap.component';
@@ -27,7 +27,7 @@ import { DependencyGraphComponent } from './component/dependency-graph/dependenc
2727
MatrixComponent,
2828
SidenavButtonsComponent,
2929
TopHeaderComponent,
30-
TaskDescriptionComponent,
30+
ActivityDescriptionComponent,
3131
CircularHeatmapComponent,
3232
MappingComponent,
3333
ReadmeToHtmlComponent,

src/app/component/task-description/task-description.component.css renamed to src/app/component/activity-description/activity-description.component.css

File renamed without changes.

src/app/component/task-description/task-description.component.html renamed to src/app/component/activity-description/activity-description.component.html

Lines changed: 25 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<div class="content-box">
22
<h1>
3-
{{ currentTask.dimension }} -> {{ currentTask.subDimension }}:
4-
{{ currentTask.taskName }}
3+
{{ currentActivity.dimension }} -> {{ currentActivity.subDimension }}:
4+
{{ currentActivity.activityName }}
55
</h1>
66

77
<div class="example-action-buttons">
@@ -16,7 +16,7 @@ <h1>
1616
<b>UUID</b>
1717
</mat-panel-title>
1818
</mat-expansion-panel-header>
19-
<p [innerHTML]="currentTask.uuid"></p>
19+
<p [innerHTML]="currentActivity.uuid"></p>
2020
</mat-expansion-panel>
2121

2222
<mat-expansion-panel [expanded]="true">
@@ -25,7 +25,7 @@ <h1>
2525
<b>Description</b>
2626
</mat-panel-title>
2727
</mat-expansion-panel-header>
28-
<p [innerHTML]="currentTask.description"></p>
28+
<p [innerHTML]="currentActivity.description"></p>
2929
</mat-expansion-panel>
3030

3131
<mat-expansion-panel>
@@ -34,7 +34,7 @@ <h1>
3434
<b>Risk</b>
3535
</mat-panel-title>
3636
</mat-expansion-panel-header>
37-
<p [innerHTML]="currentTask.risk"></p>
37+
<p [innerHTML]="currentActivity.risk"></p>
3838
</mat-expansion-panel>
3939

4040
<mat-expansion-panel>
@@ -43,16 +43,16 @@ <h1>
4343
<b>Measure</b>
4444
</mat-panel-title>
4545
</mat-expansion-panel-header>
46-
<p [innerHTML]="currentTask.measure"></p>
46+
<p [innerHTML]="currentActivity.measure"></p>
4747
</mat-expansion-panel>
4848

49-
<mat-expansion-panel *ngIf="currentTask.implementatonGuide">
49+
<mat-expansion-panel *ngIf="currentActivity.implementatonGuide">
5050
<mat-expansion-panel-header>
5151
<mat-panel-title>
5252
<b>Implementation Guide</b>
5353
</mat-panel-title>
5454
</mat-expansion-panel-header>
55-
<p [innerHTML]="currentTask.implementatonGuide"></p>
55+
<p [innerHTML]="currentActivity.implementatonGuide"></p>
5656
</mat-expansion-panel>
5757

5858
<mat-expansion-panel>
@@ -61,18 +61,18 @@ <h1>
6161
<b>Difficulty of Implementation</b>
6262
</mat-panel-title>
6363
</mat-expansion-panel-header>
64-
<p>Knowledge: {{ this.KnowledgeLabels[this.currentTask.knowledge] }}</p>
65-
<p>Time: {{ this.GeneralLabels[this.currentTask.time] }}</p>
66-
<p>Resources: {{ this.GeneralLabels[this.currentTask.resources] }}</p>
64+
<p>Knowledge: {{ this.KnowledgeLabels[this.currentActivity.knowledge] }}</p>
65+
<p>Time: {{ this.GeneralLabels[this.currentActivity.time] }}</p>
66+
<p>Resources: {{ this.GeneralLabels[this.currentActivity.resources] }}</p>
6767
</mat-expansion-panel>
6868

69-
<mat-expansion-panel *ngIf="currentTask.usefulness !== -1">
69+
<mat-expansion-panel *ngIf="currentActivity.usefulness !== -1">
7070
<mat-expansion-panel-header>
7171
<mat-panel-title>
7272
<b>Usefulness</b>
7373
</mat-panel-title>
7474
</mat-expansion-panel-header>
75-
<p>{{ this.GeneralLabels[this.currentTask.usefulness] }}</p>
75+
<p>{{ this.GeneralLabels[this.currentActivity.usefulness] }}</p>
7676
</mat-expansion-panel>
7777

7878
<mat-expansion-panel>
@@ -81,7 +81,7 @@ <h1>
8181
<b>Evidence</b>
8282
</mat-panel-title>
8383
</mat-expansion-panel-header>
84-
<p [innerHTML]="currentTask.evidence"></p>
84+
<p [innerHTML]="currentActivity.evidence"></p>
8585
</mat-expansion-panel>
8686

8787
<mat-expansion-panel>
@@ -90,7 +90,7 @@ <h1>
9090
<b>Assessment</b>
9191
</mat-panel-title>
9292
</mat-expansion-panel-header>
93-
<p [innerHTML]="currentTask.assessment"></p>
93+
<p [innerHTML]="currentActivity.assessment"></p>
9494
</mat-expansion-panel>
9595

9696
<mat-expansion-panel>
@@ -102,7 +102,7 @@ <h1>
102102
<p>
103103
<mat-accordion multi="true">
104104
<mat-expansion-panel
105-
*ngFor="let implement of this.currentTask.implementation">
105+
*ngFor="let implement of this.currentActivity.implementation">
106106
<mat-expansion-panel-header>
107107
<mat-panel-title>
108108
<b [innerHTML]="implement['name']"></b>
@@ -157,7 +157,7 @@ <h1>
157157
<b>{{ SAMMVersion }}</b>
158158
</mat-panel-title>
159159
</mat-expansion-panel-header>
160-
<ul *ngFor="let samm of currentTask.samm">
160+
<ul *ngFor="let samm of currentActivity.samm">
161161
<li>{{ samm }}</li>
162162
</ul>
163163
</mat-expansion-panel>
@@ -167,7 +167,7 @@ <h1>
167167
<b>{{ ISOVersion }}</b>
168168
</mat-panel-title>
169169
</mat-expansion-panel-header>
170-
<ul *ngFor="let iso of currentTask.iso">
170+
<ul *ngFor="let iso of currentActivity.iso">
171171
<li>{{ iso }}</li>
172172
</ul>
173173
</mat-expansion-panel>
@@ -177,7 +177,7 @@ <h1>
177177
<b>{{ ISO22Version }}</b>
178178
</mat-panel-title>
179179
</mat-expansion-panel-header>
180-
<ul *ngFor="let iso22 of currentTask.iso22">
180+
<ul *ngFor="let iso22 of currentActivity.iso22">
181181
<li>{{ iso22 }}</li>
182182
</ul>
183183
</mat-expansion-panel>
@@ -192,7 +192,7 @@ <h1>
192192
</mat-panel-title>
193193
</mat-expansion-panel-header>
194194
<div
195-
*ngIf="currentTask.isImplemented; then thenBlock; else elseBlock"></div>
195+
*ngIf="currentActivity.isImplemented; then thenBlock; else elseBlock"></div>
196196
<ng-template #thenBlock> Implemented </ng-template>
197197
<ng-template #elseBlock> Not Implemented </ng-template>
198198
</mat-expansion-panel>
@@ -203,9 +203,9 @@ <h1>
203203
</mat-panel-title>
204204
</mat-expansion-panel-header>
205205
<app-dependency-graph
206-
dimension="{{ currentTask.dimension }}"
207-
subDimension="{{ currentTask.subDimension }}"
208-
taskName="{{ currentTask.taskName }}"></app-dependency-graph>
206+
dimension="{{ currentActivity.dimension }}"
207+
subDimension="{{ currentActivity.subDimension }}"
208+
activityName="{{ currentActivity.activityName }}"></app-dependency-graph>
209209
</mat-expansion-panel>
210210

211211
<mat-expansion-panel>
@@ -214,7 +214,7 @@ <h1>
214214
<b>Comments</b>
215215
</mat-panel-title>
216216
</mat-expansion-panel-header>
217-
<p [innerHTML]="currentTask.comments"></p>
217+
<p [innerHTML]="currentActivity.comments"></p>
218218
</mat-expansion-panel>
219219
</mat-accordion>
220220

@@ -224,6 +224,6 @@ <h1>
224224
<b>Tags</b>
225225
</mat-panel-title>
226226
</mat-expansion-panel-header>
227-
<p [innerHTML]="currentTask.tags"></p>
227+
<p [innerHTML]="currentActivity.tags"></p>
228228
</mat-expansion-panel>
229229
</div>

src/app/component/task-description/task-description.component.spec.ts renamed to src/app/component/activity-description/activity-description.component.spec.ts

Lines changed: 19 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -4,22 +4,22 @@ import { RouterTestingModule } from '@angular/router/testing';
44
import { sample } from 'rxjs';
55
import { ymlService } from 'src/app/service/yaml-parser/yaml-parser.service';
66

7-
import { TaskDescriptionComponent } from './task-description.component';
7+
import { ActivityDescriptionComponent } from './activity-description.component';
88

9-
describe('TaskDescriptionComponent', () => {
10-
let component: TaskDescriptionComponent;
11-
let fixture: ComponentFixture<TaskDescriptionComponent>;
9+
describe('ActivityDescriptionComponent', () => {
10+
let component: ActivityDescriptionComponent;
11+
let fixture: ComponentFixture<ActivityDescriptionComponent>;
1212

1313
beforeEach(async () => {
1414
await TestBed.configureTestingModule({
1515
providers: [ymlService, HttpClient, HttpHandler],
1616
imports: [RouterTestingModule],
17-
declarations: [TaskDescriptionComponent],
17+
declarations: [ActivityDescriptionComponent],
1818
}).compileComponents();
1919
});
2020

2121
beforeEach(() => {
22-
fixture = TestBed.createComponent(TaskDescriptionComponent);
22+
fixture = TestBed.createComponent(ActivityDescriptionComponent);
2323
component = fixture.componentInstance;
2424
fixture.detectChanges();
2525
});
@@ -31,8 +31,8 @@ describe('TaskDescriptionComponent', () => {
3131
it('check if header is being genenrated', () => {
3232
const testDimension = 'Sample Dimension';
3333
const testSubDimension = 'Sample subDimension';
34-
component.currentTask.dimension = testDimension;
35-
component.currentTask.subDimension = testSubDimension;
34+
component.currentActivity.dimension = testDimension;
35+
component.currentActivity.subDimension = testSubDimension;
3636
fixture.detectChanges();
3737
const HTMLElement: HTMLElement = fixture.nativeElement;
3838
const heading = HTMLElement.querySelector('h1')!;
@@ -42,7 +42,7 @@ describe('TaskDescriptionComponent', () => {
4242

4343
it('check if UUID is being genenrated', () => {
4444
const testUUID = '00000000-0000-0000-0000-000000000000';
45-
component.currentTask.uuid = testUUID;
45+
component.currentActivity.uuid = testUUID;
4646
fixture.detectChanges();
4747
const HTMLElement: HTMLElement = fixture.nativeElement;
4848
const contentDisplayedinParagraphTag = HTMLElement.querySelectorAll('p')!;
@@ -51,7 +51,7 @@ describe('TaskDescriptionComponent', () => {
5151

5252
it('check if description is being genenrated', () => {
5353
const testDescription = 'Sample Description';
54-
component.currentTask.description = testDescription;
54+
component.currentActivity.description = testDescription;
5555
fixture.detectChanges();
5656
const HTMLElement: HTMLElement = fixture.nativeElement;
5757
const contentDisplayedinParagraphTag = HTMLElement.querySelectorAll('p')!;
@@ -62,7 +62,7 @@ describe('TaskDescriptionComponent', () => {
6262

6363
it('check if risk is being genenrated', () => {
6464
const testRisk = 'Sample Risk';
65-
component.currentTask.risk = testRisk;
65+
component.currentActivity.risk = testRisk;
6666
fixture.detectChanges();
6767
const HTMLElement: HTMLElement = fixture.nativeElement;
6868
const contentDisplayedinParagraphTag = HTMLElement.querySelectorAll('p')!;
@@ -71,7 +71,7 @@ describe('TaskDescriptionComponent', () => {
7171

7272
it('check if measure is being genenrated', () => {
7373
const testMeasure = 'Sample Measure';
74-
component.currentTask.measure = testMeasure;
74+
component.currentActivity.measure = testMeasure;
7575
fixture.detectChanges();
7676
const HTMLElement: HTMLElement = fixture.nativeElement;
7777
const contentDisplayedinParagraphTag = HTMLElement.querySelectorAll('p')!;
@@ -82,7 +82,7 @@ describe('TaskDescriptionComponent', () => {
8282

8383
it('check if implementation guide is being genenrated', () => {
8484
const testImplementationGuide = 'Sample Implementation Guide';
85-
component.currentTask.implementatonGuide = testImplementationGuide;
85+
component.currentActivity.implementatonGuide = testImplementationGuide;
8686
fixture.detectChanges();
8787
const HTMLElement: HTMLElement = fixture.nativeElement;
8888
const contentDisplayedinParagraphTag = HTMLElement.querySelectorAll('p')!;
@@ -93,7 +93,7 @@ describe('TaskDescriptionComponent', () => {
9393

9494
it('check if evidence is being genenrated', () => {
9595
const testEvidence = 'Sample Evidence';
96-
component.currentTask.evidence = testEvidence;
96+
component.currentActivity.evidence = testEvidence;
9797
fixture.detectChanges();
9898
const HTMLElement: HTMLElement = fixture.nativeElement;
9999
const contentDisplayedinParagraphTag = HTMLElement.querySelectorAll('p')!;
@@ -104,7 +104,7 @@ describe('TaskDescriptionComponent', () => {
104104

105105
it('check if assessment is being genenrated', () => {
106106
const testAssessment = 'Sample Assessment';
107-
component.currentTask.assessment = testAssessment;
107+
component.currentActivity.assessment = testAssessment;
108108
fixture.detectChanges();
109109
const HTMLElement: HTMLElement = fixture.nativeElement;
110110
const contentDisplayedinParagraphTag = HTMLElement.querySelectorAll('p')!;
@@ -115,7 +115,7 @@ describe('TaskDescriptionComponent', () => {
115115

116116
it('check if comments is being genenrated', () => {
117117
const testComments = 'Sample Comments';
118-
component.currentTask.comments = testComments;
118+
component.currentActivity.comments = testComments;
119119
fixture.detectChanges();
120120
const HTMLElement: HTMLElement = fixture.nativeElement;
121121
const contentDisplayedinParagraphTag = HTMLElement.querySelectorAll('p')!;
@@ -128,9 +128,9 @@ describe('TaskDescriptionComponent', () => {
128128
const testSAMM = [' Sample SAMM '];
129129
const testISO = [' Sample ISO'];
130130
const testISO22 = [' Sample ISO22'];
131-
component.currentTask.samm = testSAMM;
132-
component.currentTask.iso = testISO;
133-
component.currentTask.iso22 = testISO22;
131+
component.currentActivity.samm = testSAMM;
132+
component.currentActivity.iso = testISO;
133+
component.currentActivity.iso22 = testISO22;
134134
fixture.detectChanges();
135135
const HTMLElement: HTMLElement = fixture.nativeElement;
136136
const contentDisplayedinParagraphTag = HTMLElement.querySelectorAll('p')!;

0 commit comments

Comments
 (0)