From b714450514e442b33643a701692265af17e26d9a Mon Sep 17 00:00:00 2001
From: Thisari Muthuwahandi <thisari.muthuwahandi@mni.thm.de>
Date: Mon, 18 Mar 2019 13:34:58 +0100
Subject: [PATCH] zg

---
 .../comment-create-page.component.scss        |  2 +-
 .../comment-create-page.component.ts          |  2 -
 .../comment-list/comment-list.component.html  |  6 +-
 .../comment-list/comment-list.component.scss  | 40 +++++++++----
 .../comment-list/comment-list.component.ts    | 27 ++++++++-
 src/app/services/http/comment.service.ts      | 40 +++++++++----
 src/assets/i18n/creator/de.json               | 38 ++++++------
 src/assets/i18n/creator/en.json               | 50 ++++++++--------
 src/assets/i18n/home/de.json                  | 52 ++++++++--------
 src/assets/i18n/home/en.json                  | 60 +++++++++----------
 src/assets/i18n/participant/de.json           | 24 ++++----
 src/assets/i18n/participant/en.json           | 25 ++++----
 src/theme/_theme.scss                         |  2 -
 13 files changed, 211 insertions(+), 157 deletions(-)

diff --git a/src/app/components/participant/comment-create-page/comment-create-page.component.scss b/src/app/components/participant/comment-create-page/comment-create-page.component.scss
index ce244ec3c..e1772bc65 100644
--- a/src/app/components/participant/comment-create-page/comment-create-page.component.scss
+++ b/src/app/components/participant/comment-create-page/comment-create-page.component.scss
@@ -11,6 +11,6 @@ app-comment-list {
 }
 
 button {
-  margin-right: 20px;
+  float: right;
   min-width: 80px;
 }
diff --git a/src/app/components/participant/comment-create-page/comment-create-page.component.ts b/src/app/components/participant/comment-create-page/comment-create-page.component.ts
index 048bc1801..c472c2187 100644
--- a/src/app/components/participant/comment-create-page/comment-create-page.component.ts
+++ b/src/app/components/participant/comment-create-page/comment-create-page.component.ts
@@ -40,8 +40,6 @@ export class CommentCreatePageComponent implements OnInit {
     this.roomId = localStorage.getItem(`roomId`);
   }
 
