/** * @name @ethicdevs/json-tree-view * @license MIT * @maintainer * @forked-from <前端通過元素展示Json樹狀資料,因, https://github.com/yuda-lyu/w-jsonview-tree> * @itself-forked-from <沒有加入預先展開數據功能,自己下載來修改, https://github.com/pgrabovets/json-view> */ declare type JsonObject = Record; declare type JSONTreeNode = { key: null | string; parent: null | JSONTreeNode; value: null | string; expanded: boolean; type: null | "array" | "string" | "number" | "bigint" | "boolean" | "symbol" | "undefined" | "object" | "function"; children: null | JSONTreeNode[]; elem: null | Element; depth: number; setCaretIconRight(): void; setCaretIconDown(): void; hideChildren(): void; showChildren(): void; toggle(): void; }; /** * @export * @param {Object} jsonObj 輸入Json物件 * @param {Element} rootElem 輸入初始化元素 * @param {Object} [option={}] 輸入設定物件,預設為空物件 * @param {Boolean} [option.expanded=false] 輸入是否預先展開,預設為false */ export declare function renderJSONTreeView(jsonObj: JsonObject, rootElem: Element, options?: { expanded?: boolean; }): JSONTreeNode; export {};