-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
234 lines (218 loc) · 6.87 KB
/
index.html
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
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8" />
<meta name="description" content="" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<link rel="preconnect" href="https://fonts.googleapis.com" />
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin />
<link
href="https://fonts.googleapis.com/css2?family=Source+Code+Pro:wght@200&family=Source+Sans+Pro&display=swap"
rel="stylesheet"
/>
<title>Force Graph</title>
<link rel="stylesheet" href="stylesheets/style.css" />
<link
href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0-alpha1/dist/css/bootstrap.min.css"
rel="stylesheet"
integrity="sha384-GLhlTQ8iRABdZLl6O3oVMWSktQOp6b7In1Zl3/Jr59b6EGGoI1aFkw7cmDA6j6gD"
crossorigin="anonymous"
/>
<link
rel="stylesheet"
href="https://cdnjs.cloudflare.com/ajax/libs/codemirror/6.65.7/codemirror.min.css"
/>
<link
rel="stylesheet"
href="https://cdnjs.cloudflare.com/ajax/libs/codemirror/6.65.7/theme/dracula.min.css"
/>
<link rel="stylesheet" href="stylesheets/autocomplete.css" />
</head>
<body>
<div class="split left">
<div class="left-1">
<div class="mb-4">
<button type="button" id="save-btn" class="btn btn-success">
Save
</button>
<button type="button" id="cpy-btn" class="btn btn-light">
Copy to clipboard
</button>
<button type="button" id="pst-btn" class="btn btn-light">
Try import from clipboard
</button>
<button type="button" id="clr-btn" class="btn btn-warning">
Clear
</button>
</div>
<div class="row g-1 mb-2">
<div class="col-md-4">
<input
type="text"
class="form-control"
id="add-node-id"
placeholder="id"
/>
</div>
<div class="col-md-4">
<input
type="number"
class="form-control"
id="add-node-grp"
placeholder="group"
/>
</div>
<div class="col">
<button
class="btn btn-outline-secondary"
type="button"
id="add-node-btn"
>
Add Node
</button>
</div>
</div>
<div class="row g-1 mb-4">
<div class="col-md-4">
<input
type="text"
class="form-control"
id="add-link-src"
placeholder="source"
/>
</div>
<div class="col-md-4">
<input
type="text"
class="form-control"
id="add-link-tgt"
placeholder="target"
/>
</div>
<div class="col-md-2">
<input
type="number"
class="form-control"
id="add-link-val"
placeholder="value"
value="1"
/>
</div>
<div class="col">
<button
class="btn btn-outline-secondary"
type="button"
id="add-link-btn"
>
Add Link
</button>
</div>
</div>
<div class="row g-1 mb-2">
<div class="col-md-8">
<input
type="text"
class="form-control"
id="remove-node-id"
placeholder="node"
/>
</div>
<div class="col">
<button
class="btn btn-outline-danger"
type="button"
id="remove-node-btn"
>
Remove Node
</button>
</div>
</div>
<div class="row g-1 mb-4">
<div class="col-md-4">
<input
type="text"
class="form-control"
id="remove-link-src"
placeholder="source"
/>
</div>
<div class="col-md-4">
<input
type="text"
class="form-control"
id="remove-link-tgt"
placeholder="target"
/>
</div>
<div class="col">
<button
class="btn btn-outline-danger"
type="button"
id="remove-link-btn"
>
Remove Link
</button>
</div>
</div>
<div class="row g-1 mb-2">
<div class="col-md-4">
<input
type="text"
class="form-control"
id="rename-from"
placeholder="from"
/>
</div>
<div class="col-md-4">
<input
type="text"
class="form-control"
id="rename-to"
placeholder="to"
/>
</div>
<div class="col">
<button
class="btn btn-outline-secondary"
type="button"
id="rename-btn"
>
Rename
</button>
</div>
</div>
</div>
<div class="left-2">
<div id="data-editor"></div>
</div>
<div class="left-3">
<p id="status">Status</p>
</div>
</div>
<div class="split right">
<div class="right-topleft">
<input
type="checkbox"
class="btn-check"
id="3d-toggle"
autocomplete="off"
/>
<label class="btn btn-outline-primary" for="3d-toggle">3D</label><br />
</div>
<div id="graph"></div>
</div>
<script src="https://unpkg.com/three@0.148.0/build/three.js"></script>
<script src="https://unpkg.com/three-spritetext@1.6.5/dist/three-spritetext.min.js"></script>
<script src="https://unpkg.com/3d-force-graph@1.70.19/dist/3d-force-graph.min.js"></script>
<script src="https://unpkg.com/force-graph@1.42.18/dist/force-graph.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/codemirror/6.65.7/codemirror.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/codemirror/6.65.7/mode/javascript/javascript.min.js"></script>
<script
src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0-alpha1/dist/js/bootstrap.min.js"
integrity="sha384-mQ93GR66B00ZXjt0YO5KlohRA5SY2XofN4zfuZxLkoj1gXtW8ANNCe9d5Y3eG5eD"
crossorigin="anonymous"
></script>
<script src="https://cdn.jsdelivr.net/npm/@tarekraafat/autocomplete.js@10.2.7/dist/autoComplete.min.js"></script>
<script src="scripts/index.js"></script>
</body>
</html>