mirror of
https://github.com/andwati/zitadel.git
synced 2026-11-11 16:45:13 +00:00
fix(console): better error messages (#5409)
* fix(console): better error messages * fix: fix i18n error labels * rollout cnsl-i18n-errors * move errors to form-field * fix: form control errors * rollout validators * translate * replace variables * lint * self review * fix confirm validation * use help observable * fix validation errors * cleanup * custom validator for idp templates * lint * validate on blur * remove element --------- Co-authored-by: Max Peintner <[email protected]>
This commit is contained in:
co-authored by
Max Peintner
parent
e00cc187fa
commit
93e1fe0056
@@ -0,0 +1,20 @@
|
||||
<div class="cnsl-form-field-wrapper" (click)="_control.onContainerClick && _control.onContainerClick($event)">
|
||||
<ng-content select="cnsl-label"></ng-content>
|
||||
<div class="cnsl-rel" #inputContainer>
|
||||
<ng-content></ng-content>
|
||||
<ng-content select="cnslSuffix"></ng-content>
|
||||
</div>
|
||||
<ng-container *ngIf="help$ && help$ | async as help">
|
||||
<div [ngSwitch]="help.type" class="cnsl-form-field-subscript-wrapper">
|
||||
<div *ngSwitchCase="'hints'" class="cnsl-form-field-hint-wrapper" [@transitionMessages]="_subscriptAnimationState">
|
||||
<ng-content select="cnsl-hint"></ng-content>
|
||||
</div>
|
||||
<div *ngSwitchCase="'errors'" class="cnsl-form-field-error-wrapper" [@transitionMessages]="_subscriptAnimationState">
|
||||
<span cnslError *ngFor="let err of help.validationErrors">
|
||||
{{ err.i18nKey | translate : err.params }}
|
||||
</span>
|
||||
<ng-content select="cnsl-error"></ng-content>
|
||||
</div>
|
||||
</div>
|
||||
</ng-container>
|
||||
</div>
|
||||
Reference in New Issue
Block a user