forked from appsemble/appsemble
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathnodePositions.ts
More file actions
27 lines (25 loc) · 1.04 KB
/
nodePositions.ts
File metadata and controls
27 lines (25 loc) · 1.04 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
import { type XYPosition } from 'reactflow';
/**
* Defines where the chapters should be placed on the grid
*/
export const chapterNodes: { id: string; position: XYPosition }[] = [
{ id: 'introduction', position: { x: 0, y: 0 } },
{ id: 'how-to-create-an-app', position: { x: 0, y: 200 } },
{ id: 'data-flow', position: { x: 0, y: 500 } },
{ id: 'storing-data', position: { x: 0, y: 700 } },
{ id: 'data-transformation', position: { x: -200, y: 1050 } },
{ id: 'styling-apps', position: { x: 200, y: 1050 } },
{ id: 'basic-app', position: { x: 0, y: 1400 } },
];
/**
* Defines the connections that get drawn between chapters
*/
export const chapterEdges: { from: string; to: string }[] = [
{ from: 'introduction', to: 'how-to-create-an-app' },
{ from: 'how-to-create-an-app', to: 'data-flow' },
{ from: 'data-flow', to: 'storing-data' },
{ from: 'storing-data', to: 'data-transformation' },
{ from: 'storing-data', to: 'styling-apps' },
{ from: 'styling-apps', to: 'basic-app' },
{ from: 'data-transformation', to: 'basic-app' },
];