/
Visualiser Integration Redesign

Visualiser Integration Redesign

  • decide approach with updating timeline slider later

  • use common div for visualiser canvas so we don’t have many components that do the same thing

  • use redux / useContext for handlers to remove prop drilling

  • declare handlers in VisualiserController

  • try removing inline styles if possible

  • splitting up large components into smaller components which are in the same context

  • in GUIMode folder experiment with removing nesting

  • move commandsInputRules.ts and executableCommands.ts and simplify and put in visualiser-src

  • reduce number of files we need to change to add an operation

visualiser-src Refactoring

  • Realised that the initialiser class and concept is basically useless

    • Every method is a wrapper around another method from a different class.

    • We can just make the AnimationController store the current GraphicalDataStructure instead, and have the UI interact with the controller.

  • Current thoughts are:

    • Put doOperation method in AnimationController

      • Takes in a command (string) and arguments (numbers).

      • Returns an error message or empty string if successful. We can also make it throw an exception which can be caught in the executeCommand handler function.

      • Confirm with Edward’s branch which errors to check for.

    • Put applyTopicTitle in AnimationController

      • A new data structure is set every time topic title changes.

  • We still need to figure out how to deal with the documentation.

    • Put it in a separate file?

    • Put it in the same file as the GraphicalDataStructure?