Andrey Goncharov
efdcaee302
Make enum term length dynamic
...
Reviewed By: mweststrate
Differential Revision: D50551626
fbshipit-source-id: f180252782244aaa5bc8c90521664f6bcbe6b9b7
2023-10-23 06:51:06 -07:00
Anton Kastritskiy
663380e721
mark unused vars as errors
...
Reviewed By: lblasa
Differential Revision: D50500690
fbshipit-source-id: 6f739fe25c232ecfe842337af4399681e85f6a13
2023-10-20 12:44:58 -07:00
Anton Kastritskiy
30100989f4
fix tabs + localStorage
...
Summary:
Key fix is
```diff
- 'Tabs:' + localStorageKeyOverride ?? keys.join(','),
+ 'Tabs:' + (localStorageKeyOverride ?? keys.join(',')),
```
Previously it worked like `('Tabs:' + localStorageKeyOverride) ?? keys.join(','),` which always evaluated to `"Tabs:undefined"`. This means that all tabs that were not using localStorageKeyOverride were reusing the same localstorage key. If you open some tabs with A, B, and C tabs. And open tab B. Then open other tabs with D, E, and F. No tab would be selected as the default value would be B.
The second part it extracing keys from `items` prop instead of children.
Reviewed By: lblasa
Differential Revision: D50411422
fbshipit-source-id: 30f70c4347649f29e8c8ff1f2f38fdca7e826198
2023-10-18 09:33:48 -07:00
Andrey Goncharov
a0a9465c0b
Fix dark theme support
...
Reviewed By: lblasa
Differential Revision: D50406262
fbshipit-source-id: eda5c73efcd50dbe572cab078d3c04a4cd845601
2023-10-18 04:15:05 -07:00
Andrey Goncharov
82487be96e
Handle paste
...
Summary: When a user pastes anything, it is treated as an input for a search through the entire row
Reviewed By: lblasa
Differential Revision: D49948975
fbshipit-source-id: 2dd23d4ee0819623549d88eb077c7b2d2fdf604f
2023-10-05 03:54:29 -07:00
Andrey Goncharov
c8fc3e6b82
If not option is matched, treat it as a whole row search predicate
...
Summary: See prev diffs
Reviewed By: lblasa
Differential Revision: D49948976
fbshipit-source-id: 177fd4b90449c78975b6a21c50a781789425b34e
2023-10-05 03:54:29 -07:00
Andrey Goncharov
c4fbd10e68
Allow handling arbitrary text
...
Summary:
When a user enters any arbitrary text, we will treat as an input for the search through the entire row.
Based on feedback from https://fb.workplace.com/groups/flippersupport/permalink/1703929480087703/
Reviewed By: lblasa
Differential Revision: D49911868
fbshipit-source-id: 4c569e4b01e468f0ca112ea4b00fe143b30bed2a
2023-10-05 03:54:29 -07:00
Andrey Goncharov
0346dc1120
Add an predicate to search a whole row
...
Summary:
Allow users to search through the entire row.
Based on feedback from https://fb.workplace.com/groups/flippersupport/permalink/1703929480087703/
Reviewed By: lblasa
Differential Revision: D49911869
fbshipit-source-id: 7bb9816c91b9168d657314b289e3ecc3c237c8d8
2023-10-05 03:54:29 -07:00
Pascal Hartig
4905446697
Update deps
...
Summary: Update a few selected patch-level deps.
Reviewed By: antonk52
Differential Revision: D49779877
fbshipit-source-id: 5f8da30a3802f4ca516ad20ac223cafce5120ba0
2023-10-03 10:58:10 -07:00
Andrey Goncharov
1e81fe636a
Add extraActions fallback to MasterDetai and DataTable
...
Summary: Old MasterDetail and DataTable (pre-power search) are using `extraActions` prop which no longer exists in teh new components. This diff adds a fallback.
Reviewed By: ivanmisuno
Differential Revision: D49869730
fbshipit-source-id: 4c1a658aa94acc770836f9bf296a3df7d6cdcb3e
2023-10-03 09:13:02 -07:00
Andrey Goncharov
72e6ba2705
Add dedicated operators to handle seriazable objects
...
Reviewed By: lblasa
Differential Revision: D49828114
fbshipit-source-id: 6846ce7360697806a6a770c1c6f864d162eee528
2023-10-02 08:27:37 -07:00
Andrey Goncharov
010de365fa
Allow using whole row for power search
...
Reviewed By: lblasa
Differential Revision: D49827828
fbshipit-source-id: 93219146ba59074be305eb9a963550223a5abd18
2023-10-02 08:27:37 -07:00
Andrey Goncharov
c27f9c7916
Fallback for empty titles
...
Summary: Some columns set title to an empty string
Reviewed By: lblasa
Differential Revision: D49826852
fbshipit-source-id: 3661394323dade813295420a1186d9297a8be153
2023-10-02 08:27:37 -07:00
Andrey Goncharov
84bb47655e
Hide unknown value processing behind a GK
...
Reviewed By: antonk52
Differential Revision: D49822509
fbshipit-source-id: 2228883f8ef16013a63c0d6d69697e32b55cec68
2023-10-02 08:27:37 -07:00
Andrey Goncharov
76918ae4fe
Handle unknown values when adding power search to unconfigured columns
...
Reviewed By: antonk52
Differential Revision: D49822513
fbshipit-source-id: a9c5c6ddc91ac6e7284af045ec673144d9c64906
2023-10-02 08:27:37 -07:00
Andrey Goncharov
4165a1b272
Handle unknown values in string operators
...
Reviewed By: antonk52
Differential Revision: D49822510
fbshipit-source-id: 4fc22df7af282e93af28bb0e69f70acd805e620b
2023-10-02 08:27:37 -07:00
Andrey Goncharov
8a591a7855
Support handleUnknownValues in default operators
...
Summary: We treat every column without the power search config as if it contains strings. Sometimes that might bite us, for instance, when the column contains an object.
Reviewed By: lblasa
Differential Revision: D49822511
fbshipit-source-id: 18dadb5abe624fae510663fc26668b2b594899c3
2023-10-02 08:27:37 -07:00
Andrey Goncharov
446147b9fe
Split SimpleOperatorConfig
...
Reviewed By: lblasa
Differential Revision: D49822512
fbshipit-source-id: 82fc6a72cd5ff3b5f9d577baea49367b4f2521fd
2023-10-02 08:27:37 -07:00
Anton Kastritskiy
a37b04737c
Move default actions and extra actions next to the search
...
Summary: Having default and extra actions at the bottom is not actionable. Users are used to haveing table controls on the top.
Reviewed By: LukeDefeo, aigoncharov
Differential Revision: D49538205
fbshipit-source-id: 724a31dc44de79cb0e09efae48dd2135450b34ae
2023-09-22 08:25:24 -07:00
Anton Kastritskiy
947cc819e3
remove unneccessary console.log
...
Reviewed By: lblasa
Differential Revision: D49502424
fbshipit-source-id: 674eb165871da43427ea5605b4aa74ec3297dd33
2023-09-21 09:43:22 -07:00
Andrey Goncharov
a35708989c
Add metrics
...
Reviewed By: antonk52
Differential Revision: D49455605
fbshipit-source-id: 00b4de3106d2497b43708623c410ca262e931059
2023-09-20 05:39:33 -07:00
Andrey Goncharov
fc5fa4a349
Fix styles of non-interactive elements
...
Summary: Make non-interactive elements non-focusable and disable hover styles for them
Reviewed By: LukeDefeo
Differential Revision: D49455532
fbshipit-source-id: a047e1a149ab4131feef70b80a4995b455441701
2023-09-20 05:39:33 -07:00
Andrey Goncharov
f3bff735cc
Simplify search term renderer matching
...
Summary: Each search term renderer handles its "editing" state internally now. As a result, we can simplify switch-case
Reviewed By: antonk52
Differential Revision: D49454252
fbshipit-source-id: 297ce73f53772b0112ed338c6aac0583f3807ec8
2023-09-20 04:36:57 -07:00
Andrey Goncharov
e031032b93
Make date term editable
...
Reviewed By: lblasa
Differential Revision: D49453947
fbshipit-source-id: b6959c6ac74d8966e21fb91f7dcbdf186253b93b
2023-09-20 04:36:57 -07:00
Andrey Goncharov
e180a1ed4b
Make float term editable
...
Summary: For the purposes of the demo I added power search config for a float field to the summary field
Reviewed By: lblasa
Differential Revision: D49452844
fbshipit-source-id: 26aaadd07a1a8a67dfcf3cb9d8e487f8f4ee2214
2023-09-20 04:36:57 -07:00
Andrey Goncharov
31e93ff3fe
Make integer term editable
...
Summary: For the purposes of the demo I added power search config for an integer field to the summary field
Reviewed By: lblasa
Differential Revision: D49452729
fbshipit-source-id: 78b8fdccfd799a0f71f652d90d10e11db237cbae
2023-09-20 04:36:57 -07:00
Andrey Goncharov
b3fe4c9650
Make enum term editable
...
Reviewed By: lblasa
Differential Revision: D49452483
fbshipit-source-id: e9bef3c5499a91231f6025e403c132b924491def
2023-09-20 04:36:57 -07:00
Andrey Goncharov
09cb48a3e3
Make string term editable
...
Summary:
At the end of the stack we are going to unify two branches of the switch-case in PowerSearchTerm.tsx.
Each search term is going to handle the finalized and "editing" mode internally
Reviewed By: lblasa
Differential Revision: D49451975
fbshipit-source-id: 587ba332d1fbfbaefb368e37965543575e64062f
2023-09-20 04:36:57 -07:00
Andrey Goncharov
1163769b83
Change layout for power search enabled data table
...
Summary: Doc: https://docs.google.com/document/d/1miofxds9DJgWScj0zFyBbdpRH5Rj0T9FqiCapof5-vU/edit#heading=h.pg8svtdjlx7
Reviewed By: antonk52
Differential Revision: D49411939
fbshipit-source-id: 0ca8b69ac7eaad1ece88caa5a220203fe54ad946
2023-09-19 08:19:25 -07:00
Andrey Goncharov
f6ffbfe3e2
Fix filtering bugs
...
Summary: Doc: https://docs.google.com/document/d/1miofxds9DJgWScj0zFyBbdpRH5Rj0T9FqiCapof5-vU/edit#heading=h.pg8svtdjlx7
Reviewed By: antonk52
Differential Revision: D49411941
fbshipit-source-id: 530b0abcbba57e2503da4641d17fd1a507955b45
2023-09-19 08:19:25 -07:00
Andrey Goncharov
6f38ecfd01
Add enum_is_nullish_or operator
...
Summary: Doc: https://docs.google.com/document/d/1miofxds9DJgWScj0zFyBbdpRH5Rj0T9FqiCapof5-vU/edit#heading=h.pg8svtdjlx7
Reviewed By: antonk52
Differential Revision: D49410975
fbshipit-source-id: 5f97e055107dfb72d14825b5d697cea71b9bf81a
2023-09-19 08:19:25 -07:00
Andrey Goncharov
e6f1e7a74f
Add enum_set_is_nullish_or_any_of operator
...
Summary: Doc: https://docs.google.com/document/d/1miofxds9DJgWScj0zFyBbdpRH5Rj0T9FqiCapof5-vU/edit#heading=h.pg8svtdjlx7
Reviewed By: antonk52
Differential Revision: D49410967
fbshipit-source-id: 699e620ce1076793597702711758809fc149389e
2023-09-19 08:19:25 -07:00
Andrey Goncharov
a6fdc127a2
Simplify SearchTerm
...
Summary: Doc: https://docs.google.com/document/d/1miofxds9DJgWScj0zFyBbdpRH5Rj0T9FqiCapof5-vU/edit#heading=h.pg8svtdjlx7
Reviewed By: antonk52
Differential Revision: D49410971
fbshipit-source-id: 5651dd1745aaf2efc96bae6a6b36cadad00d5c36
2023-09-19 08:19:25 -07:00
Andrey Goncharov
9d4ce0586d
Support setting initial power search expression
...
Summary: Doc: https://docs.google.com/document/d/1miofxds9DJgWScj0zFyBbdpRH5Rj0T9FqiCapof5-vU/edit#heading=h.pg8svtdjlx7
Reviewed By: antonk52
Differential Revision: D49410966
fbshipit-source-id: 2dcdb4495275dfdca7920af26bbfea4fb95ac419
2023-09-19 08:19:25 -07:00
Andrey Goncharov
ba812eaea6
Fix empty filter bug
...
Summary: Doc: https://docs.google.com/document/d/1miofxds9DJgWScj0zFyBbdpRH5Rj0T9FqiCapof5-vU/edit#heading=h.pg8svtdjlx7
Reviewed By: antonk52
Differential Revision: D49410974
fbshipit-source-id: 4845f32e6be6375e113053b7123df6e78b44b269
2023-09-19 08:19:25 -07:00
Andrey Goncharov
e5b2f693a3
Setup power search
...
Summary: Doc: https://docs.google.com/document/d/1miofxds9DJgWScj0zFyBbdpRH5Rj0T9FqiCapof5-vU/edit#heading=h.pg8svtdjlx7
Reviewed By: antonk52
Differential Revision: D49410972
fbshipit-source-id: 35cea0f033c16748e0ceb0921dee8276787fb1a6
2023-09-19 08:19:25 -07:00
Andrey Goncharov
3022b8ddb1
Simplify data table power search config for each column
...
Summary: Doc: https://docs.google.com/document/d/1miofxds9DJgWScj0zFyBbdpRH5Rj0T9FqiCapof5-vU/edit#heading=h.pg8svtdjlx7
Reviewed By: antonk52
Differential Revision: D49410973
fbshipit-source-id: d8854eefaf1901c4984300df955a15c77c03505e
2023-09-19 08:19:25 -07:00
Andrey Goncharov
3b75b6994b
Allow disabling power search for certain columns
...
Summary: Doc: https://docs.google.com/document/d/1miofxds9DJgWScj0zFyBbdpRH5Rj0T9FqiCapof5-vU/edit#heading=h.pg8svtdjlx7
Reviewed By: antonk52
Differential Revision: D49373658
fbshipit-source-id: 872bd6ecdce9c3ed7934f86f1954efdff76185b9
2023-09-19 08:19:25 -07:00
Andrey Goncharov
c75c377818
Expose DataTable and DataTableManager
...
Summary: Doc: https://docs.google.com/document/d/1miofxds9DJgWScj0zFyBbdpRH5Rj0T9FqiCapof5-vU/edit#heading=h.pg8svtdjlx7
Reviewed By: LukeDefeo
Differential Revision: D49349842
fbshipit-source-id: 927dc817e09d830feab9ba3e5e566ddb17fe1ad0
2023-09-19 08:19:25 -07:00
Andrey Goncharov
a86c8b412f
Remove search history from context menu
...
Summary: Doc: https://docs.google.com/document/d/1miofxds9DJgWScj0zFyBbdpRH5Rj0T9FqiCapof5-vU/edit#heading=h.pg8svtdjlx7
Reviewed By: LukeDefeo
Differential Revision: D49410968
fbshipit-source-id: a5160bb5d392f3884d46a3a390aa9e274d0230ea
2023-09-19 08:19:25 -07:00
Andrey Goncharov
d09dde724b
Add search icon
...
Summary: Doc: https://docs.google.com/document/d/1miofxds9DJgWScj0zFyBbdpRH5Rj0T9FqiCapof5-vU/edit#heading=h.pg8svtdjlx7
Reviewed By: LukeDefeo
Differential Revision: D49349828
fbshipit-source-id: 45a9917366236dda6c2409c30a4800cfe53dbd56
2023-09-19 08:19:25 -07:00
Andrey Goncharov
54a93c03aa
Compute power search config from columns
...
Summary: Doc: https://docs.google.com/document/d/1miofxds9DJgWScj0zFyBbdpRH5Rj0T9FqiCapof5-vU/edit#heading=h.pg8svtdjlx7
Reviewed By: antonk52
Differential Revision: D49349521
fbshipit-source-id: 49f8059bdbfbcc316b79eb633ec54d957f16548d
2023-09-19 08:19:25 -07:00
Andrey Goncharov
8cea5be59d
Add min width for term finder
...
Summary: Doc: https://docs.google.com/document/d/1miofxds9DJgWScj0zFyBbdpRH5Rj0T9FqiCapof5-vU/edit#heading=h.pg8svtdjlx7
Reviewed By: LukeDefeo
Differential Revision: D49349523
fbshipit-source-id: a9b9a14a74f9c32e094936e4bd38bef8f34e4c2c
2023-09-19 08:19:25 -07:00
Andrey Goncharov
f86dba951b
Fix Searchbar styles
...
Summary: Doc: https://docs.google.com/document/d/1miofxds9DJgWScj0zFyBbdpRH5Rj0T9FqiCapof5-vU/edit#heading=h.pg8svtdjlx7
Reviewed By: LukeDefeo
Differential Revision: D49349522
fbshipit-source-id: fa37cd0dcca291788834e76df3d4475842df8d48
2023-09-19 08:19:25 -07:00
Andrey Goncharov
54085eb79f
Add context menu
...
Summary: Doc: https://docs.google.com/document/d/1miofxds9DJgWScj0zFyBbdpRH5Rj0T9FqiCapof5-vU/edit#heading=h.pg8svtdjlx7
Reviewed By: LukeDefeo
Differential Revision: D49276995
fbshipit-source-id: 83c1346c6c5869c2608b73b11d40f7f55a7a694b
2023-09-19 08:19:25 -07:00
Andrey Goncharov
bad3dfa20a
Hide filter buttons
...
Summary: Doc: https://docs.google.com/document/d/1miofxds9DJgWScj0zFyBbdpRH5Rj0T9FqiCapof5-vU/edit#heading=h.pg8svtdjlx7
Reviewed By: LukeDefeo
Differential Revision: D49276686
fbshipit-source-id: 5bfea4b7ef87b8d71aa4cb5a1dc3f9a94ea420f0
2023-09-19 08:19:25 -07:00
Andrey Goncharov
9dbd6f7732
Allow TableHead hide filter button
...
Summary: Doc: https://docs.google.com/document/d/1miofxds9DJgWScj0zFyBbdpRH5Rj0T9FqiCapof5-vU/edit#heading=h.pg8svtdjlx7
Reviewed By: LukeDefeo
Differential Revision: D49276687
fbshipit-source-id: dfa2a51e3bfa84ad3e39b6a4b3a4e279cf63c1d5
2023-09-19 08:19:25 -07:00
Andrey Goncharov
de5f9bc32a
Add bolirplate for power search integration
...
Summary: Doc: https://docs.google.com/document/d/1miofxds9DJgWScj0zFyBbdpRH5Rj0T9FqiCapof5-vU/edit#heading=h.pg8svtdjlx7
Reviewed By: LukeDefeo
Differential Revision: D49272248
fbshipit-source-id: ad6d88568f40bd698faed4c3fc0fc55efd93f5f3
2023-09-19 08:19:25 -07:00
Andrey Goncharov
0cdc7d41be
Add MasterDetailWithPowerSearch
...
Summary: Doc: https://docs.google.com/document/d/1miofxds9DJgWScj0zFyBbdpRH5Rj0T9FqiCapof5-vU/edit#heading=h.pg8svtdjlx7
Reviewed By: LukeDefeo
Differential Revision: D49271463
fbshipit-source-id: 1309227024dd02e0f683a3c427b61663fb7a212f
2023-09-19 08:19:25 -07:00
Andrey Goncharov
1cf7160b2c
Add same_as_absolute_date_no_time operator
...
Summary: Doc: https://docs.google.com/document/d/1miofxds9DJgWScj0zFyBbdpRH5Rj0T9FqiCapof5-vU/edit#heading=h.pg8svtdjlx7
Reviewed By: lblasa, antonk52
Differential Revision: D49232775
fbshipit-source-id: 0ad6fafdd998f79a8b96bf9cd9d6e012e6e3a492
2023-09-14 04:48:12 -07:00