UNPKG

@formio/angular

Version:

This library was generated with [Angular CLI](https://github.com/angular/angular-cli) version 10.1.4.

186 lines (173 loc) 7.62 kB
import * as i0 from '@angular/core'; import { EventEmitter, OnInit, OnDestroy, ChangeDetectorRef, NgZone } from '@angular/core'; import { FormioAuthService } from '@formio/angular/auth'; import * as i10 from '@angular/router'; import { ActivatedRoute, Router, Routes } from '@angular/router'; import * as i8 from '@formio/angular'; import { FormioAppConfig, FormioAlerts, FormioPromiseService, FormioRefreshValue } from '@formio/angular'; import { Subscription } from 'rxjs'; import * as i7 from '@angular/common'; import * as i9 from '@formio/angular/grid'; interface FormioResourceRouteConfig { index?: any; create?: any; resource?: any; view?: any; edit?: any; delete?: any; } declare class FormioResourceConfig { name: string; form: string; parents: any[]; static ɵfac: i0.ɵɵFactoryDeclaration<FormioResourceConfig, never>; static ɵprov: i0.ɵɵInjectableDeclaration<FormioResourceConfig>; } interface FormioResourceMap { [name: string]: any; } declare class FormioResources { auth?: FormioAuthService; resources: FormioResourceMap; error: EventEmitter<any>; onError: EventEmitter<any>; constructor(auth?: FormioAuthService); static ɵfac: i0.ɵɵFactoryDeclaration<FormioResources, never>; static ɵprov: i0.ɵɵInjectableDeclaration<FormioResources>; } declare class FormioResourceService { appConfig: FormioAppConfig; config: FormioResourceConfig; resourcesService: FormioResources; initialized: boolean; form: any; alerts: FormioAlerts; resource: any; resourceUrl?: string; formUrl: string; formFormio: FormioPromiseService; formio: FormioPromiseService; refresh: EventEmitter<FormioRefreshValue>; resourceResolve: any; resourceReject: any; resourceLoaded?: Promise<any>; resourceLoading?: Promise<any>; resourceId?: string; resources: any; ready?: Promise<any>; readyResolve: any; readyReject: any; formLoading?: Promise<any>; formLoaded: Promise<any>; formResolve: any; formReject: any; isLoading: boolean; constructor(appConfig: FormioAppConfig, config: FormioResourceConfig, resourcesService: FormioResources); initialize(): void; setResource(resourceId: any): void; init(route: ActivatedRoute): Promise<any>; onError(error: any): void; onFormError(err: any): void; loadForm(): Promise<any>; loadParents(): Promise<any>; onSubmissionError(err: any): void; loadResource(): Promise<any>; save(resource: any): Promise<any>; remove(): Promise<void>; static ɵfac: i0.ɵɵFactoryDeclaration<FormioResourceService, [null, null, { optional: true; }]>; static ɵprov: i0.ɵɵInjectableDeclaration<FormioResourceService>; } declare class FormioResourceComponent implements OnInit, OnDestroy { service: FormioResourceService; route: ActivatedRoute; auth: FormioAuthService; router: Router; perms: { delete: boolean; edit: boolean; }; routerSubscription: Subscription; constructor(service: FormioResourceService, route: ActivatedRoute, auth: FormioAuthService, router: Router); ngOnInit(): void; ngOnDestroy(): void; init(): Promise<any>; static ɵfac: i0.ɵɵFactoryDeclaration<FormioResourceComponent, never>; static ɵcmp: i0.ɵɵComponentDeclaration<FormioResourceComponent, "ng-component", never, {}, {}, never, never, false, never>; } declare class FormioResourceViewComponent implements OnDestroy { service: FormioResourceService; config: FormioResourceConfig; constructor(service: FormioResourceService, config: FormioResourceConfig); submission: { data: {}; }; ngOnDestroy(): void; static ɵfac: i0.ɵɵFactoryDeclaration<FormioResourceViewComponent, never>; static ɵcmp: i0.ɵɵComponentDeclaration<FormioResourceViewComponent, "ng-component", never, {}, {}, never, never, false, never>; } declare class FormioResourceEditComponent implements OnDestroy { service: FormioResourceService; route: ActivatedRoute; router: Router; config: FormioResourceConfig; triggerError: EventEmitter<any>; onSubmitDone: EventEmitter<object>; submission: { data: {}; }; constructor(service: FormioResourceService, route: ActivatedRoute, router: Router, config: FormioResourceConfig); onSubmit(submission: any): void; ngOnDestroy(): void; static ɵfac: i0.ɵɵFactoryDeclaration<FormioResourceEditComponent, never>; static ɵcmp: i0.ɵɵComponentDeclaration<FormioResourceEditComponent, "ng-component", never, {}, {}, never, never, false, never>; } declare class FormioResourceDeleteComponent { service: FormioResourceService; route: ActivatedRoute; router: Router; constructor(service: FormioResourceService, route: ActivatedRoute, router: Router); onDelete(): void; onCancel(): void; static ɵfac: i0.ɵɵFactoryDeclaration<FormioResourceDeleteComponent, never>; static ɵcmp: i0.ɵɵComponentDeclaration<FormioResourceDeleteComponent, "ng-component", never, {}, {}, never, never, false, never>; } declare class FormioResourceCreateComponent implements OnInit { service: FormioResourceService; route: ActivatedRoute; router: Router; config: FormioResourceConfig; onError: EventEmitter<any>; onSuccess: EventEmitter<any>; constructor(service: FormioResourceService, route: ActivatedRoute, router: Router, config: FormioResourceConfig); ngOnInit(): void; onSubmit(submission: any): void; static ɵfac: i0.ɵɵFactoryDeclaration<FormioResourceCreateComponent, never>; static ɵcmp: i0.ɵɵComponentDeclaration<FormioResourceCreateComponent, "ng-component", never, {}, {}, never, never, false, never>; } declare class FormioResourceIndexComponent implements OnInit { service: FormioResourceService; route: ActivatedRoute; router: Router; config: FormioResourceConfig; cdr: ChangeDetectorRef; ngZone: NgZone; gridSrc?: string; gridQuery: any; createText: String; constructor(service: FormioResourceService, route: ActivatedRoute, router: Router, config: FormioResourceConfig, cdr: ChangeDetectorRef, ngZone: NgZone); ngOnInit(): void; onSelect(row: any): void; onCreateItem(): void; static ɵfac: i0.ɵɵFactoryDeclaration<FormioResourceIndexComponent, never>; static ɵcmp: i0.ɵɵComponentDeclaration<FormioResourceIndexComponent, "ng-component", never, {}, {}, never, never, false, never>; } declare function FormioResourceRoutes(config?: FormioResourceRouteConfig): Routes; declare class FormioResource { static forChild(config?: FormioResourceRouteConfig): any; static forRoot(config?: FormioResourceRouteConfig): any; static ɵfac: i0.ɵɵFactoryDeclaration<FormioResource, never>; static ɵmod: i0.ɵɵNgModuleDeclaration<FormioResource, [typeof FormioResourceComponent, typeof FormioResourceCreateComponent, typeof FormioResourceIndexComponent, typeof FormioResourceViewComponent, typeof FormioResourceEditComponent, typeof FormioResourceDeleteComponent], [typeof i7.CommonModule, typeof i8.FormioModule, typeof i9.FormioGrid, typeof i10.RouterModule], never>; static ɵinj: i0.ɵɵInjectorDeclaration<FormioResource>; } export { FormioResource, FormioResourceComponent, FormioResourceConfig, FormioResourceCreateComponent, FormioResourceDeleteComponent, FormioResourceEditComponent, FormioResourceIndexComponent, FormioResourceRoutes, FormioResourceService, FormioResourceViewComponent, FormioResources }; //# sourceMappingURL=index.d.ts.map