-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Adiciona comentarios na tela do video
- Loading branch information
1 parent
5b1cba7
commit f9436e7
Showing
3 changed files
with
112 additions
and
24 deletions.
There are no files selected for viewing
45 changes: 35 additions & 10 deletions
45
src/app/pages/video-viewer/video-comment/video-comment.component.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,36 @@ | ||
<div> | ||
|
||
<form [formGroup]="commentForm" (submit)="addComment()" class="text-center"> | ||
|
||
<textarea name="comment" placeholder="Adicione um comentário" type="text" formControlName="comment" required> </textarea> | ||
<button class="w-20 h-8 bg-blue-brand rounded-lg justify-center my-8 text-white md:h-10 md:w-32" type="submit">Adicionar comentário</button> | ||
|
||
|
||
</form> | ||
|
||
</div> | ||
<div *ngIf="userId"> | ||
<form [formGroup]="commentForm" (submit)="addComment()" class="text-center"> | ||
<textarea | ||
name="comment" | ||
placeholder="Adicione um comentário" | ||
type="text" | ||
formControlName="comment" | ||
required | ||
> | ||
</textarea> | ||
<button | ||
class="w-20 h-8 bg-blue-brand rounded-lg justify-center my-8 text-white md:h-10 md:w-32" | ||
type="submit" | ||
> | ||
Adicionar comentário | ||
</button> | ||
</form> | ||
</div> | ||
<div *ngIf="!userId"> | ||
<p class="text-center">Faça login para comentar</p> | ||
</div> | ||
<div *ngFor="let comment of comments" class="flex"> | ||
<div> | ||
<div> | ||
{{ comment.user_name }} | ||
</div> | ||
<div> | ||
<p>{{ comment.content }}</p> | ||
</div> | ||
<div> | ||
<p>{{ comment.created_at }}</p> | ||
</div> | ||
</div> | ||
</div> | ||
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters