(core) Adding onNewRecord event for custom widgets

Summary:
New onNewRecord event in custom widgets that is triggered
when the user selects a blank row.

Together with this diff there is PR for grist-help https://github.com/gristlabs/grist-help/pull/150

Test Plan: added test case

Reviewers: cyprien

Reviewed By: cyprien

Differential Revision: https://phab.getgrist.com/D3375
This commit is contained in:
Jarosław Sadziński
2022-04-11 21:33:26 +02:00
parent cedcdc6bff
commit 4401ec4d79
4 changed files with 16 additions and 4 deletions

View File

@@ -63,7 +63,7 @@ declare module "app/client/components/BaseView" {
public isTruncated: ko.Observable<boolean>;
public tableModel: DataTableModel;
constructor(gristDoc: GristDoc, viewSectionModel: any);
constructor(gristDoc: GristDoc, viewSectionModel: any, options?: {addNewRow?: boolean, isPreview?: boolean});
public setCursorPos(cursorPos: CursorPos): void;
public createFilterMenu(ctl: IOpenController, filterInfo: FilterInfo, onClose?: () => void): HTMLElement;
public buildTitleControls(): DomArg;