Summary:
See title. The issue occurs because this tabs component derives a key by essentially serializing the children. Since its possible for different elements in the UIDebugger to have different number of tabs, due to framework events not always being present this was never anticipated.
Solution is to just let the callee supply a storage key which does not depend on the exact number of tabs
Reviewed By: lblasa
Differential Revision: D47520033
fbshipit-source-id: 67e57db5110fde52451d30496c25a25b0eb4a6f7
Summary:
Add support for secondary indices, to allow for cheap lookups, like a set of events for a specific UI element in the events table:
```
#### getAllRecordsByIndex
Usage: `getAllRecordsByIndex({ indexedAttribute: value, indexAttribute2: value2, .... })`
This method allows fast lookups for objects that match specific attributes exactly.
Returns all items matching the specified index query.
Note that the results are unordered, unless
records have not been updated using upsert / update, in that case
insertion order is maintained.
If no index has been specified for this exact keyset in the indexQuery (see options.indices), this method will throw.
Example:
```
```
const ds = createDataSource([eatCookie, drinkCoffee, submitBug], {
key: 'id',
indices: [
['title']
['id', 'title'],
['title', 'done'],
],
});
// Find first element with title === cookie (or undefined)
const todo = ds.getFirstRecordByIndex({
title: 'cookie',
})
// Find all elements where title === cookie, and done === false
const todos = ds.getAllRecordsByIndex({
title: 'cookie',
done: false,
})
```
Reviewed By: antonk52
Differential Revision: D47396435
fbshipit-source-id: 20c4527be83532863b9b07ab20ebf20a80c3c35d
Summary:
Until now when we filter by a column value we only get the items that match this value exactly.
Release: we can add loose filters that match value or `undefined`
Reviewed By: lblasa, ivanmisuno
Differential Revision: D46318631
fbshipit-source-id: 94ecb3f074674d4b0ce3a480f4f3b9ddc058ceef
Summary:
^
Basically, update Jest and fix any raised issues. Mainly:
- Update necessary dependencies
- Update snapshots
- `useFakeTimers` caused a few issues which meant that the way we hook into the performance object had to be tweaked. The main code change is: `//fbsource/xplat/sonar/desktop/scripts/jest-setup-after.tsx`
- `mocked` -> `jest.mocked`
Changelog: Update Jest to v29.5.1
Reviewed By: antonk52
Differential Revision: D46319818
fbshipit-source-id: d218ca8f7e43abac6b00844953ddeb7f4e1010a2
Summary: Fixes a regression from D45394048. It "sortable" as a nullable column prop. When it is undefined it should be treated as true.
Reviewed By: LukeDefeo
Differential Revision: D45776216
fbshipit-source-id: dcd8ce97217086deab7b2b1852837fbfa7437d13
Summary: People complained about barely noticeable filtered state indication multiple times
Reviewed By: antonk52
Differential Revision: D45394233
fbshipit-source-id: 60a3531b1808ae8f95ce8cd405a20b74bad0ed46
Summary: This way plugins get something meaningful when they call `getFlipperLib()` in their tests
Reviewed By: LukeDefeo
Differential Revision: D44662821
fbshipit-source-id: c13800f9d8e905ae4a89955f2186adb816730b77
Summary:
When a marker is selected, it was difficult to notice any style differences.
This changes makes it more obvious when a marker is selected.
Reviewed By: antonk52, aigoncharov
Differential Revision: D44628828
fbshipit-source-id: c4634338e04969f3d973137ad861cb999b28c139
Summary:
`onClick` was not getting called if it wasn't paired with `canSetCurrent`.
Ultimately, we can benefit from propagating this event in all cases as to give indication of whenever a marker has been selected.
Reviewed By: antonk52, aigoncharov
Differential Revision: D44628819
fbshipit-source-id: bee910b48ad065d7479e247fbacdcd738f281b26
Summary: DataInspector can use `any` value to inspect. Lift the constraint from TimelineDataDescription as ultimately is not necessary i.e. the right inspector will be used based on the type of properties.
Reviewed By: antonk52
Differential Revision: D44572963
fbshipit-source-id: ad8a257020c90e18468e905f2beda44c2ee06368
Summary: Make properties optional. Additionally, only show them if found.
Reviewed By: mweststrate
Differential Revision: D43948493
fbshipit-source-id: 0aa77a725663b456f069c717b4ea051008516c9e
Summary: Make this property optional as is not always required to implement it, if not needed.
Reviewed By: mweststrate
Differential Revision: D43948425
fbshipit-source-id: 43ed761c70c4779134f277a4cda53c1e3d326cb8
Summary: It wasn't exported, instead it was consumed by the 'flipper' deprecated module.
Reviewed By: fabiomassimo
Differential Revision: D43872434
fbshipit-source-id: 70a4a525c660f0779f942739311205417cef3834
Summary: Without the margin, the point is displayed at the top-left which is not centrally aligned with both time and label.
Reviewed By: antonk52
Differential Revision: D43872394
fbshipit-source-id: 087c09e44c65ddaef79cfb25a860d7b4893ba072
Summary: The margin was miss-aligning with the label.
Reviewed By: antonk52
Differential Revision: D43872373
fbshipit-source-id: 8a6ff8104c6e532d8139053aad221244c2cd5feb
Summary:
Set a fixed number of decimals for the 'ms'.
More doesn't give more insights and it messes with the overall layout.
Reviewed By: antonk52
Differential Revision: D43872203
fbshipit-source-id: 343278923ee27dbf884af41c997457bfba337ba8
Summary: Remove the bottom padding as this was not really making it any better.
Reviewed By: antonk52
Differential Revision: D43872178
fbshipit-source-id: 8302385d190c65000afda02b5c8aa9d272ccc271
Summary:
The hover background colour had complete disregard on the selected theme, both light and dark.
This change removes the gradient and instead sets a right hover background.
Reviewed By: antonk52
Differential Revision: D43872161
fbshipit-source-id: 4f0bfd97a2cb6bb9ceb7869dd38b37dc68ad6bb7
Summary:
The goal is to restore the *TimeMachine* functionality in Flipper while the new UI Debugger is working in a revamped version. This version was previously removed in D42573698 (b31f8c8755).
This time machine functionality will only be available for *LithoView* that are backed by a *ComponentTree*.
Below you can find a high-level overview of the current schema:
{F884011465}
Reviewed By: LukeDefeo, adityasharat
Differential Revision: D43574130
fbshipit-source-id: fe9d661e5fcce9655e70be4785652e7048dade54
Summary:
Bumps [js-base64](https://github.com/dankogai/js-base64) from 3.7.4 to 3.7.5.
<details>
<summary>Commits</summary>
<ul>
<li><a href="7e790b799e"><code>7e790b7</code></a> version 3.7.5</li>
<li><a href="f729053682"><code>f729053</code></a> Merge pull request <a href="https://github-redirect.dependabot.com/dankogai/js-base64/issues/167">https://github.com/facebook/flipper/issues/167</a> from ctomacheski/main</li>
<li><a href="a9a994f367"><code>a9a994f</code></a> improve performance by stop using the mapFn param on Uint8Array.from constructor</li>
<li>See full diff in <a href="https://github.com/dankogai/js-base64/compare/3.7.4...3.7.5">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/4519
Reviewed By: mweststrate
Differential Revision: D43305193
Pulled By: ivanmisuno
fbshipit-source-id: e10eb134c079951e325c1f4d627eb1e60510c12d
Summary: Combining a bunch of individual tasks for dep upgrades into one diff.
Reviewed By: ivanmisuno
Differential Revision: D42706074
fbshipit-source-id: 054b2545ad1295699f47f4c6eb5065b7b9a1d6a0
Summary:
This plugin is rarely used and would need to be re-worked to work in a world where ComponentTree is not the only way of rendering a Litho hierarchy.
Deleting for now for simplicity
Reviewed By: adityasharat, passy
Differential Revision: D42573698
fbshipit-source-id: 0d9cd713b668e6fc79cd5cddcdcb9f24ed98f927
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: Set width of sidebar for `main` position in `MasterDetail`.
Reviewed By: mweststrate
Differential Revision: D41493698
fbshipit-source-id: a9f4804256a7ee46ed32f367e8b21ff57dd484e0
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:
Flipper plugins fail when importing css from third-party dependencies. This diff tries to fix that.
Effectively, the plugin can import the css and export it when is bundled.
When we load the plugin, we check if there's a css file for it. If there's one, we return it and try to use it.
Reviewed By: aigoncharov
Differential Revision: D40758178
fbshipit-source-id: e53afffcc481504905d5eeb1aea1f9114ee2a86b
Summary:
Replace draft inspectors with read-only components.
This is a first step into having a richer UI. At the moment, these are read-only components but will likely be extended in the future as to allow editing of values.
Reviewed By: LukeDefeo
Differential Revision: D40345016
fbshipit-source-id: a6aef5861474b4aa8353c00ef257ab17b4cff00e
Summary:
In a headless mode we do not have access to local storage. As a result, headless plugins that try to use `persistToLocalStorage` option crash. We should ignore the option for these plugins for now and add a way to persist the plugin state to the disk in a headless mode in the future.
CHANGELOG: Ignore persistToLocalStorage in headless mode
Resolves https://github.com/facebook/flipper/issues/4190
Reviewed By: lblasa
Differential Revision: D40341873
fbshipit-source-id: 40774c0024f79cf1652f24146fd16f6a101ca99e