Commit Graph

563 Commits

Author SHA1 Message Date
Andrey Goncharov
194c08a12c Support keyboard
Summary: Project doc: https://docs.google.com/document/d/1miofxds9DJgWScj0zFyBbdpRH5Rj0T9FqiCapof5-vU

Reviewed By: lblasa

Differential Revision: D48559580

fbshipit-source-id: 683969879c213b869faadc60c6caab8f716b8688
2023-08-30 07:26:35 -07:00
Andrey Goncharov
0633658cee Filter power search term options
Summary: Project doc: https://docs.google.com/document/d/1miofxds9DJgWScj0zFyBbdpRH5Rj0T9FqiCapof5-vU

Reviewed By: lblasa

Differential Revision: D48558180

fbshipit-source-id: 311d5ed1859d0a31f85942772a956c46f58be46e
2023-08-30 07:26:35 -07:00
Andrey Goncharov
44c3f53905 Support removing search terms
Summary: Project doc: https://docs.google.com/document/d/1miofxds9DJgWScj0zFyBbdpRH5Rj0T9FqiCapof5-vU

Reviewed By: lblasa

Differential Revision: D48557277

fbshipit-source-id: edaa5e8806538fa308d43c364e4f68967c1bf2ac
2023-08-30 07:26:35 -07:00
Andrey Goncharov
7061de44fe Support entering freeform search values
Summary: Project doc: https://docs.google.com/document/d/1miofxds9DJgWScj0zFyBbdpRH5Rj0T9FqiCapof5-vU

Reviewed By: lblasa

Differential Revision: D48556764

fbshipit-source-id: aa2d77ce111e33ebe5d936c30d23ed78ca0e2c2e
2023-08-30 07:26:35 -07:00
Andrey Goncharov
c091067902 Update antd
Summary:
Project doc: https://docs.google.com/document/d/1miofxds9DJgWScj0zFyBbdpRH5Rj0T9FqiCapof5-vU

Required to get `Space.Compact`

allow-large-files

Reviewed By: passy

Differential Revision: D48520383

fbshipit-source-id: 000a5c16c00541455dc4a31c4fddb2c4c252a89e
2023-08-30 07:26:35 -07:00
Andrey Goncharov
795d02d00c Separate search term parts
Summary: Project doc: https://docs.google.com/document/d/1miofxds9DJgWScj0zFyBbdpRH5Rj0T9FqiCapof5-vU

Reviewed By: lblasa

Differential Revision: D48520106

fbshipit-source-id: 2a544230f182bd82023310ea88742fab44e2df9b
2023-08-30 07:26:35 -07:00
Andrey Goncharov
c746a11dc6 Allow multiple search terms
Summary: Project doc: https://docs.google.com/document/d/1miofxds9DJgWScj0zFyBbdpRH5Rj0T9FqiCapof5-vU

Reviewed By: lblasa

Differential Revision: D48519758

fbshipit-source-id: d691a26ebed9f7797516386b8fb9d4457b870a3e
2023-08-30 07:26:35 -07:00
Andrey Goncharov
9cdf944716 Compute Autocomplete options from config
Summary: Project doc: https://docs.google.com/document/d/1miofxds9DJgWScj0zFyBbdpRH5Rj0T9FqiCapof5-vU

Reviewed By: lblasa

Differential Revision: D48518324

fbshipit-source-id: 5abee77cca10f03b2d9fa5b62802a5000152248e
2023-08-30 07:26:35 -07:00
Andrey Goncharov
b780dc0598 Add basic Autocomplete
Summary: Project doc: https://docs.google.com/document/d/1miofxds9DJgWScj0zFyBbdpRH5Rj0T9FqiCapof5-vU

Reviewed By: lblasa

Differential Revision: D48517919

fbshipit-source-id: ec6e723a595862b61722db9c5afd96138264dfdc
2023-08-30 07:26:35 -07:00
Andrey Goncharov
839653c8fa Add PowerSearch example config
Summary: Project doc: https://docs.google.com/document/d/1miofxds9DJgWScj0zFyBbdpRH5Rj0T9FqiCapof5-vU

Reviewed By: lblasa

Differential Revision: D48468962

