From 9d4cd8a8e9e4fbaf335be3f8fded5dd7118686d6 Mon Sep 17 00:00:00 2001 From: Fabian Gruenwald <fabian.gruenwald@mni.thm.de> Date: Sat, 1 May 2021 17:24:20 +0200 Subject: [PATCH] added --- .../shared/tag-cloud/tag-cloud.component.html | 1 - .../shared/tag-cloud/tag-cloud.component.ts | 25 ++++++++----------- 2 files changed, 11 insertions(+), 15 deletions(-) diff --git a/src/app/components/shared/tag-cloud/tag-cloud.component.html b/src/app/components/shared/tag-cloud/tag-cloud.component.html index dbd0424a6..dd93d857b 100644 --- a/src/app/components/shared/tag-cloud/tag-cloud.component.html +++ b/src/app/components/shared/tag-cloud/tag-cloud.component.html @@ -12,7 +12,6 @@ [height]="options.height" [overflow]="options.overflow" [zoomOnHover]="zoomOnHoverOptions" - (clicked)="tagClicked($event)" [log]='"debug"'> </angular-tag-cloud> diff --git a/src/app/components/shared/tag-cloud/tag-cloud.component.ts b/src/app/components/shared/tag-cloud/tag-cloud.component.ts index f4ef01748..fbffc1c86 100644 --- a/src/app/components/shared/tag-cloud/tag-cloud.component.ts +++ b/src/app/components/shared/tag-cloud/tag-cloud.component.ts @@ -74,20 +74,17 @@ export class TagCloudComponent implements OnInit { this.spacyService.analyse(commentsConcatenated, 'de').subscribe((res: Result) => { - this.data = res.words.filter(w => ['NE', 'NN', 'NMP', 'NNE'].indexOf(w.tag) >= 0).map(w => { - const weight = 5 + Math.floor(Math.random() * 4 + 1); - const color = weight2color[weight]; - return new TagComment(color, - true, null, null, - /*Math.floor(Math.random() * 30 - 15)*/0, w.text, - 'TODO', weight); - } - ) - } - ) - } + this.data = res.words.filter(w => ['NE', 'NN', 'NMP', 'NNE'].indexOf(w.tag) >= 0).map(w => { + const weight = 5 + Math.floor(Math.random() * 4 + 1); + const color = weight2color[weight]; + return new TagComment(color, + true, null, null, + /*Math.floor(Math.random() * 30 - 15)*/0, w.text, + 'TODO', weight); + } + ) + }) + - tagClicked(clicked: CloudData) { - console.log(clicked); } } -- GitLab