Project

General

Profile

Update TreeView » History » Version 4

Tomislav Pleše, 10/02/2025 12:45 PM

1 1 Tomislav Pleše
# Update TreeView
2 2 Tomislav Pleše
3
4 3 Tomislav Pleše
CASES
5 2 Tomislav Pleše
1. Root Creation
6
2. Root Parent - Directly Under Root
7
3. Root Parent - Under Regular Point
8
4. Root-Shard Parent - Under Regular Point
9
5. Child-Shard Parent - Under Regular Point
10 1 Tomislav Pleše
6. Root Parent - Root Initial Sharding
11
7. Root-Shard Parent - Root 2nd Sharding
12
8. Regular Child - Regular Point Initial Sharding
13
9. Child-Shard Parent - Regular Point 2nd Sharding   
14 3 Tomislav Pleše
15
16
FLOW
17
18 4 Tomislav Pleše
SCREEN: HomeScreen <-> TreeSliverThread <-> TreeSliverItem
19
20
21
1. Root Creation
22
1. 1. There is a text input field and a submit button on the screen
23
1. 2. User writes a prompt and presses submit button
24
1. 3. App creates new Point 
25
26 2 Tomislav Pleše
27
28
29
In my flutter app I have Point model (from which a node in tree view is created). There is a regular Point, and there is a Shard Point. Shard Point is the one that has one or more ShardDTOs in it's shardList list. Shards are created by sharding: user enters sub-prompt, and from that new Shard is created and added to shardsList.
30
31
I have already implemented a flow for handling Prompts for regular Points. It goes:
32
PromptInputField -> HomeScreen -> HomeScreenManager -> ThreadManager -> PointManager (when there is no Sharding).
33
34
I now want to implement a flow that will handle sub-Prompts (which creates Shard Points), where the flow would go:
35
PromptInputField -> HomeScreen -> HomeScreenManager -> ThreadManager -> ShardManager (when there is Sharding (creation of new Shards)). There can be use of existing methods in PointManager where applicable, but main logic should reside in the ShardManager.
36
37
The branching between Sharding and No Sharding flows is currently in the HomeScreenManger in the method: handlePrompt(). Try to see if it should stay there, or should be moved to the ThreadManager.
38
39
Look at my code and suggest minimal changes that will make this work.