]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blame - client/src/app/shared/shared-forms/input-text.component.html
Handle input error in custom input text
[github/Chocobozzz/PeerTube.git] / client / src / app / shared / shared-forms / input-text.component.html
CommitLineData
4c8749cb 1<div class="input-group">
1916c966
C
2 <input
3 [id]="inputId" [autocomplete]="autocomplete" [value]="value" [placeholder]="placeholder" [tabindex]="tabindex"
f1c86172 4 [(ngModel)]="value" (ngModelChange)="update()" [readonly]="readonly"
1916c966 5 #input (click)="input.select()" (input)="update()" (change)="update()" [type]="inputType" class="form-control"
75084782 6 [ngClass]="{ 'input-error': formError }"
1916c966 7 />
f8b530e0 8
93c728a2 9 <button *ngIf="withToggle" (click)="toggle()" type="button" class="btn btn-outline-secondary" [title]="toggleTitle">
dc1296a9
C
10 <my-global-icon *ngIf="show" iconName="eye-open"></my-global-icon>
11 <my-global-icon *ngIf="!show" iconName="eye-close"></my-global-icon>
4c8749cb 12 </button>
1916c966 13
4c8749cb
C
14 <button
15 *ngIf="withCopy" [cdkCopyToClipboard]="input.value" (click)="activateCopiedMessage()" type="button"
16 class="btn btn-outline-secondary text-uppercase" i18n-title title="Copy"
17 >
b15fcd49 18 <my-global-icon iconName="copy"></my-global-icon>
4c8749cb
C
19 <span class="copy-text">Copy</span>
20 </button>
f8b530e0 21</div>
75084782
C
22
23<div *ngIf="formError" class="form-error">{{ formError }}</div>