UNPKG

alinea

Version:

[![npm](https://img.shields.io/npm/v/alinea.svg)](https://npmjs.org/package/alinea) [![install size](https://packagephobia.com/badge?p=alinea)](https://packagephobia.com/result?p=alinea)

25 lines (24 loc) 778 B
import { AsyncTreeDataLoader, DropTarget, ItemInstance } from '@headless-tree/core'; import { EntryPhase } from 'alinea/core'; export declare function rootId(rootName: string): string; export interface EntryTreeItem { id: string; index: string; entries: Array<{ id: string; entryId: string; type: string; title: string; phase: EntryPhase; locale: string | null; workspace: string; root: string; path: string; parentPaths: Array<string>; }>; isFolder?: boolean; children: Array<string>; } export declare function useEntryTreeProvider(): AsyncTreeDataLoader<EntryTreeItem> & { onDrop(items: Array<ItemInstance<EntryTreeItem>>, target: DropTarget<EntryTreeItem>): void; };