Closed axelpale closed 11 months ago
Issue https://github.com/taataa/tapspace/issues/105 was caused because content was removed in the middle of a gesture. The forgetting of content should happen only after gestures have ended.
Solving the issue #113 will probably show us how to do this.
Do we need a general depth-limited graph search algorithm?
Consider we have a tree structure where the nodes can be opened (a leaf becomes a parent for a bunch of new leaves) or closed (the children of the nodes are removed so the node becomes a leaf). Consider also a graph-based UI with a single focal point. Let the focal node be the one closest to the center of the viewport, at the tree-depth most suitable for the current scale.
The question is: when the focal node changes, how we determine which nodes to open or close.
Graph traversal libs:
Good ones are hard to find!
An approach we used in Taataa, videograph example, and a school-project that starts with S:
Three layers:
In other words:
If the view moves, we must:
Two cases, let us call them:
For the case LINKED, an algorithm:
The async fetching should be cancellable to prevent unnecessary async API calls.
For the case COORDINATED, an algorithm:
Assume there exists one-to-one mapping between ids and coordinates.
Init
Solved in tapspace 2.0.0-alpha.16 or so with tapspace.loaders.TreeLoader.
Tools that help in connecting tapspace front-end to backends with so much data that only a fraction can be downloaded and rendered at once.
Approaches
Propositions