fbshipit-source-id: e86be373be324b44656f2ed0d9f66bf969d47a6b
2023-08-30 07:26:35 -07:00
Andrey Goncharov
d54bd8938a Add PowerSearch basic types
Summary: Project doc: https://docs.google.com/document/d/1miofxds9DJgWScj0zFyBbdpRH5Rj0T9FqiCapof5-vU

Reviewed By: lblasa

Differential Revision: D48467956

fbshipit-source-id: 7f5303d981831c261bf5e4fe0027883fd1e7d873
2023-08-30 07:26:35 -07:00
Pascal Hartig
7ce86869e4 Build plugins with ES2021
Summary:
Starting small as this will unblock D48642120.

If it works without causing any issues, I'll update the remaining ones.

We're on Node v18 everywhere now, so this should be compatible. According to https://node.green/ that should cover nearly everything.

Reviewed By: lblasa

Differential Revision: D48683680

fbshipit-source-id: 26d2788468b673793b70b6339d1845c1dcf7e05d
2023-08-25 09:43:01 -07:00
Luke De Feo
3ff0c301c8 Use exact mode when user explicitly filters on a column
Summary: Using substring doesnt make sense for these actions. As you say I want to filer on this cell but it includes many others

Reviewed By: aigoncharov

Differential Revision: D48515476

fbshipit-source-id: b7a77c022052bb33e2ce2a3f656dabab114d8a78
2023-08-21 05:59:44 -07:00
Luke De Feo
f5bc03c263 Add framework event node level event filtering
Summary: Lets you filter a nodes events by thread or type

Reviewed By: lblasa

Differential Revision: D48346955

fbshipit-source-id: 455d65ad21c54c5ad26782ac6a446f7ae15a4356
2023-08-21 04:24:16 -07:00
Luke De Feo
2d217575bb improve marker timeline
Summary:
1. removed background hover
2. made can select actually work
3. disable user selection
4. remove decimal points from ms

Reviewed By: lblasa

Differential Revision: D48270181

fbshipit-source-id: 724efedb5cad7f93c80ed5dd7f49efe4c434c324
2023-08-21 04:24:16 -07:00
Lorenzo Blasa
ff6f98fc0d Import File implementation
Summary: Implementation was missing for the browser. This provides a default implementation.

Reviewed By: aigoncharov

Differential Revision: D48311198

fbshipit-source-id: fd067600f571234e0fbccfb90853b62f175ff8fb
2023-08-14 11:33:06 -07:00
Andrey Goncharov
2834d3300a Track filtering and searching for data table
Reviewed By: mweststrate

Differential Revision: D48116067

fbshipit-source-id: 2dee2cfd68a23e1153b3f10ff229009777e936da
2023-08-09 08:01:44 -07:00
Hamdullah Shah
0fdd901297 DataDescriptor BigInt
Summary: The `DataDescriptionType` accepts the `BigInt` type but it doesn't render. Added the `case` for that and reuse the `NumberValue` tag for it.

Reviewed By: aigoncharov

Differential Revision: D48152012

fbshipit-source-id: 32ebc8a37df34d57b40c7ecdad331c547415b335
2023-08-08 09:50:08 -07:00
Luke De Feo
3282417663 Fix bug where if events come in the creation of a new tab throws exception
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
2023-07-19 08:58:20 -07:00
Lorenzo Blasa
532f6ff1ee App Inspect rounded container
Summary: ^

Reviewed By: antonk52

Differential Revision: D47591057

fbshipit-source-id: 5f3f308fb252245ebe510dd98b4cbd7ea7c6e27e
2023-07-19 06:12:07 -07:00
Andrey Goncharov
b55d730dd7 Integrate filter exceptions with DataTable
Summary: See previous diff for context

Reviewed By: LukeDefeo

Differential Revision: D47472005

fbshipit-source-id: 6e7d8873d275f826c38fab16c72e1621fd2784e1
2023-07-18 05:25:59 -07:00
Anton Kastritskiy
bdd502d54f navbar placeholder
Reviewed By: elboman

Differential Revision: D47398098

fbshipit-source-id: 6e9518b47292b351153015da233574f7abfd0396
2023-07-18 03:52:34 -07:00
Michel Weststrate
c8776175c3 Added support for secondary indices for fast lookups
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
2023-07-14 07:46:52 -07:00
Andrey Goncharov
1c532095ab Expose suggestNewPlugin as a shared util
Reviewed By: antonk52, ivanmisuno

Differential Revision: D46798839

