@progress/kendo-angular-listview
Version:
Kendo UI Angular listview component
61 lines (60 loc) • 1.83 kB
TypeScript
/**-----------------------------------------------------------------------------------------
* Copyright © 2025 Progress Software Corporation. All rights reserved.
* Licensed under commercial license. See LICENSE.md in the project root for more information
*-------------------------------------------------------------------------------------------*/
import { EventEmitter, NgZone } from '@angular/core';
import { FormGroup } from '@angular/forms';
import { Observable } from 'rxjs';
import * as i0 from "@angular/core";
/**
* @hidden
*/
export type Entity = {
index: number;
group: any;
};
/**
* @hidden
*/
export type CommandAction = 'edit' | 'remove' | 'cancel' | 'save' | 'add';
/**
* @hidden
*/
export type CommandEvent = {
action: CommandAction;
formGroup?: FormGroup;
isNew?: boolean;
itemIndex?: number;
};
/**
* @hidden
*/
export declare class EditService {
ngZone: NgZone;
changes: EventEmitter<CommandEvent>;
changed: Observable<any>;
private editedIndices;
private newItem;
private changedSource;
constructor(ngZone: NgZone);
editItem(index: number, group?: any): void;
addItem(group: any): void;
isEditing(): boolean;
get hasNewItem(): boolean;
get newDataItem(): any;
get newItemGroup(): FormGroup;
editGroup(index: number): any;
close(index?: number): void;
context(index?: number): Entity;
isEdited(index: number): boolean;
hasEdited(index: number): boolean;
beginEdit(itemIndex: number): void;
beginAdd(): void;
endEdit(itemIndex?: number): void;
save(itemIndex?: number): void;
remove(itemIndex: number): void;
private findByIndex;
private onChanged;
static ɵfac: i0.ɵɵFactoryDeclaration<EditService, never>;
static ɵprov: i0.ɵɵInjectableDeclaration<EditService>;
}