mirror of
https://github.com/zadam/trilium.git
synced 2025-11-11 15:55:52 +01:00
chore(react): start rendering nodes in note map
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
import { NoteMapLink, NoteMapPostResponse } from "@triliumnext/commons";
|
||||
import server from "../../services/server";
|
||||
import { NodeObject } from "force-graph";
|
||||
import { LinkObject, NodeObject } from "force-graph";
|
||||
|
||||
type MapType = "tree" | "link";
|
||||
|
||||
@@ -11,13 +11,22 @@ interface GroupedLink {
|
||||
names: string[];
|
||||
}
|
||||
|
||||
interface Node extends NodeObject {
|
||||
export interface Node extends NodeObject {
|
||||
id: string;
|
||||
name: string;
|
||||
type: string;
|
||||
color: string;
|
||||
}
|
||||
|
||||
export interface Link extends LinkObject<NodeObject> {
|
||||
id: string;
|
||||
name: string;
|
||||
x: number;
|
||||
y: number;
|
||||
source: Node;
|
||||
target: Node;
|
||||
}
|
||||
|
||||
export interface NotesAndRelationsData {
|
||||
nodes: Node[];
|
||||
links: {
|
||||
|
||||
Reference in New Issue
Block a user