add new tree store interface
This commit is contained in:
11
src/Umbraco.Web.UI.Client/libs/store/tree-store.interface.ts
Normal file
11
src/Umbraco.Web.UI.Client/libs/store/tree-store.interface.ts
Normal file
@@ -0,0 +1,11 @@
|
||||
import type { Observable } from 'rxjs';
|
||||
|
||||
export interface UmbTreeStore<T> {
|
||||
appendItems: (items: Array<T>) => void;
|
||||
updateItem: (unique: string, item: Partial<T>) => void;
|
||||
removeItem: (unique: string) => void;
|
||||
|
||||
rootItems: () => Observable<Array<T>>;
|
||||
childrenOf: (parentUnique: string | null) => Observable<Array<T>>;
|
||||
treeItems: (uniques: Array<string>) => Observable<Array<T>>;
|
||||
}
|
||||
Reference in New Issue
Block a user