fbshipit-source-id: f2b942a138a998f167b60c04c32c634545bbfe96
2023-06-16 08:29:54 -07:00
Andrey Goncharov
16b4d58ac3 Support filtering by exact match
Summary: Project: https://docs.google.com/document/d/1SbFrpvfIShX5npANNa1AkgHliR1M-VMLW5Q9RhREt94/edit

Reviewed By: antonk52

Differential Revision: D46642517

fbshipit-source-id: e23eead18189adb9aaacb7eab3244cfce289203e
2023-06-12 07:29:55 -07:00
Andrey Goncharov
b9322247e6 Make assert stable ref error more explicit
Reviewed By: ivanmisuno

Differential Revision: D46359534

fbshipit-source-id: 002e4e8ae9168cf2cf3b652fc853416de825861f
2023-06-06 03:44:48 -07:00
Anton Kastritskiy
12734d6b7e allow column filter to be loose
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
2023-06-01 06:51:41 -07:00
Lorenzo Blasa
6430403da0 Jest update v26.6.3 -> v29.5.1
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
2023-05-31 14:19:29 -07:00
Anton Kastritskiy
fda21e96e8 Update typescript to 4.9.5
Reviewed By: passy

Differential Revision: D46068908

fbshipit-source-id: 4c1ffff8690eec5a10c67d6c5d1aacf224e0f0d4
2023-05-23 03:15:10 -07:00
Andrey Goncharov
33ae7f23db Fix column sorting not visible
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
2023-05-11 08:14:05 -07:00
Andrey Goncharov
78b650dbe0 Make fliters non-exclusive
Summary:
Project: https://docs.google.com/document/d/1SbFrpvfIShX5npANNa1AkgHliR1M-VMLW5Q9RhREt94/edit

Also, sync quick filters with the internal filter state of the table

Reviewed By: antonk52

Differential Revision: D45396180

fbshipit-source-id: 6a8ef4ac61a49ec7af71ae9e26f20f395fb34cef
2023-04-28 12:19:45 -07:00
Andrey Goncharov
65daaf80f1 Expose table state from table manager
Summary: Project: https://docs.google.com/document/d/1SbFrpvfIShX5npANNa1AkgHliR1M-VMLW5Q9RhREt94/edit

Reviewed By: antonk52

Differential Revision: D45395107

fbshipit-source-id: 8ca3639a109e40b26acead8bb4b0eace68ac9bce
2023-04-28 12:19:45 -07:00
Andrey Goncharov
424985a75a Expose removing filters programatically
Summary: Project: https://docs.google.com/document/d/1SbFrpvfIShX5npANNa1AkgHliR1M-VMLW5Q9RhREt94/edit

Reviewed By: antonk52

Differential Revision: D45394864

fbshipit-source-id: d2c140d542eaee157cbad5b6a0f29fc62f73a18b
2023-04-28 12:19:45 -07:00
Andrey Goncharov
647bc06f3a Make filtered state of columns more apparent
Summary: People complained about barely noticeable filtered state indication multiple times

Reviewed By: antonk52

Differential Revision: D45394233

fbshipit-source-id: 60a3531b1808ae8f95ce8cd405a20b74bad0ed46
2023-04-28 12:19:45 -07:00
Andrey Goncharov
9d2de05723 Allow to disable column sorting
Summary: Project: https://docs.google.com/document/d/1SbFrpvfIShX5npANNa1AkgHliR1M-VMLW5Q9RhREt94/edit#

Reviewed By: antonk52

Differential Revision: D45394048

fbshipit-source-id: 4255777d477f8240f52b5f82c28e922ef1011989
2023-04-28 12:19:45 -07:00
Andrey Goncharov
a819c77f18 Expose addColumnFilter from DataTable
Summary:
Project: https://docs.google.com/document/d/1SbFrpvfIShX5npANNa1AkgHliR1M-VMLW5Q9RhREt94/edit#

Used to set filters externally in next diff

Reviewed By: antonk52

Differential Revision: D45393487

fbshipit-source-id: 15c1186292f45de455ebbcbfced7a63c824a6c19
2023-04-28 12:19:45 -07:00
Andrey Goncharov
27eb5978a9 Pass TableManager instance to Details sidebar of any MasterDetail table
Summary: Project: https://docs.google.com/document/d/1SbFrpvfIShX5npANNa1AkgHliR1M-VMLW5Q9RhREt94/edit#

