Summary: This diff includes minor changes to the pages within the Under the Hood section of Flipper Docs.
Reviewed By: passy
Differential Revision: D41521538
fbshipit-source-id: 35b372ffdde118faef2732e4cb7684fc9df18f87
Summary:
Bumps [rayon](https://github.com/rayon-rs/rayon) from 1.5.2 to 1.6.0.
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a href="https://github.com/rayon-rs/rayon/blob/master/RELEASES.md">rayon's changelog</a>.</em></p>
<blockquote>
<h1>Release rayon 1.6.0 / rayon-core 1.10.0 (2022-11-18)</h1>
<ul>
<li>The minimum supported <code>rustc</code> is now 1.56.</li>
<li>The new <code>IndexedParallelIterator::fold_chunks</code> and <code>fold_chunks_with</code> methods
work like <code>ParallelIterator::fold</code> and <code>fold_with</code> with fixed-size chunks of
items. This may be useful for predictable batching performance, without the
allocation overhead of <code>IndexedParallelIterator::chunks</code>.</li>
<li>New "broadcast" methods run a given function on all threads in the pool.
These run at a sort of reduced priority after each thread has exhausted their
local work queue, but before they attempt work-stealing from other threads.
<ul>
<li>The global <code>broadcast</code> function and <code>ThreadPool::broadcast</code> method will
block until completion, returning a <code>Vec</code> of all return values.</li>
<li>The global <code>spawn_broadcast</code> function and methods on <code>ThreadPool</code>, <code>Scope</code>,
and <code>ScopeFifo</code> will run detached, without blocking the current thread.</li>
</ul>
</li>
<li>Panicking methods now use <code>#[track_caller]</code> to report the caller's location.</li>
<li>Fixed a truncated length in <code>vec::Drain</code> when given an empty range.</li>
</ul>
<h2>Contributors</h2>
<p>Thanks to all of the contributors for this release!</p>
<ul>
<li><a href="https://github.com/cuviper"><code>@cuviper</code></a></li>
<li><a href="https://github.com/idanmuze"><code>@idanmuze</code></a></li>
<li><a href="https://github.com/JoeyBF"><code>@JoeyBF</code></a></li>
<li><a href="https://github.com/JustForFun88"><code>@JustForFun88</code></a></li>
<li><a href="https://github.com/kianmeng"><code>@kianmeng</code></a></li>
<li><a href="https://github.com/kornelski"><code>@kornelski</code></a></li>
<li><a href="https://github.com/ritchie46"><code>@ritchie46</code></a></li>
<li><a href="https://github.com/ryanrussell"><code>@ryanrussell</code></a></li>
<li><a href="https://github.com/steffahn"><code>@steffahn</code></a></li>
<li><a href="https://github.com/TheIronBorn"><code>@TheIronBorn</code></a></li>
<li><a href="https://github.com/willcrozi"><code>@willcrozi</code></a></li>
</ul>
<h1>Release rayon 1.5.3 (2022-05-13)</h1>
<ul>
<li>The new <code>ParallelSliceMut::par_sort_by_cached_key</code> is a stable sort that caches
the keys for each item -- a parallel version of <code>slice::sort_by_cached_key</code>.</li>
</ul>
<h1>Release rayon-core 1.9.3 (2022-05-13)</h1>
<ul>
<li>Fixed a use-after-free race in job notification.</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a href="60cdb43173"><code>60cdb43</code></a> Merge <a href="https://github-redirect.dependabot.com/rayon-rs/rayon/issues/686">https://github.com/facebook/flipper/issues/686</a></li>
<li><a href="efeeace277"><code>efeeace</code></a> Release rayon 1.2.0 / rayon-core 1.6.0</li>
<li><a href="d993d7a666"><code>d993d7a</code></a> Merge <a href="https://github-redirect.dependabot.com/rayon-rs/rayon/issues/683">https://github.com/facebook/flipper/issues/683</a></li>
<li><a href="2720d8d55b"><code>2720d8d</code></a> Merge <a href="https://github-redirect.dependabot.com/rayon-rs/rayon/issues/682">https://github.com/facebook/flipper/issues/682</a></li>
<li><a href="c6a294b62f"><code>c6a294b</code></a> impl ParallelExtend<()> for ()</li>
<li><a href="9bfb3c6d55"><code>9bfb3c6</code></a> clippy::inconsistent_digit_grouping</li>
<li><a href="3cd762e225"><code>3cd762e</code></a> clippy::toplevel_ref_arg</li>
<li><a href="b216c3e0eb"><code>b216c3e</code></a> Update bare traits to <code>dyn Trait</code></li>
<li><a href="58b0275a14"><code>58b0275</code></a> Once:new() is const-stable since Rust 1.24</li>
<li><a href="83b67e27f2"><code>83b67e2</code></a> Merge <a href="https://github-redirect.dependabot.com/rayon-rs/rayon/issues/673">https://github.com/facebook/flipper/issues/673</a></li>
<li>Additional commits viewable in <a href="https://github.com/rayon-rs/rayon/compare/v1.5.2...rayon-core-v1.6.0">compare view</a></li>
</ul>
</details>
<br />
[](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)
Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `dependabot rebase`.
[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)
---
<details>
<summary>Dependabot commands and options</summary>
<br />
You can trigger Dependabot actions by commenting on this PR:
- `dependabot rebase` will rebase this PR
- `dependabot recreate` will recreate this PR, overwriting any edits that have been made to it
- `dependabot merge` will merge this PR after your CI passes on it
- `dependabot squash and merge` will squash and merge this PR after your CI passes on it
- `dependabot cancel merge` will cancel a previously requested merge and block automerging
- `dependabot reopen` will reopen this PR if it is closed
- `dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
- `dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
- `dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
- `dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
</details>
Pull Request resolved: https://github.com/facebook/flipper/pull/4322
Reviewed By: antonk52
Differential Revision: D41472340
Pulled By: passy
fbshipit-source-id: 73924e9502283654444533f98d68d3edcc9d1c01
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
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
Summary: Added context menu to visualizer similar to what we have on the tree
Reviewed By: lblasa
Differential Revision: D41494948
fbshipit-source-id: 0cfa4c98b7a68462a7103ed1ce9eaaff8c99aeee
Summary: Mouse over event still fires for the dom nodes behind the context menu modal. This will cause state changes and rerenders. Some of the state the context menu depends on can change so it would cause the context menu items to change while its stil open. Now we dont fire those hover state changes while context menu active
Reviewed By: lblasa
Differential Revision: D41494947
fbshipit-source-id: 17918f15d74230d9c7070a4de7a0a0ce10a08001
Summary: If a node has a global negative offset (e.g from a view pager) its position will be outside of the visualizors bounds and could potentially be where the tree is. The user doesnt see the wireframes since overflow hidden is on the parent node. A situation can arise where when the mouse is over the tree the hit test returns an offscreen node and causes us to hover a random node rather than the tree node hover effect taking place. We are just adding a guard to say if the mouse is outside the dom rect for the root visualization node than dont run the hit test
Reviewed By: lblasa
Differential Revision: D41493001
fbshipit-source-id: ea7974de7f2b80126d52490526a21e2a3b487d3d
Summary: Introduced an outer div which is the size of the real root node so that focusing doesnt shift the UI.
Reviewed By: antonk52
Differential Revision: D41492999
fbshipit-source-id: 336104e5d18d773953e0a58a699acc7660c4045f
Summary: Added context menu to tree nodes that 'focuses' a node. This will make the node the root of the tree. Focus state can be removed again via context menu but we could add a permanent button in the future
Reviewed By: lblasa
Differential Revision: D41493002
fbshipit-source-id: 43ec7a25aeea0b169cbcbb1ac20ac22ea893fee2
Summary: In order to support focus mode we need to have only 1 snapshot. In practice this is the case but we are making this more apparant in this diff.
Reviewed By: lblasa
Differential Revision: D41493003
fbshipit-source-id: 19ed7213d15adaea4732f4ec60309efa8dae6f94
Summary: Out of the box the library search has some issues. when search matches it steals focus from the input. Eventually we want to customise the rendering of the tree items anyway so this lays the foundation for taht
Reviewed By: antonk52
Differential Revision: D41336524
fbshipit-source-id: 194f67023edd0675cd9bd8d6134260439c6b2785
Summary:
Bumps com.github.ben-manes.versions from 0.42.0 to 0.44.0.
[](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)
Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `dependabot rebase`.
[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)
---
<details>
<summary>Dependabot commands and options</summary>
<br />
You can trigger Dependabot actions by commenting on this PR:
- `dependabot rebase` will rebase this PR
- `dependabot recreate` will recreate this PR, overwriting any edits that have been made to it
- `dependabot merge` will merge this PR after your CI passes on it
- `dependabot squash and merge` will squash and merge this PR after your CI passes on it
- `dependabot cancel merge` will cancel a previously requested merge and block automerging
- `dependabot reopen` will reopen this PR if it is closed
- `dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
- `dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
- `dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
- `dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
</details>
Pull Request resolved: https://github.com/facebook/flipper/pull/4312
Reviewed By: antonk52
Differential Revision: D41472327
Pulled By: passy
fbshipit-source-id: 44caad58d885c2df2bb2a0124c3406b43016fd95
Summary:
Bumps espresso-intents from 3.4.0 to 3.5.0.
[](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)
Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `dependabot rebase`.
[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)
---
<details>
<summary>Dependabot commands and options</summary>
<br />
You can trigger Dependabot actions by commenting on this PR:
- `dependabot rebase` will rebase this PR
- `dependabot recreate` will recreate this PR, overwriting any edits that have been made to it
- `dependabot merge` will merge this PR after your CI passes on it
- `dependabot squash and merge` will squash and merge this PR after your CI passes on it
- `dependabot cancel merge` will cancel a previously requested merge and block automerging
- `dependabot reopen` will reopen this PR if it is closed
- `dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
- `dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
- `dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
- `dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
</details>
Pull Request resolved: https://github.com/facebook/flipper/pull/4310
Reviewed By: antonk52
Differential Revision: D41472303
Pulled By: passy
fbshipit-source-id: 89aa6aa62f5917c58b4ca7ce5a55099b971ad5c7
Summary:
Bumps rules from 1.4.0 to 1.5.0.
[](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)
Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `dependabot rebase`.
[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)
---
<details>
<summary>Dependabot commands and options</summary>
<br />
You can trigger Dependabot actions by commenting on this PR:
- `dependabot rebase` will rebase this PR
- `dependabot recreate` will recreate this PR, overwriting any edits that have been made to it
- `dependabot merge` will merge this PR after your CI passes on it
- `dependabot squash and merge` will squash and merge this PR after your CI passes on it
- `dependabot cancel merge` will cancel a previously requested merge and block automerging
- `dependabot reopen` will reopen this PR if it is closed
- `dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
- `dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
- `dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
- `dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
</details>
Pull Request resolved: https://github.com/facebook/flipper/pull/4311
Reviewed By: antonk52
Differential Revision: D41472307
Pulled By: passy
fbshipit-source-id: c2b9c7e771051c1098fd7c8fd1f38672e83db581
Summary:
There was an issue whereas snapshots were not properly rendered on retina devices.
After running a few tests, the issue seems to be solved by changing the snapshot format from jpeg to png.
Reviewed By: antonk52
Differential Revision: D41520939
fbshipit-source-id: 1563fe89162e41f71418357a7e58caaf46581f04
Summary: This diff includes minor changes to the pages within the Features section of Flipper Docs.
Reviewed By: passy
Differential Revision: D41471000
fbshipit-source-id: 0a414d1e5e0cff5d874d3fe6eab647c3877b9caf
Summary: This diff includes minor changes to the pages within the Setup section of Flipper Docs.
Reviewed By: mweststrate
Differential Revision: D41496698
fbshipit-source-id: a338931bd08e474ee348e25798463647f9a0be29
Summary: This diff includes minor changes to the pages within the Setup section of Flipper Docs.
Reviewed By: passy
Differential Revision: D41472932
fbshipit-source-id: 41894bba63a91e90869423af1d3635ac3fa0c20f
Summary: This diff includes minor changes to the pages within the Creating Plugins section of Flipper Docs.
Reviewed By: passy
Differential Revision: D41497503
fbshipit-source-id: 5c5718b63bfff18322b28b547724415ab40a1810
Summary:
^
IMHO, this is a better name.
... and secretly make it enabled by default
Reviewed By: LukeDefeo
Differential Revision: D41495973
fbshipit-source-id: f287a4beadb70587ff43ac896213a20746dd8c22
Summary:
Before this change, color inspector used a color picker that showed: color, rgba, hex.
The problem is that engineers have to click on it to see these values.
This change leaves the picker as is, but presents both hex and rgba inlined within the inspector thus avoiding extra interactions.
Reviewed By: antonk52
Differential Revision: D41495740
fbshipit-source-id: c8af01e3060d2e6725295418293b1e30679c1b1f
Summary: Set width of sidebar for `main` position in `MasterDetail`.
Reviewed By: mweststrate
Differential Revision: D41493698
fbshipit-source-id: a9f4804256a7ee46ed32f367e8b21ff57dd484e0
Summary:
^
In this case, the unknown value, which is a text will be displayed as sent by the client.
Reviewed By: antonk52
Differential Revision: D41494094
fbshipit-source-id: 9295e3f7e055a8ce9b430137600108a4cdf32c90
Summary: Due to litho component instances being immutable we are able to process them later if we hold on to the instance. We have added a Maybe deferred type which sort of resembles a Monad. It wraps a value which may or may not be calculated later.
Reviewed By: lblasa
Differential Revision: D41474251
fbshipit-source-id: 2ba6e688518dba55cf4aa5ba53f390a92cf0921f
Summary:
Enumeration used to be a type containing a single property value of type string.
The InspectableEnum is a type that had an Enumeration value and possible values.
As we removed possible values from the enum value, this structure no longer serves its purpose.
Reviewed By: antonk52
Differential Revision: D41400874
fbshipit-source-id: e5c2d1e15ee9b3074ddd69f75ee9b8150d44379f
Summary: Wanted to write about this for a while as we're reinventing the rules every time we get to this time of the year. :)
Reviewed By: LukeDefeo, antonk52
Differential Revision: D41434886
fbshipit-source-id: 445c6c259bee74874472cf246fdc209e82514fcd
Summary:
As metadata got split from attributes, raw data became harder to read.
This change annotates raw data with attribute names to ease readability and thus usability.
Reviewed By: antonk52
Differential Revision: D41400622
fbshipit-source-id: 8bebb2bd368490b9d7a2b4435749cdf0570b7571
Summary: If there are no attributes for a given section, display a 'No data available' message rather than having an empty panel.
Reviewed By: antonk52
Differential Revision: D41400252
fbshipit-source-id: 0337702f638b9b917e6b3be5962838d2eb15c20d
Summary:
Litho margins/padding/borders have the following attributes:
- left, top, right, bottom
- horizontal, vertical
- all
- start, end
This change processes these attributes and creates a SpaceBox inspectable which enables the margin visualiser in Flipper Desktop.
Reviewed By: LukeDefeo
Differential Revision: D41375299
fbshipit-source-id: be8bac1819f2b17c2fd1b1b86678aa0559278609
Summary: If we have a milliseconds portion of a date that's <100, we'd fill in zeroes in a symmetrical way (around the value) rather than filling in at the front, which led to some confusion.
Reviewed By: mweststrate
Differential Revision: D41342194
fbshipit-source-id: a8f60110dcad8bfa77b81abed88df0b0643c780e
Summary:
Before this change, possible values for an enumeration were embedded within the attribute value itself.
After this change, possible values are located within the attribute metadata.
Reviewed By: LukeDefeo
Differential Revision: D41337003
fbshipit-source-id: cef5654a679e9b961e82993abb201b518fcbcd00
Summary:
There were 2 situations where the UI hadn't changed but we were sending a nodes with a different Id accross traversals which confuses things on the desktop
1. By removing the litho observer we are repeatidly scanning the entire hierachy on scroll or when a video plays. The debug component that represents litho views are not stable, they are generated each time even if the underlying component is the same
2. Offset child is generated by us each time and the old id refered to the generated offset child not the underlying object
This diff addresses these 2 cases by allowing a descriptor to choose the ID.
The nodeId convience method was used in a lot of places. For the places where the id ended up in the protocol we have migrated to the descriptors getID. In some other places it is only used internally or for logging. In this case I have renamed the method and changed the return type from Id to int so it cant be accidently used in the protocol
Reviewed By: lblasa
Differential Revision: D41307239
fbshipit-source-id: 655b230180a6d02d66888e86b2293eead3385455
Summary: In a previous diff the Bounds was made mandatory and the fragment bounds was set to be the same as the underlying view. this caused the offset to be doubled since the underlying view would also apply that offset. Since fragments dont contribute to layout and are purely for lifecycle we can set it to 0 and handle it on the desktop
Reviewed By: lblasa
Differential Revision: D41304500
fbshipit-source-id: 39591b3ef0c746bd7a4ec8d61fed623cc7c94944
Summary:
Previously we would only consider a node hit if the nouse pos was inside every parents. There are a few reason why this isnt ideal:
1. Fragments are return 0 bounds
2. Many hierachys (particually in litho ) have nonsensical strucutres where your parent may have hieght 0, or children overflow parents bounds. Therefore it was impossible to select many nodes but unclear why
Reviewed By: lblasa
Differential Revision: D41304499
fbshipit-source-id: d75c8060f71fa0b972f136cb11258b62a9c98ebc
Summary:
There seem to be a number of issues with registering to all changes properly for litho observer.
Removing it and allowing the decor view to do a full traversal fixes a number of problems. The performance with hardware rendering seems to be fine. This should be stopgap untill we tackle time travel properly
Reviewed By: lblasa
Differential Revision: D41304501
fbshipit-source-id: 5b7cdbd0dac04ba0dbf8dd5e449c99f0db4d0863
Summary: Pretty much copy/paste from Pascal's post on data pipelines as it provides a quick overview of things involved
Reviewed By: passy
Differential Revision: D41274753
fbshipit-source-id: 337b034d2460ba448582b9dea70b835898627faa
Summary: This change alphabetically sorts the 'Under the Hood' section and adds a 'Meta' parent category for everything that is internal as to add a visual cue of what is internal and whats not.
Reviewed By: passy
Differential Revision: D41273678
fbshipit-source-id: 1acf8da184762d5924bff90b6691be1e4be92c46
Summary:
In our organization, Flipper is distributed in a version controlled way. As a result, we do not want users to manually update or receive prompts to update when a new version is available. There is already a `--updater` flag in the command line arguments for flipper.exe, but it isn't piped through. This change pipes it through and disables all update related UI when `--no-updater` is passed in.
## Changelog
Support --updater and --no-updater options for flipper.exe
Pull Request resolved: https://github.com/facebook/flipper/pull/4277
Test Plan: Ran `yarn build --win` in flipper/desktop, and launched flipper.exe from flipper/dist/win-unpacked with the `--updater`, `--no-updater` and no flags and ensured the proper behavior was observed (update UI shows by default or when `--updater` is specified, and doesn't show when `--no-updater` is specified).
Reviewed By: passy
Differential Revision: D41298321
Pulled By: mweststrate
fbshipit-source-id: 5ddfede2700954f0fdd6a111b20d0836fab25565
Summary:
There are situations where multiple siblings overlap and they are both hit. Previously we picked the first one in the hierachy. Now we produce a list of hit children. The list will not have 2 nodes in the same ancestor path.
We store the hovered nodes as a list as we may want to present a modal in future to ask user which node they indented to select. That said simply sorting nodes by area seems to give decent results so we can start with this
Reviewed By: lblasa
Differential Revision: D41220271
fbshipit-source-id: 643a369113da28e8c4749725a7aee7aa5d08c401
Summary:
The Dom events for the divs that are very close together were not firing correctly causing the old implementation to not track the hovered node correctly. This was really frustrating trying to select a node amongst many close neighbours.
The new approach uses the mouse x,y position and performs a hit test. Currently we do a dfs looking for the first deepest child that interests the mouse x,y. In a future diff we will extract a list when there are multiple candidates.
Hovered node was removed from react props since both the tree and visualisor depend on it meaning when hover state changes the whole app is rerendered. Instead we have moved hover state to an atom which is subscribed to by each visualsation node. Only if the old or new value matches the particular nodes id do we set state. The viz nodes were memo'd to prevent children renderning. The result is that for a hover change at most 2 nodes out of the 500 or so will rerender.
I attempted to do the same with the tree but it wasnt working with the controlled tree environment + focus state. The perf seems fine as is so will leave it for now
Reviewed By: lblasa
Differential Revision: D41218324
fbshipit-source-id: 7f80bcee256abad2689a88d7e209f92417aab672
Summary: This structure makes sense for the vizualiser which itself is a nested structure. It also saves the awkward branch of there is no key in the map.
Reviewed By: lblasa
Differential Revision: D40670371
fbshipit-source-id: 6c1b960a77749be9e8a193decf6b8d50ce6c7968