Commit Graph

8 Commits

Author SHA1 Message Date
Luc Oth
7c3d264803 ManagedTable: pass an innerRef to bypass debounceRender
Summary: The ref would point to the DebouncedComponent instead of the ManagedTable passing an innerRef and handling binding manually.

Reviewed By: mweststrate

Differential Revision: D22374912

fbshipit-source-id: d404931405939ef8bfbde31f9aec7d531a3b62e3
2020-07-03 09:34:43 -07:00
Michel Weststrate
3033fb035c Evaluate copyText lazily
Summary:
`copyText` is generated when building rows for table, and is typically filled by JSON stringifying the incoming data. That is a pretty expensive process that could be done lazily. As shown in later diffs, this reduces the generation of rows for tables from ~18ms to ~3ms, which makes rendering a lot smoother.

(n.b. fixing the code duplication in the managedtables is part of the component lib plan)

Reviewed By: passy

Differential Revision: D21929660

fbshipit-source-id: 67cc69945e2bb28a6462a9d9ab765e33ced89378
2020-06-09 03:00:23 -07:00
Chaiwat Ekkaewnumchai
dec5045fca Fix Unwanted Highlight in ManagedTable
Summary: Previously, rows got highlighted after switching between data for `ManagedTable` even though `highlightableRows` was set to false. This diff forces the highlighting not to happen when the value is set to false

Reviewed By: mweststrate

Differential Revision: D21720266

fbshipit-source-id: 534944fe03ad1561bc2109468ae6c4c5f3fc947d
2020-05-26 05:50:12 -07:00
Michel Weststrate
655d856d1c Fixed broken timeline layout
Summary: Changelog: Fixed broken layout of timeline in QPL plugin

Reviewed By: passy

Differential Revision: D21383013

fbshipit-source-id: 95fbe2681ff27dff827c742f11192c1d07ad021c
2020-05-05 04:06:25 -07:00
Anton Nikolaev
ec07272c78 Linter checks for extraneous dependencies
Summary: Added eslint rule "no-extraneous-imports" which disallow using modules which are not listed as dependencies in the corresponding package.json. Fixed a bunch of reported errors after the rule applied.

Reviewed By: passy

Differential Revision: D21186848

fbshipit-source-id: 0af9ac4b3fffdfd0ab7c23ae4ff12a3f5989d5e9
2020-04-23 05:33:20 -07:00
Chaiwat Ekkaewnumchai
e37bccaf04 Scroll to Inspected Element
Summary:
changelog: Add scroll to inspected element in layout plugin

Before this diff, when one inspected an element, one needed to scroll down to see highlighted line for that element. This diff added automatic scroll to inspected element. It will scroll so that the line is in middle of the app.

Also, fix direct state mutation and this error:
```
Public property 'onKeyDown' of exported class has or is using private name 'Element'.
```

Reviewed By: passy, mweststrate

Differential Revision: D20798587

fbshipit-source-id: 763eb63cd51abd73940e301e36e89232033722c3
2020-04-03 03:03:04 -07:00
Pascal Hartig
fc9ed65762 prettier 2
Summary:
Quick notes:

- This looks worse than it is. It adds mandatory parentheses to single argument lambdas. Lots of outrage on Twitter about it, personally I'm {emoji:1f937_200d_2642} about it.
- Space before function, e.g. `a = function ()` is now enforced. I like this because both were fine before.
- I added `eslint-config-prettier` to the config because otherwise a ton of rules conflict with eslint itself.

Close https://github.com/facebook/flipper/pull/915

Reviewed By: jknoxville

Differential Revision: D20594929

fbshipit-source-id: ca1c65376b90e009550dd6d1f4e0831d32cbff03
2020-03-24 09:38:11 -07:00
Anton Nikolaev
863f89351e Yarn workspaces
Summary:
1) moved "sonar/desktop/src" to "sonar/desktop/app/src", so "app" is now a separate package containing the core Flipper app code
2) Configured yarn workspaces with the root in "sonar/desktop": app, static, pkg, doctor, headless-tests. Plugins are not included for now, I plan to do this later.

Reviewed By: jknoxville

Differential Revision: D20535782

fbshipit-source-id: 600b2301960f37c7d72166e0d04eba462bec9fc1
2020-03-20 13:37:41 -07:00