Reviewed By: passy

Differential Revision: D45354900

fbshipit-source-id: 7f968c9d235f5d8bb23e59e50e39fc1e9f498f46
2023-04-28 12:19:45 -07:00
Pascal Hartig
22e28a4f3e Bump prettier from 2.6.2 to 2.8.7 in /desktop
Summary: Updates prettier and applies the fixes.

Reviewed By: antonk52

Differential Revision: D45087515

fbshipit-source-id: 226814ab4805eb12e64c2134407164498c708c0a
2023-04-19 03:04:19 -07:00
Andrey Goncharov
ff85744911 Make DataView report window changes
Summary: Project: https://docs.google.com/document/d/1x-1ShlxXCM2od9JMO6PP14Cuqq0OrVe1Qd7FUwTos9A/edit

Reviewed By: antonk52

Differential Revision: D44748055

fbshipit-source-id: 409c272b12fb29c156efdaa1ab26d4d6a2936645
2023-04-06 10:10:34 -07:00
Andrey Goncharov
4e898eb01a Allow passing external virtualizedRef to DataTable
Summary: External virtualRef allows us to scroll the table programmatically whenever we want

Reviewed By: antonk52

Differential Revision: D44746968

fbshipit-source-id: ad8e0fb3b43881ed8f4ba114cd35c08643ef0d3b
2023-04-06 10:10:34 -07:00
Andrey Goncharov
794c29f320 Add "overlay" sidebar position to MaterDetail
Summary: Project: https://docs.google.com/document/d/1x-1ShlxXCM2od9JMO6PP14Cuqq0OrVe1Qd7FUwTos9A/edit

Reviewed By: ivanmisuno

Differential Revision: D44706158

fbshipit-source-id: 16c70a7c9a414a6c32d690eb05ae5b08818dd400
2023-04-05 07:22:15 -07:00
Andrey Goncharov
f8a1f38c0a Set flipperLib implementation automatically in unit tests
Summary: This way plugins get something meaningful when they call `getFlipperLib()` in their tests

Reviewed By: LukeDefeo

Differential Revision: D44662821

fbshipit-source-id: c13800f9d8e905ae4a89955f2186adb816730b77
2023-04-04 05:26:31 -07:00
Lorenzo Blasa
b0a8dbca01 MarkerTimeline to show a more obvious selected state
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
2023-04-04 04:05:15 -07:00
Lorenzo Blasa
f210ec809f Propagate onClick for TimelineDataDescription
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
2023-04-03 10:35:15 -07:00
Lorenzo Blasa
695c669e0c TimelineDataDescription to accept any properties
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
2023-03-31 04:15:29 -07:00
Andrey Goncharov
09f7bcf878 Fail fast if DataSourceRendererVirtual references an non-existent value
Reviewed By: ivanmisuno

Differential Revision: D44417205

fbshipit-source-id: 043b3b12ea44d85f1fb02e2cf030b4c9cc7e5087
2023-03-27 06:50:59 -07:00
Andrey Goncharov
a0c17b94c4 Add track controls
Summary: Project: https://docs.google.com/document/d/1x-1ShlxXCM2od9JMO6PP14Cuqq0OrVe1Qd7FUwTos9A/edit#heading=h.fiq3qxllvkl

Reviewed By: ivanmisuno

Differential Revision: D44306047

fbshipit-source-id: 393741f9255dea3d582ac43a4733aa835f5d4a27
2023-03-23 04:12:31 -07:00
Lorenzo Blasa
d669fd08e5 TimelineDataDescription optional properties
Summary: Make properties optional. Additionally, only show them if found.

Reviewed By: mweststrate

Differential Revision: D43948493

fbshipit-source-id: 0aa77a725663b456f069c717b4ea051008516c9e
2023-03-10 06:18:21 -08:00
Lorenzo Blasa
b4f6f9f008 TimelineDataDescription optional onClick
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
2023-03-10 06:18:21 -08:00
Lorenzo Blasa
bdf3dbe332 Export TimelineDataDescription
Summary: It wasn't exported, instead it was consumed by the 'flipper' deprecated module.

Reviewed By: fabiomassimo

Differential Revision: D43872434

fbshipit-source-id: 70a4a525c660f0779f942739311205417cef3834
2023-03-07 11:23:20 -08:00