Commit Graph

6 Commits

Author SHA1 Message Date
Luke De Feo
3891a5d61b Introduce selection for elements in z stack aka target mode
Summary:
The old layout plugins target mode would ask you which view you wanted to select when you clicked, the visualiser currently chooses for you based on size of the element.

Sometimes this isnt what you want so I have added a context menu with all the intersecting nodes from which you can select or focus

Reviewed By: lblasa

Differential Revision: D47589789

fbshipit-source-id: 9c9d0d7587b830aa72089267d9bcf2b687142574
2023-07-26 03:22:38 -07:00
Luke De Feo
957a336349 UID refactor 4/ Expose readonly UIState
Summary:
Currently state writes can either go through a named handler that is easy to find and debug or they can directly modify the state.

By exposing readonly atoms only we ensure that all state writes go through a UIACtions. This adds consistency and ease of future debugging.

E.g We could add a utility to wrap all ui actions with logging statements

Reviewed By: antonk52

Differential Revision: D47547531

fbshipit-source-id: f88651169d8e7c5f7e31068d64f9aa5b6b573647
2023-07-21 07:17:31 -07:00
Luke De Feo
f3f5018f71 Add No source found state and error state
Summary: Note There is currently an issue with myles https://fb.workplace.com/groups/myles.search/permalink/1446945366079946/?notif_id=1688467057742844&notif_t=video_processed&ref=notif

Reviewed By: lblasa

Differential Revision: D47210290

fbshipit-source-id: 584435922610e5138a6c14543163fcf3a347a727
2023-07-10 09:22:39 -07:00
Luke De Feo
33ebe05126 Add icons to context menu
Summary: So pretty

Reviewed By: lblasa

Differential Revision: D47210293

fbshipit-source-id: 592dde396d43e4af30e38cab6a198e2153cfbf30
2023-07-10 09:22:39 -07:00
Luke De Feo
6bb541a33f Group app wide ui state into one object
Summary: Should be a bit easier to see what UI state we are holding at the plugin instance level

Reviewed By: lblasa

Differential Revision: D41498272

fbshipit-source-id: 6d88086766efd9c39f71be7e2ce32c5058494c96
2022-11-24 09:23:16 -08:00
Luke De Feo
7fc64adfd4 Refactor out UI debugger menu item
Summary: We have to do a couple of odd things to get the context menu items to behave. The code was duplicated between tree and visualizer. This custom component removes duplication and makes the approach a bit clearer (via js doc)

Reviewed By: antonk52

Differential Revision: D41495718

fbshipit-source-id: ec98d5101e636a2c9034c656d29991d4fe348762
2022-11-24 09:23:16 -08:00