json-tree-view-vue3
Version:
JSON tree rendering Vue3 component
33 lines • 1.05 kB
TypeScript
export declare enum ItemType {
OBJECT = 0,
ARRAY = 1,
VALUE = 2
}
export type PrimitiveTypes = string | number | boolean | null;
export interface SelectedData {
key: string;
value: PrimitiveTypes;
path: string;
}
export type ItemData = {
key: string;
type: ItemType;
path: string;
depth: number;
length?: number;
children?: ItemData[];
value?: PrimitiveTypes;
};
export type Props = {
data: ItemData;
maxDepth?: number;
canSelect?: boolean;
};
declare const __VLS_export: import("vue").DefineComponent<Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {} & {
selected: (value: SelectedData) => any;
}, string, import("vue").PublicProps, Readonly<Props> & Readonly<{
onSelected?: ((value: SelectedData) => any) | undefined;
}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
declare const _default: typeof __VLS_export;
export default _default;
//# sourceMappingURL=JsonTreeViewItem.vue.d.ts.map