UNPKG

ngx-schema-forms

Version:

New features: - Ajv schema validator. - Angular forms compatible: Property tree is created using FormGroup, FormArray and FormControl classes. - Array now properly loads initial data from model. - WidgetTyep: WidgetRegistry now supports WidgetType, now wo

43 lines (42 loc) 1.81 kB
import { AfterContentInit, QueryList, ElementRef, SimpleChanges, OnChanges, EventEmitter } from '@angular/core'; import { ValidatorFn } from '@angular/forms'; import { ActionRegistry } from '../../model/actionregistry'; import { SchemaPropertyType } from '../../schema'; import { TemplateSchemaService } from '../template-schema.service'; import { ButtonComponent } from '../button/button.component'; import { FieldParent } from './field-parent'; import { Field } from './field'; import { ItemComponent } from './item/item.component'; import { TemplateSchemaElementRegistry } from '../template-schema-element-registry'; export declare class FieldComponent extends FieldParent implements Field, OnChanges, AfterContentInit { private elementRef; private templateSchemaService; protected templateRegistry: TemplateSchemaElementRegistry; protected actionRegistry: ActionRegistry; childFields: QueryList<FieldComponent>; childItems: QueryList<ItemComponent>; childButtons: QueryList<ButtonComponent>; name: string; type: SchemaPropertyType; format: string; required: boolean; readOnly: boolean; title: string; description: string; placeholder: string; widget: string | object; validators: ValidatorFn | ValidatorFn[]; schema: any; changes: EventEmitter<{}>; constructor(elementRef: ElementRef, templateSchemaService: TemplateSchemaService, templateRegistry: TemplateSchemaElementRegistry, actionRegistry: ActionRegistry); getSchema(): any; getValidators(): { path: string; validators: ValidatorFn | ValidatorFn[]; }[]; register(parentFieldPath?: string): void; ngOnChanges(changes: SimpleChanges): void; private getOneOf(); private setTitleFromContent(); ngAfterContentInit(): void; }