-  // TODO: check if empty
-
   send(subject: string, body: string): void {
     subject = subject.trim();
     body = body.trim();
diff --git a/src/app/components/shared/comment-list/comment-list.component.html b/src/app/components/shared/comment-list/comment-list.component.html
index e8d5e8bb8..7b4199544 100644
--- a/src/app/components/shared/comment-list/comment-list.component.html
+++ b/src/app/components/shared/comment-list/comment-list.component.html
@@ -1,4 +1,8 @@
-<mat-toolbar >List of Questions</mat-toolbar>
+<input matInput #searchBox placeholder="search in comments" (input)="search(searchBox.value)">
+<ul class="search-results">
+  <li *ngFor="let comment of comments$  | async">
+    <a routerLink="/comment/{{comment.id}}">{{comment.subject}}</a>
+</ul>
 <mat-card class="outer-card">
   <mat-card class="card-container" *ngFor="let comment of comments">
     <mat-card-title>{{comment.subject}}</mat-card-title>
diff --git a/src/app/components/shared/comment-list/comment-list.component.scss b/src/app/components/shared/comment-list/comment-list.component.scss
index 98d96ca35..77a82d8e4 100644
--- a/src/app/components/shared/comment-list/comment-list.component.scss
+++ b/src/app/components/shared/comment-list/comment-list.component.scss
@@ -1,24 +1,40 @@
 mat-card {
-  margin-bottom: 20px;
-  background-color: #b2ebf2;
+  margin-bottom: 10px;
+  background-color: #4db6ac;
 }
 
 mat-card-content>:first-child {
   margin-top: 20px;
 }
 
-mat-toolbar {
-  border-radius: 10px;
-  margin-bottom: 20px;
-  background-color: #bbdefb;
+.card-container {
+  background-color: #b2dfdb;
+  overflow: auto;
+  overflow-wrap: break-word;
 }
 
-.card-container {
-  background-color: #4dd0e1;
-  opacity: 0.7;
-  border-radius: 2px;
+mat-card-title {
+  font-size: 20px;
 }
 
-.outer-card {
-  border-radius: 8px;
+input {
+  border: 2px solid #4db6ac;
+  border-radius: 30px;
+   padding: 5px 10px 5px 20px;
+   width: 50%;
 }
+
+.search-results li {
+  list-style-type: none;
+  width: 50%;
+}
+
+li a {
+  border: 1px solid #4db6ac;
+  text-decoration: none;
+  display: block;
+  color: black;
+   background-color: #b2dfdb;
+   padding: 10px;
+   
+}
\ No newline at end of file
diff --git a/src/app/components/shared/comment-list/comment-list.component.ts b/src/app/components/shared/comment-list/comment-list.component.ts
index f30897d85..55635ead0 100644
--- a/src/app/components/shared/comment-list/comment-list.component.ts
+++ b/src/app/components/shared/comment-list/comment-list.component.ts
@@ -1,6 +1,8 @@
-import { Component, OnInit } from '@angular/core';
+import { Component, OnInit, Pipe, PipeTransform } from '@angular/core';
 import { ActivatedRoute } from '@angular/router';
 import { Location } from '@angular/common';
+import { debounceTime, distinctUntilChanged, switchMap } from 'rxjs/operators';
+import { Observable, Subject } from 'rxjs';
 import { Comment } from '../../../models/comment';
 import { CommentService } from '../../../services/http/comment.service';
 import { RoomService } from '../../../services/http/room.service';
@@ -16,7 +18,7 @@ import { LanguageService } from '../../../services/util/language.service';
   templateUrl: './comment-list.component.html',
   styleUrls: ['./comment-list.component.scss']
 })
-export class CommentListComponent implements OnInit {
+export class CommentListComponent implements OnInit{
   userRoleTemp: any = UserRole.CREATOR;
   userRole: UserRole;
   user: User;
@@ -24,6 +26,8 @@ export class CommentListComponent implements OnInit {
   isLoading = true;
   roomId: string;
   roomShortId: string;
+  private searchTerms = new Subject<string>();
+  comments$: Observable<Comment[]>;
 
   constructor(protected authenticationService: AuthenticationService,
               private route: ActivatedRoute,
@@ -42,7 +46,13 @@ export class CommentListComponent implements OnInit {
     this.roomShortId = this.route.snapshot.paramMap.get('roomId');
     this.roomId = localStorage.getItem(`roomId`);
     this.getComments();
-    this.translateService.use(localStorage.getItem('currentLang'));
+     this.comments$ = this.searchTerms.pipe(
+      debounceTime(100),
+      distinctUntilChanged(),
+      // switch to new search observable each time the term changes
+      switchMap((term: string) => this.commentService.searchComments(this.roomId, term)),
+    ); 
+    this.translateService.use(localStorage.getItem('currentLang')); 
   }
 
   getComments(): void {
@@ -64,4 +74,15 @@ export class CommentListComponent implements OnInit {
       this.notification.show(`Comment '${comment.subject}' successfully deleted.`);
     });
   }
+
+  searchx(term: string): void {
+    term = term.trim().toLowerCase();
+    this.comments.filter(c => {
+       c.subject.toLowerCase().includes(term);
+    });
+  }
+
+  search(term: string): void {
+    this.searchTerms.next(term);
+  }
 }
diff --git a/src/app/services/http/comment.service.ts b/src/app/services/http/comment.service.ts
index 8f404e05b..ffa639f7f 100644
--- a/src/app/services/http/comment.service.ts
+++ b/src/app/services/http/comment.service.ts
@@ -1,5 +1,5 @@
 import { Injectable } from '@angular/core';
-import { HttpClient, HttpHeaders } from '@angular/common/http';
+import { HttpClient, HttpHeaders, HttpParams } from '@angular/common/http';
 import { Observable } from 'rxjs';
 import { Comment } from '../../models/comment';
 import { catchError, tap } from 'rxjs/operators';
@@ -17,14 +17,14 @@ export class CommentService extends BaseHttpService {
     find: '/find'
   };
 
-  constructor( private http: HttpClient ) {
+  constructor(private http: HttpClient) {
     super();
   }
 
   getComment(commentId: string): Observable<Comment> {
-    const connectionUrl = `${ this.apiUrl.base }${ this.apiUrl.comment }/~${ commentId }`;
+    const connectionUrl = `${this.apiUrl.base}${this.apiUrl.comment}/~${commentId}`;
     return this.http.get<Comment>(connectionUrl, httpOptions).pipe(
-      tap (_ => ''),
+      tap(_ => ''),
       catchError(this.handleError<Comment>('addComment'))
     );
   }
@@ -32,18 +32,19 @@ export class CommentService extends BaseHttpService {
   addComment(comment: Comment): Observable<Comment> {
     const connectionUrl = this.apiUrl.base + this.apiUrl.comment + '/';
     return this.http.post<Comment>(connectionUrl,
-      { roomId: comment.roomId, subject: comment.subject, body: comment.body,
+      {
+        roomId: comment.roomId, subject: comment.subject, body: comment.body,
         read: comment.read, creationTimestamp: comment.creationTimestamp
       }, httpOptions).pipe(
-      tap (_ => ''),
-      catchError(this.handleError<Comment>('addComment'))
-    );
+        tap(_ => ''),
+        catchError(this.handleError<Comment>('addComment'))
+      );
   }
 
   deleteComment(commentId: string): Observable<Comment> {
-    const connectionUrl = `${ this.apiUrl.base + this.apiUrl.comment }/${ commentId }`;
+    const connectionUrl = `${this.apiUrl.base + this.apiUrl.comment}/${commentId}`;
     return this.http.delete<Comment>(connectionUrl, httpOptions).pipe(
-      tap (_ => ''),
+      tap(_ => ''),
       catchError(this.handleError<Comment>('deleteComment'))
     );
   }
@@ -54,11 +55,27 @@ export class CommentService extends BaseHttpService {
       properties: { roomId: roomId },
       externalFilters: {}
     }, httpOptions).pipe(
-      tap (_ => ''),
+      tap(_ => ''),
       catchError(this.handleError<Comment[]>('getComments', []))
     );
   }
 
+  searchComments(roomId: string, term:string): Observable<Comment[]> {
+    const connectionUrl = this.apiUrl.base + this.apiUrl.comment + this.apiUrl.find;
+    term = term.trim();
+
+    // Add safe, URL encoded search parameter if there is a search term
+    const options = term ?
+      { params: new HttpParams().set('subject', term) } : {};
+    return this.http.post<Comment[]>(connectionUrl, {
+      properties: { roomId: roomId },
+      externalFilters: {}
+    }, options).pipe(
+      tap(_ => ''),
+      catchError(this.handleError<Comment[]>('getComments', []))
+    );
+ } 
+
   updateComment(comment: Comment): Observable<any> {
     const connectionUrl = this.apiUrl + this.apiUrl.comment + '/' + comment.id;
     return this.http.put(connectionUrl, comment, httpOptions).pipe(
@@ -66,4 +83,5 @@ export class CommentService extends BaseHttpService {
       catchError(this.handleError<any>('updateComment'))
     );
   }
+
 }
diff --git a/src/assets/i18n/creator/de.json b/src/assets/i18n/creator/de.json
index bbae8df7d..fc217ecfe 100644
--- a/src/assets/i18n/creator/de.json
+++ b/src/assets/i18n/creator/de.json
@@ -1,9 +1,9 @@
 {
   "home-page": {
     "create-session": "Session erstellen",
-    "no-empty-name": "Bitte geben Sie einen Namen ein.",
+    "no-empty-name": "Bitte geben Sie einen Namen ein",
     "created-1": "Session '",
-    "created-2": "' erfolgreich erstellt."
+    "created-2": "' erfolgreich erstellt"
   },
   "room-page": {
     "comments": "Kommentare",
@@ -15,7 +15,7 @@
     "sure": "Sind Sie sicher?",
     "reallySession": "Wollen Sie die Session ",
     "reallyContent": "Wollen Sie die Frage ",
-    "really2": " wirklich löschen? Diese Aktion kann nicht rückgängig gemacht werden.",
+    "really2": " wirklich löschen? Diese Aktion kann nicht rückgängig gemacht werden",
     "abort": "Abbrechen",
     "update": "Update",
     "default-content-group": "Standard",
@@ -36,27 +36,27 @@
     "actions": "Optionen",
     "reset": "Zurücksetzen",
     "contents": "Fragen",
-    "submitted": "Frage erstellt. Bereit für die Erstellung neuer Fragen.",
-    "no-empty": "Keine leeren Felder erlaubt. Bitte überprüfen sie Thema und Inhalt.",
-    "no-empty2": "Keine leeren Felder erlaubt.",
-    "only-one": "Im Single-Choice-Modus ist nur eine Antwort erlaubt.",
-    "same-answer": "Zweimal die selbe Antwort ist nicht erlaubt.",
-    "changes-made": "Änderungen gespeichert.",
-    "answer-deleted": "Antwort gelöscht.",
-    "answer-recovered": "Antwort wiederhergestellt.",
-    "only-one-true": "Im Single-Modus ist nur eine richtige Antwort erlaubt.",
-    "reset-all": "Alle Eingaben wurden zurückgesetzt.",
-    "need-answers": "Auswahlfragen brauchen Antworten. Bitte fügen Sie Antworten hinzu.",
-    "select-one": "Im Single-Choice-Modus muss es eine richtige Antwort geben.",
-    "at-least-one": "Im Multiple-Choice-Modus muss es mindestens eine richtige Antwort geben.",
+    "submitted": "Frage erstellt. Bereit für die Erstellung neuer Fragen",
+    "no-empty": "Keine leeren Felder erlaubt. Bitte überprüfen sie Thema und Inhalt",
+    "no-empty2": "Keine leeren Felder erlaubt",
+    "only-one": "Im Single-Choice-Modus ist nur eine Antwort erlaubt",
+    "same-answer": "Zweimal die selbe Antwort ist nicht erlaubt",
+    "changes-made": "Änderungen gespeichert",
+    "answer-deleted": "Antwort gelöscht",
+    "answer-recovered": "Antwort wiederhergestellt",
+    "only-one-true": "Im Single-Modus ist nur eine richtige Antwort erlaubt",
+    "reset-all": "Alle Eingaben wurden zurückgesetzt",
+    "need-answers": "Auswahlfragen brauchen Antworten. Bitte fügen Sie Antworten hinzu",
+    "select-one": "Im Single-Choice-Modus muss es eine richtige Antwort geben",
+    "at-least-one": "Im Multiple-Choice-Modus muss es mindestens eine richtige Antwort geben",
     "undo": "Rückgängig",
     "points": "Punkte",
     "delete": "Löschen",
     "abort": "Abbrechen",
     "delete-answer": "Antwort löschen",
     "edit-answer": "Antwort bearteiten",
-    "content-deleted": "Frage wurde gelöscht.",
-    "content-updated": "Frage wurde aktualisiert."
+    "content-deleted": "Frage wurde gelöscht",
+    "content-updated": "Frage wurde aktualisiert"
   },
   "session": {
     "session-name": "Name der Session",
@@ -70,7 +70,7 @@
     "answers": "Antworten",
     "percentage": "Prozent",
     "abstentions": "Enthaltungen",
-    "no-questions": "Es sind noch keine Antworten vorhanden.",
+    "no-questions": "Es sind noch keine Antworten vorhanden",
     "good": "Gut",
     "improvable": "Luft nach oben",
     "no-answers": "Keine Antworten"
diff --git a/src/assets/i18n/creator/en.json b/src/assets/i18n/creator/en.json
index f1c72bc9b..5e41476d2 100644
--- a/src/assets/i18n/creator/en.json
+++ b/src/assets/i18n/creator/en.json
@@ -1,9 +1,9 @@
 {
   "home-page": {
     "create-session": "Create session",
-    "no-empty-name": "Please enter a name.",
+    "no-empty-name": "Please enter a name",
     "created-1": "Session '",
-    "created-2": "' successfully created."
+    "created-2": "' successfully created"
   },
   "room-page": {
     "comments": "Comments",
@@ -15,7 +15,7 @@
     "sure": "Are you sure?",
     "reallySession": "Do you really want to delete session ",
     "reallyContent": "Do you really want to delete content ",
-    "really2": "? This action can not be undone.",
+    "really2": "? This action can not be undone",
     "abort": "Abort",
     "update": "Update",
     "default-content-group": "Default",
@@ -26,8 +26,8 @@
     "content": "Content",
     "create": "Create",
     "collection": "Collection",
-    "body": "Body",
-    "subject": "Subject",
+    "body": "Content",
+    "subject": "Title",
     "yes": "Yes",
     "no": "No",
     "add-answer": "Add answer",
@@ -35,42 +35,42 @@
     "answers": "Answers",
     "actions": "Options",
     "reset": "Reset",
-    "contents": "Contents",
-    "submitted": "Content submitted. Ready for creation of new content.",
-    "no-empty": "No empty fields allowed. Please check subject and body.",
-    "no-empty2": "No empty filed allowed.",
-    "only-one": "In single choice mode is only 1 true answer allowed.",
-    "same-answer": "Same answer label is not allowed.",
-    "changes-made": "Changes are made.",
-    "answer-deleted": "Answer deleted.",
-    "answer-recovered": "Answer recovered.",
-    "only-one-true": "In single mode is only 1 true answer allowed.",
-    "reset-all": "Reset all inputs.",
-    "need-answers": "Choice content needs answers. Please add some answers.",
-    "select-one": "In single choice mode you have to select 1 true answer.",
-    "at-least-one": "In multiple choice mode you have to select at least 1 true answer.",
+    "contents": "Questions",
+    "submitted": "Question submitted. Ready to create new questions",
+    "no-empty": "No empty fields allowed. Please check subject and body",
+    "no-empty2": "No empty fields allowed",
+    "only-one": "In single choice mode, only one answer is allowed",
+    "same-answer": "Duplicate answers are not allowed",
+    "changes-made": "Changes saved",
+    "answer-deleted": "Answer deleted",
+    "answer-recovered": "Answer recovered",
+    "only-one-true": "In single mode, only one correct answer is allowed",
+    "reset-all": "Reset all inputs",
+    "need-answers": "Choice content needs answers. Please enter your answers",
+    "select-one": "In single choice mode, only one answer is correct",
+    "at-least-one": "In multiple choice mode, at least one answer is correct",
     "undo": "Undo",
     "points": "Points",
     "delete": "Delete",
     "abort": "Abort",
     "delete-answer": "Delete answer",
     "edit-answer": "Edit answer",
-    "content-deleted": "Content has been deleted.",
-    "content-updated": "Content has been updated."
+    "content-deleted": "Question deleted",
+    "content-updated": "Question updated"
   },
   "session": {
     "session-name": "Session name",
     "description": "Description",
-    "max-ls": "Max. letters / signs:",
+    "max-ls": "Max. characters:",
     "create-session": "Create session"
   },
   "statistic": {
-    "content": "Content",
-    "answer-statistic": "Answer statistic",
+    "content": "Question",
+    "answer-statistic": "Answer statistics",
     "answers": "Answers",
     "percentage": "Percentage",
     "abstentions": "Abstentions",
-    "no-questions": "There are no answers yet.",
+    "no-questions": "There are no answers yet",
     "good": "Good",
     "improvable": "Improvable",
     "no-answers": "No answers"
diff --git a/src/assets/i18n/home/de.json b/src/assets/i18n/home/de.json
index 891968049..c6f2e078e 100644
--- a/src/assets/i18n/home/de.json
+++ b/src/assets/i18n/home/de.json
@@ -18,25 +18,25 @@
 	},
 	"home-page": {
 		"join-demo-session": "Demo-Session betreten",
-		"session-id": "Session-Id",
-		"no-room-found": "Es wurde keine Session mit dieser ID gefunden.",
-		"please-enter": "Bitte geben Sie eine Session-ID ein.",
-		"exactly-8": "Eine Session-ID hat genau 8 Ziffern.",
+		"session-id": "Session-ID",
+		"no-room-found": "Es wurde keine Session mit dieser ID gefunden",
+		"please-enter": "Bitte geben Sie eine Session-ID ein",
+		"exactly-8": "Eine Session-ID hat genau 8 Ziffern",
 		"create-session": "Session erstellen",
-		"no-empty-name": "Bitte geben Sie einen Namen ein.",
+		"no-empty-name": "Bitte geben Sie einen Namen ein",
 		"created-1": "Session '",
-		"created-2": "' erfolgreich erstellt.",
-		"only-numbers": "Eine Session-Id besteht aus Nummern."
+		"created-2": "' erfolgreich erstellt",
+		"only-numbers": "Eine Session-ID besteht aus Ziffern"
 	},
 	"login": {
-		"email": "E-Mail",
-		"email-invalid": "E-Mail Adresse ist ungültig",
-		"email-required": "E-Mail Adresse ist erforderlich",
+		"email": "E-mail",
+		"email-invalid": "E-mail Adresse ist ungültig",
+		"email-required": "E-mail Adresse ist erforderlich",
 		"guest-login": "Anmelden als Gast",
-		"input-incorrect": "Bitte prüfen Sie Ihre Eingaben.",
-		"login-successful": "Login erfolgreich.",
+		"input-incorrect": "Bitte prüfen Sie Ihre Eingaben",
+		"login-successful": "Login erfolgreich",
 		"login": "Anmelden",
-		"login-data-incorrect": "Benutzername oder Passwort nicht korrekt.",
+		"login-data-incorrect": "Benutzername oder Passwort nicht korrekt",
 		"password": "Passwort",
 		"password-required": "Passwort ist erforderlich",
 		"activate": "Aktivieren",
@@ -45,26 +45,26 @@
 		"activation-key-incorrect": "Aktivierungsschlüssel falsch"
 	},
 	"password-reset": {
-		"email": "E-Mail",
-		"email-invalid": "E-Mail Adresse ist nicht gültig.",
-		"email-required": "E-Mail Adresse ist erforderlich.",
-		"input-incorrect": "Bitte prüfen Sie Ihre Eingabe.",
+		"email": "E-mail",
+		"email-invalid": "E-mail Adresse ist ungültig.",
+		"email-required": "E-mail Adresse ist erforderlich.",
+		"input-incorrect": "Bitte prüfen Sie Ihre Eingaben",
 		"reset-password": "Passwort zurücksetzen",
-		"reset-successful": "Passwort wurde zurückgesetzt. Bitte prüfen Sie Ihre E-Mails"
+		"reset-successful": "Passwort wurde zurückgesetzt. Bitte prüfen Sie Ihre E-mails"
 	},
 	"register": {
-		"email": "E-Mail",
-		"email-verify": "E-Mail bestätigen",
-		"email-invalid": "E-Mail Adresse ist nicht gültig",
-		"email-required": "E-Mail Adresse ist erforderlich",
-		"email-unmatch": "E-Mail Adressen stimmen nicht überein",
+		"email": "E-mail",
+		"email-verify": "E-mail bestätigen",
+		"email-invalid": "E-mail Adresse ist ungültig",
+		"email-required": "E-mail Adresse ist erforderlich",
+		"email-unmatch": "E-mail Adressen stimmen nicht überein",
 		"password": "Passwort",
 		"password-required": "Passwort ist erforderlich",
 		"password-unmatch": "Passwörter stimmen nicht überein",
 		"password-verify": "Passwort bestätigen",
 		"register": "Registrieren",
-		"register-successful": "Erfolgreich registriert. Bitte prüfen Sie Ihre E-Mails",
-		"register-unsuccessful": "Bitte prüfen Sie Ihre Eingaben."
+		"register-successful": "Erfolgreich registriert. Bitte prüfen Sie Ihre E-mails",
+		"register-unsuccessful": "Bitte prüfen Sie Ihre Eingaben"
 	},
 	"session": {
 		"session-name": "Name der Session",
@@ -75,7 +75,7 @@
   "footer": {
     "dsgvo": "DSGVO",
     "imprint": "Impressum",
-    "will-open": " wird in einem neuen Fenster geöffnet..",
+    "will-open": " wird in einem neuen Fenster geöffnet...",
     "open": "Öffnen"
   }
 }
diff --git a/src/assets/i18n/home/en.json b/src/assets/i18n/home/en.json
index dcb2f0c79..6025d8644 100644
--- a/src/assets/i18n/home/en.json
+++ b/src/assets/i18n/home/en.json
@@ -4,7 +4,7 @@
 		"german": "German",
 		"logout": "Logout",
 		"guest": "Guest",
-		"logged-out": "Logout successful.",
+		"logged-out": "Logout successful",
 		"back": "Back",
 		"my-sessions": "My Sessions",
 		"visited-sessions": "Visited Sessions"
@@ -18,64 +18,64 @@
 	},
 	"home-page": {
 		"join-demo-session": "Join demo-session",
-		"session-id": "Session-Id",
-		"no-room-found": "No session was found with this id.",
-		"please-enter": "Please enter a session-id.",
-		"exactly-8": "A session-id has exactly 8 digits.",
+		"session-id": "Session-ID",
+		"no-room-found": "No session was found with this ID",
+		"please-enter": "Please enter a session-ID",
+		"exactly-8": "A session-ID has exactly 8 digits",
 		"create-session": "Create session",
 		"no-empty-name": "Please enter a name.",
 		"created-1": "Session '",
-		"created-2": "' successfully created.",
-		"only-numbers": "A session-id only contains numbers."
+		"created-2": "' successfully created",
+		"only-numbers": "A session-ID only contains digits"
 	},
 	"login": {
-		"email": "E-Mail",
-		"email-invalid": "E-Mail is invalid",
-		"email-required": "E-Mail is required",
+		"email": "E-mail",
+		"email-invalid": "E-mail is invalid",
+		"email-required": "E-mail required",
 		"guest-login": "Guest login",
-		"input-incorrect": "Please check your data.",
-		"login-successful": "Login successful.",
+		"input-incorrect": "Please check your data",
+		"login-successful": "Login successful",
 		"login": "Login",
-		"login-data-incorrect": "Username or password incorrect.",
+		"login-data-incorrect": "Username or password incorrect",
 		"password": "Password",
-		"password-required": "Password is required",
+		"password-required": "Password required",
 		"activate": "Activate",
 		"activation-key": "Activation key",
 		"activation-key-required": "Activation key required",
-		"activation-key-incorrect": "Activation key is wrong"
+		"activation-key-incorrect": "Activation key is incorrect"
 	},
 	"password-reset": {
-		"email": "E-Mail",
-		"email-invalid": "E-Mail is not valid",
-		"email-required": "E-Mail is required",
-		"input-incorrect": "Please check your data.",
+		"email": "E-mail",
+		"email-invalid": "E-mail is invalid",
+		"email-required": "E-mail required",
+		"input-incorrect": "Please check your data",
 		"reset-password": "Reset password",
-		"reset-successful": "Password was reset. Please check your mail."
+		"reset-successful": "Password was reset. Please check your mail"
 	},
 	"register": {
-		"email": "E-Mail",
-		"email-verify": "Verify E-Mail",
-		"email-invalid": "E-Mail is not valid",
-		"email-required": "E-Mail is required",
-		"email-unmatch": "E-Mails do not match",
+		"email": "E-mail",
+		"email-verify": "Verify E-mail",
+		"email-invalid": "E-mail is invalid",
+		"email-required": "E-mail required",
+		"email-unmatch": "E-mails do not match",
 		"password": "Password",
-		"password-required": "Password is required",
+		"password-required": "Password required",
 		"password-unmatch": "Passwords do not match",
 		"password-verify": "Verify password",
 		"register": "Register",
-		"register-successful": "Successfully registered. Please check your mail.",
-		"register-unsuccessful": "Please check your data."
+		"register-successful": "Successfully registered. Please check your mail",
+		"register-unsuccessful": "Please check your data"
 	},
 	"session": {
 		"session-name": "Session name",
 		"description": "Description",
-		"max-ls": "Max. letters / signs:",
+		"max-ls": "Max. characters:",
 		"create-session": "Create session"
 	},
   "footer": {
     "dsgvo": "GDPR",
     "imprint": "Imprint",
-    "will-open": " will be opened in a new tab..",
+    "will-open": " will be opened in a new tab...",
     "open": "Open"
   }
 }
diff --git a/src/assets/i18n/participant/de.json b/src/assets/i18n/participant/de.json
index 8b0a48001..37260531e 100644
--- a/src/assets/i18n/participant/de.json
+++ b/src/assets/i18n/participant/de.json
@@ -1,8 +1,8 @@
 {
   "home-page": {
-    "no-room-found": "Es wurde keine Session mit dieser ID gefunden.",
-    "please-enter": "Bitte geben Sie eine Session-ID ein.",
-    "exactly-8": "Eine Session-ID hat genau 8 Ziffern."
+    "no-room-found": "Es wurde keine Session mit dieser ID gefunden",
+    "please-enter": "Bitte geben Sie eine Session-ID ein",
+    "exactly-8": "Eine Session-ID hat genau 8 Ziffern"
   },
   "room-page": {
     "comments": "Kommentare",
@@ -18,19 +18,19 @@
     "enter-title": "Titel",
     "enter-comment": "Kommentar",
     "send": "Senden",
-    "error-comment": "Bitte geben Sie ein Kommentar ein!",
-    "error-title": "Bitte geben Sie einen Titel ein!",
-    "error-both-fields": "Bitte füllen Sie alle Felder aus!"
+    "error-comment": "Bitte geben Sie einen Kommentartext ein",
+    "error-title": "Bitte geben Sie einen Titel ein",
+    "error-both-fields": "Bitte füllen Sie alle Felder aus"
   },
   "answer": {
     "submit": "Absenden",
     "abstain": "Enthalten",
-    "sent": "Antwort gesendet.",
-    "abstention-sent": "Enthaltung gesendet.",
+    "sent": "Antwort gesendet",
+    "abstention-sent": "Enthaltung gesendet",
     "your-answer": "Ihre Antwort",
-    "at-least-one": "Bitte wählen sie mindestens eine Antwort.",
-    "please-one": "Bitte wählen sie eine Antwort.",
-    "please-answer": "Bitte geben sie eine Antwort ein."
+    "at-least-one": "Bitte wählen sie mindestens eine Antwort",
+    "please-one": "Bitte wählen sie eine Antwort",
+    "please-answer": "Bitte geben sie eine Antwort ein"
   },
   "statistic": {
     "content": "Frage",
@@ -38,7 +38,7 @@
     "answers": "Antworten",
     "percentage": "Prozent",
     "abstentions": "Enthaltungen",
-    "no-questions": "Es sind noch keine Antworten vorhanden.",
+    "no-questions": "Es sind noch keine Antworten vorhanden",
     "good": "Gut",
     "improvable": "Luft nach oben",
     "no-answers": "Keine Antworten"
diff --git a/src/assets/i18n/participant/en.json b/src/assets/i18n/participant/en.json
index 2fb39ac9d..7afd3e440 100644
--- a/src/assets/i18n/participant/en.json
+++ b/src/assets/i18n/participant/en.json
@@ -1,8 +1,8 @@
 {
   "home-page": {
-    "no-room-found": "No session was found with this id.",
-    "please-enter": "Please enter a session-id.",
-    "exactly-8": "A session-id has exactly 8 digits."
+    "no-room-found": "No session was found with this ID",
+    "please-enter": "Please enter a session-ID",
+    "exactly-8": "A session-ID has exactly 8 digits"
   },
   "room-page": {
     "comments": "Comments",
@@ -18,20 +18,19 @@
     "enter-title": "Title",
     "enter-comment": "Comment",
     "send": "Send",
-    "zgu":"hfjf",
-    "error-title": "Please enter a title!",
-    "error-comment": "Please enter a comment!",
-    "error-both-fields": "Please fill in all fields!"
+    "error-title": "Please enter a title",
+    "error-comment": "Please enter a comment-text",
+    "error-both-fields": "Please fill in all fields"
   },
   "answer": {
     "submit": "Submit",
     "abstain": "Abstain",
-    "sent": "Answer sent.",
-    "abstention-sent": "Abstention sent.",
+    "sent": "Answer sent",
+    "abstention-sent": "Abstention sent",
     "your-answer": "Your answer",
-    "at-least-one": "Please select at least one answer.",
-    "please-one": "Please select an answer.",
-    "please-answer": "Please enter an answer."
+    "at-least-one": "Please select at least one answer",
+    "please-one": "Please select an answer",
+    "please-answer": "Please enter an answer"
   },
   "statistic": {
     "content": "Content",
@@ -39,7 +38,7 @@
     "answers": "Answers",
     "percentage": "Percentage",
     "abstentions": "Abstentions",
-    "no-questions": "There are no answers yet.",
+    "no-questions": "There are no answers yet",
     "good": "Good",
     "improvable": "Improvable",
     "no-answers": "No answers"
diff --git a/src/theme/_theme.scss b/src/theme/_theme.scss
index a13ef7ac2..24c076011 100644
--- a/src/theme/_theme.scss
+++ b/src/theme/_theme.scss
@@ -15,8 +15,6 @@ html, body {
   $progress-primary: mat-palette($mat-light-green, 300);
   $progress-accent: mat-palette($mat-amber, 300);
   $progress-warn:  mat-palette($mat-deep-orange, 300);
-
   $progress-theme: mat-light-theme($progress-primary, $progress-accent, $progress-warn);
-
   @include angular-material-theme($progress-theme);
 }
-- 
GitLab