Skip to content

Instantly share code, notes, and snippets.

@takuya-nakayasu
Created December 24, 2018 11:11
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save takuya-nakayasu/3c970a9723495e818f7b8d9e421fc441 to your computer and use it in GitHub Desktop.
Save takuya-nakayasu/3c970a9723495e818f7b8d9e421fc441 to your computer and use it in GitHub Desktop.
質問フォームのテンプレート
<div class="container">
<mat-card class="question-card">
<mat-card-header>
<mat-card-title class="question-title">YES/NO形式の質問をどうぞ!</mat-card-title>
</mat-card-header>
<mat-card-content>
<form class="question-form" [formGroup]="questionForm">
<!-- 質問の入力フォーム -->
<mat-form-field class="input-field">
<input matInput placeholder="質問(文の最後に?をつけてください)"
id="question" name="question" formControlName="question">
<mat-error *ngIf="questionForm.controls.question.errors?.isNoQuestionMark">
文末に?をつけてください
</mat-error>
</mat-form-field>
</form>
</mat-card-content>
</mat-card>
</div>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment