ohayolibs
Version:
Ohayo is a set of essential modules for ohayojp.
38 lines (36 loc) • 1.2 kB
HTML
<sf-item-wrap [id]="id" [schema]="schema" [ui]="ui" [showError]="showError" [error]="error" [showTitle]="schema.title">
<ng-template
<input
nz-input
[]="id"
[]="disabled"
[]="disabled"
[]="ui.size"
[]="ui.borderless"
[]="value"
(ngModelChange)="change($event)"
[]="schema.maxLength || null"
[]="ui.type || 'text'"
[]="ui.placeholder"
[]="ui.autocomplete"
[]="ui.autofocus"
(keyup.enter)="enter($event)"
(focus)="focus($event)"
(blur)="blur($event)"
/>
</ng-template>
<ng-container *ngIf="type === 'addon'; else ipt">
<nz-input-group
[]="ui.addOnBefore"
[]="ui.addOnAfter"
[]="ui.addOnBeforeIcon"
[]="ui.addOnAfterIcon"
[]="ui.prefix"
[]="ui.prefixIcon"
[]="ui.suffix"
[]="ui.suffixIcon"
>
<ng-template [ngTemplateOutlet]="ipt"></ng-template>
</nz-input-group>
</ng-container>
</sf-item-wrap>