Skip to content

Commit c0b828a

Browse files
Merge branch '2024_sem2' into Colours
2 parents f5fb40c + 2c1ecee commit c0b828a

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

58 files changed

+19807
-18965
lines changed

.idea/.name

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.idea/workspace.xml

Lines changed: 40 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Binary file not shown.

package-lock.json

Lines changed: 17236 additions & 18314 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -66,13 +66,13 @@
6666
"denque": "^2.0.1",
6767
"framer-motion": "^4.0.0",
6868
"lodash": "^4.17.21",
69-
"prop-types": "^15.7.2",
69+
"prop-types": "^15.8.1",
7070
"react": "^17.0.2",
7171
"react-dom": "^17.0.2",
7272
"react-markdown": "^5.0.0",
7373
"react-resize-detector": "^6.6.0",
7474
"react-router-dom": "^5.2.0",
75-
"react-scripts": "^4.0",
75+
"react-scripts": "^5.0.1",
7676
"react-table": "^7.5.0",
7777
"reactjs-popup": "^2.0.5",
7878
"remark-gfm": "^1.0.0",
@@ -83,7 +83,7 @@
8383
},
8484
"devDependencies": {
8585
"@babel/plugin-proposal-private-property-in-object": "^7.21.11",
86-
"electron": "^15.0.0",
86+
"electron": "^31.4.0",
8787
"enzyme": "^3.11.0",
8888
"eslint": "^7.11.0",
8989
"eslint-plugin-import": "^2.28.1",
@@ -96,4 +96,3 @@
9696
"run-script-os": "^1.1.6"
9797
}
9898
}
99-

src/algorithms/controllers/AStar.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ export default {
2121
};
2222
},
2323

24-
run(chunker, {edgeValueMatrix, coordsMatrix, startNode, endNodes, heuristicFn}) {
24+
run(chunker, {edgeValueMatrix, coordsMatrix, startNode, endNodes, heuristicFn, moveNode}) {
2525
// String Variables used in displaying algo
2626
const algNameStr = 'aStar';
2727
const dashStr = '-';
@@ -130,6 +130,7 @@ export default {
130130
(vis, edgeArray, coordsArray) => {
131131
vis.graph.directed(false);
132132
vis.graph.weighted(true);
133+
vis.graph.moveNodeFn(moveNode);
133134
vis.graph.set(edgeArray, Array.from({ length: numVertices }, (v, k) => (k + 1)),coordsArray);
134135
},
135136
[E, coords]

src/algorithms/controllers/BFS.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ export default {
1818
};
1919
},
2020

21-
run(chunker, { edgeValueMatrix, coordsMatrix, endNodes, startNode}) {
21+
run(chunker, { edgeValueMatrix, coordsMatrix, endNodes, startNode, moveNode}) {
2222

2323
//Defining queue
2424
function Queue() {
@@ -70,6 +70,7 @@ export default {
7070
(vis, edgeArray, coordsArray) => {
7171
vis.graph.directed(false);
7272
vis.graph.weighted(false);
73+
vis.graph.moveNodeFn(moveNode);
7374
vis.graph.set(edgeArray, Array.from({ length: edgeValueMatrix.length }, (v, k) => (k + 1)), coordsArray);
7475

7576
},

src/algorithms/controllers/DFS.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ export default {
2121
};
2222
},
2323

24-
run(chunker, { edgeValueMatrix, coordsMatrix, endNodes, startNode}) {
24+
run(chunker, { edgeValueMatrix, coordsMatrix, endNodes, startNode, moveNode}) {
2525

2626
const E = [...edgeValueMatrix];
2727
const coords = [...coordsMatrix];
@@ -50,6 +50,7 @@ export default {
5050
(vis, edgeArray, coordsArray) => {
5151
vis.graph.directed(false);
5252
vis.graph.weighted(false);
53+
vis.graph.moveNodeFn(moveNode);
5354
vis.graph.set(edgeArray, Array.from({ length: edgeValueMatrix.length }, (v, k) => (k + 1)), coordsArray);
5455

5556
},

src/algorithms/controllers/DFSrec.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ export default {
2525
};
2626
},
2727

28-
run(chunker, { edgeValueMatrix, coordsMatrix, startNode, endNodes}) {
28+
run(chunker, { edgeValueMatrix, coordsMatrix, startNode, endNodes, moveNode}) {
2929
// String Variables used in displaying algo
3030
const algNameStr = 'DFSrec';
3131
const nStr = 'n';
@@ -241,6 +241,7 @@ export default {
241241
(vis, edgeArray, coordsArray) => {
242242
vis.graph.directed(false);
243243
vis.graph.weighted(false);
244+
vis.graph.moveNodeFn(moveNode);
244245
vis.graph.set(edgeArray, Array.from({ length: numVertices }, (v, k) => (k + 1)),coordsArray);
245246
},
246247
[E, coords], 0

src/algorithms/controllers/TTFTreeInsertion.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -347,6 +347,7 @@ export default {
347347
},
348348

349349
run(chunker, { nodes }) {
350+
350351
if (nodes === null || nodes.length === 0) return;
351352
let { node: tree, id: newID } = this.createNodeAndIncrement(null);
352353

0 commit comments

Comments
 (0)