Skip to content

Commit eecd7e1

Browse files
XinMoZJarrettChen217
authored andcommitted
Merge: merging the current dev update (oct 11)
2 parents 50c6642 + 212185e commit eecd7e1

Some content is hidden

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

43 files changed

+3200
-107
lines changed

package-lock.json

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

package.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,4 +97,3 @@
9797
"run-script-os": "^1.1.6"
9898
}
9999
}
100-

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/collapseChunkPlugin.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
// below, otherwise hooks into what happens when blocks are expanded or
88
// contracted are not enabled.
99
const importsThis = ['quickSort', 'quickSortM3', 'msort_arr_td',
10-
'transitiveClosure', 'heapSort'];
10+
'transitiveClosure', 'heapSort', 'msort_lista_td'];
1111

1212
// eslint-disable-next-line import/no-cycle
1313
// See also accompanying mods/hooks in src/context/GlobalState.js and

src/algorithms/controllers/dijkstra.js

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

20-
run(chunker, { edgeValueMatrix, coordsMatrix, startNode, endNodes}) {
20+
run(chunker, { edgeValueMatrix, coordsMatrix, startNode, endNodes, moveNode}) {
2121
// String Variables used in displaying algo
2222
const algNameStr = 'dijkstra';
2323
const dashStr = '-';
@@ -115,6 +115,7 @@ export default {
115115
(vis, edgeArray, coordsArray) => {
116116
vis.graph.directed(false);
117117
vis.graph.weighted(true);
118+
vis.graph.moveNodeFn(moveNode);
118119
vis.graph.set(edgeArray, Array.from({ length: numVertices }, (v, k) => (k + 1)),coordsArray);
119120
},
120121
[E, coords]

src/algorithms/controllers/graphSearchColours.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,10 @@
33
//
44
// OMG, colors for array and graph require different types and are
55
// inconsistent!
6-
// Arrary: '0'=Blue, '1'=Green
6+
// Array: '0'=Blue, '1'=Green
77
// Nodes: 1=Green, 4= Blue
88
// Edges: 1=Green, 2=Orange, 3=Red, 4=Blue
9-
// XXX not sure how this interracts with color perception options -
9+
// XXX not sure how this interacts with color perception options -
1010
// doesn't seem to work like this - should figure out how it's done if
1111
// it's still supported
1212
export const colors = {

src/algorithms/controllers/index.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ export { default as heapSort } from './heapSort';
44
export { default as quickSort } from './quickSort';
55
export { default as quickSortM3 } from './quickSortM3';
66
export { default as msort_arr_td } from './msort_arr_td';
7+
export { default as msort_lista_td } from './msort_lista_td';
78
export { default as transitiveClosure } from './transitiveClosure';
89
export { default as bruteForceStringSearch } from './bruteForceStringSearch';
910
export { default as horspoolStringSearch } from './horspoolStringSearch';

0 commit comments

Comments
 (0)