core/dynamic-forms/file/file.type.component.ts
FieldType
changeDetection | ChangeDetectionStrategy.OnPush |
selector | c8y-field-file |
templateUrl | ./file.type.component.html |
Properties |
|
Methods |
ngOnInit |
ngOnInit()
|
Returns :
void
|
Static Readonly CONFIG |
Type : ConfigOption
|
Default value : {
types: [
{
name: 'file',
component: FieldFile
}
]
}
|
dropArea |
Type : DropAreaComponent
|
Decorators :
@ViewChild('dropArea', {static: true})
|
Readonly dropAreaInputs |
Type : string[]
|
Default value : [
'title',
'message',
'icon',
'loadingMessage',
'alwaysShow',
'clickToOpen',
'loading',
'progress',
'maxAllowedFiles',
'files',
'accept'
]
|
<div class="form-group" role="group" [attr.aria-labelledby]="id + '-fieldset'">
<label id="{{ id + '-fieldset' }}" *ngIf="to.label || to.description">
{{ to.label | humanize }}
<button
*ngIf="to.description"
class="btn-clean text-14 m-l-4"
[popover]="to.description"
placement="right"
[outsideClick]="true"
type="button"
>
<i c8yIcon="question-circle-o" class="text-info"></i>
</button>
</label>
<c8y-drop-area #dropArea class="drop-area-sm" [formControl]="formControl"> </c8y-drop-area>
<div
class="form-control-feedback-message has-error"
role="alert"
*ngIf="showError && formControl.errors"
>
<formly-validation-message [field]="field"></formly-validation-message>
</div>
</div>