Commit Graph

36 Commits

Author SHA1 Message Date
generatedunixname89002005306973
f01b84be27 Flipper Release: v0.52.0
Summary: Releasing version 0.52.0

Reviewed By: passy

Differential Revision: D22921075

fbshipit-source-id: 4cab9552dcd5ff1a64d20e1e771a4f5173d54860
2020-08-04 06:15:23 -07:00
generatedunixname89002005306973
5dc98bab9d Flipper Release: v0.51.0
Summary: Releasing version 0.51.0

Reviewed By: nikoant

Differential Revision: D22728768

fbshipit-source-id: 49eabdccc7fd335401618f91b890e94fda11b23f
2020-07-24 10:03:20 -07:00
Michel Weststrate
f0c54667e0 Support handling deeplinks in plugins
Summary:
This adds support for handling incoming deeplinks in a Sandy plugin, which can be done by using a `client.onDeepLink(deepLink => { } )` listener

Also generalized deeplinks to not just support strings, but also richer objects, which is beneficial to plugin to plugin linking.

Reviewed By: jknoxville

Differential Revision: D22524749

fbshipit-source-id: 2cbe8d52f6eac91a1c1c8c8494706952920b9181
2020-07-22 04:13:59 -07:00
Dominik Wielgórski
cf6df492ee Created openInIDE API inside Layout Plugin
Summary: Created a communication between Layout Plugin and Flipper Desktop. The API allows users to open given file in a selected IDE. The openInIDE function returns true if the connection with Flipper is established, otherwise returns false.

Reviewed By: adityasharat

Differential Revision: D22625829

fbshipit-source-id: feaf186c107d62b1a75dfc6bbe2c1d66ffd7fd78
2020-07-21 09:27:53 -07:00
Pascal Hartig
000e7f85bf Update lodash (security fix)
Summary:
Trying to get our OSS report green and lodash is currently flagged as a security issue on GH.

Manually merged the different PRs on GitHub together.

Reviewed By: jonathoma

Differential Revision: D22599614

fbshipit-source-id: ea4c9abf21aade14cff9338b78b764b181193227
2020-07-17 14:36:24 -07:00
Pascal Hartig
9d57a667ef Bump @types/testing-library__react from 10.0.0 to 10.2.0 in /desktop (#1366)
Summary:
Created a few breakages. Would appreciate some closer eyes on this.

Pull Request resolved: https://github.com/facebook/flipper/pull/1366

Reviewed By: mweststrate

Differential Revision: D22501454

fbshipit-source-id: 9b882a12aecc65da85f29101bf87bf27519a7d2a
2020-07-14 06:19:16 -07:00
generatedunixname89002005306973
fff723d5ef Flipper Release: v0.50.0
Summary: Releasing version 0.50.0

Reviewed By: passy

Differential Revision: D22501533

fbshipit-source-id: 0896efd4eb2b2bb5f557d573526db91dc5dcd1de
2020-07-13 04:15:23 -07:00
Paco Estevez Garcia
29b6be23e8 Remove unused prop
Summary:
While reading through the Inspector I found this prop passed down and not used anywhere

printer_shredder

Reviewed By: Katalune

Differential Revision: D22431895

fbshipit-source-id: 6cbc97b3faec26349a1ad900ffa455e95f53bb2b
2020-07-08 07:13:38 -07:00
Michel Weststrate
bf79c9472e Always mock FBLogger during unit tests
Summary: Unit tests tend to randomly bail out once FBLogger is (indirectly) required by some module under test. This makes sure FBLogger is stubbed by default. We might want to do the same for `User` in the future.

Reviewed By: jknoxville

Differential Revision: D22186274

fbshipit-source-id: 2ede364c4b691d69826781355592226b075d8367
2020-07-01 09:12:35 -07:00
generatedunixname89002005306973
8000090eac Flipper Release: v0.49.0
Summary: Releasing version 0.49.0

Reviewed By: cekkaewnumchai

Differential Revision: D22307632

fbshipit-source-id: 105fc71f07a4827a5d6e54cf3200b22f800a5f1e
2020-06-30 06:33:04 -07:00
Pascal Hartig
011952d73c Flipper Release: v0.48.0
Summary: Releasing version 0.48.0

Reviewed By: mweststrate

Differential Revision: D22207960

fbshipit-source-id: 7f21ff151c4e5750646a6dd3e39690229a2e73a5
2020-06-25 02:32:47 -07:00
Anton Nikolaev
4219df6a93 Remove prepack script from each plugin
Summary: Removed back "prepack" script from every plugin package to keep it simple. Instead we will use `build-plugin` command defined in the root package.json (see next diff in the stack).

Reviewed By: mweststrate

Differential Revision: D22160252

fbshipit-source-id: cffb5df65b89df3fe390c051da0df797b3d16d2d
2020-06-22 08:15:56 -07:00
Anton Nikolaev
2085d4e362 Fix layout plugin source import violation
Summary: Fixed direct source import of Flipper code from layout plugin which broke its packaging

Reviewed By: cekkaewnumchai

Differential Revision: D22135716

fbshipit-source-id: 8f67a21ed94c13dd73d24ef8692d37ae51963319
2020-06-19 08:44:51 -07:00
generatedunixname89002005306973
43b9426ff4 Flipper Release: v0.47.0
Summary: Releasing version 0.47.0

Reviewed By: jknoxville

Differential Revision: D22089288

fbshipit-source-id: 0107d1f17cce8c9adc2b9c26d48a6d80797749be
2020-06-17 09:00:07 -07:00
Anton Nikolaev
f5a8e929c0 Bump plugin versions to match Flipper version (#1267)
Summary:
Pull Request resolved: https://github.com/facebook/flipper/pull/1267

Bumped versions of all plugins to match current Flipper version 0.46.0.

Reviewed By: mweststrate

Differential Revision: D22042959

fbshipit-source-id: 37c169bfd1b90debb8f94c9465a345a015524158
2020-06-15 09:28:23 -07:00
Anton Nikolaev
8003e7eb34 Migrate all plugins to spec v2
Summary: All the plugins migrated to spec v2 to allow packaging/publishing them independently from Flipper releases.

Reviewed By: passy

Differential Revision: D22041384

fbshipit-source-id: 23bfaf724f771a57bd628b9ea1c4d37846534a93
2020-06-15 07:29:34 -07:00
Michel Weststrate
db4c341eb3 Fix regression in accessibility layout
Summary:
Fixes a regression (D21716761) in the layout of the accessibility inspector where the layout was accidentally switched from right to bottom.

Also made the region resizable while at it.

Changelog: Fix regression in the layout plugin where accessibility info was rendered in the wrong place

Reviewed By: cekkaewnumchai

Differential Revision: D21903760

fbshipit-source-id: 08623c17428e86ea77d8438e78766a308dbac1e6
2020-06-05 08:34:26 -07:00
Michel Weststrate
54162d480c Enable react hooks linting
Summary:
Enabled linting rules that help to signal making errors with effect dependencies and such.

Fixed all errors, left any warnings generated by the hooks untouched

Reviewed By: nikoant

Differential Revision: D21721497

fbshipit-source-id: 9548453443fa7b663dc4d4289132f388c6697283
2020-05-28 10:14:05 -07:00
Pritesh Nandgaonkar
c9d2acab08 Remove flipper AD bar
Summary: This diff removes the FlipperAD bar which is shown in the layout inspector. Fixes [this](https://fb.workplace.com/groups/flippersupport/permalink/881019929045333/)

Reviewed By: passy

Differential Revision: D21716761

fbshipit-source-id: 503fc0002d137032c9a40853f7eeea599d65acea
2020-05-26 04:34:29 -07:00
Michel Weststrate
cdd0026e83 fix issue where row backgrounds are not continued when scrolling horizontally
Summary:
We used flexbox to layout rows in the element inspector. The problem with that is that flexbox cannot nicely grow all its childrens to the largest one. Although we could still see contents thanks to the `overflow: visible` hack, this means that the backgrounds didn't continue when scrolling.

In contrast, tables do grow their children width :)

Also fixed an issue where the AX details tree wasn't scrollable

Reviewed By: cekkaewnumchai

Differential Revision: D21661766

fbshipit-source-id: 6b1d16c7aded8beebdd8a50f3e8ab0d9b8633e02
2020-05-21 03:36:35 -07:00
Michel Weststrate
b0ab9b9b98 Fix Height for Main Layout Inspector
Summary:
in Layout plugin, scrollbars where often not visible, for example to see the vertical scrollbar, one had to scroll to the horizontal end first.

Also introduced the `Scrollable` component to simplify this in the feature and separate the concepts of rendering something large and making it scrollable.

This diff cleans up the layout structure and fixes the problem

changelog: Fixed several minor layout issues in the Layout plugin

Reviewed By: cekkaewnumchai

Differential Revision: D21283157

fbshipit-source-id: 81849151475165796c65001616f038a9d6cbdfb2
2020-05-21 03:36:34 -07:00
Chaiwat Ekkaewnumchai
8fa03789d1 Add Coverage Test for MultipleSelectorSection
Summary:
To comply with recent agreement, coverage test for MultipleSelectorSection is added.

Also, add undefined check in `elements.tsx` found while adding the test

Reviewed By: mweststrate

Differential Revision: D21554782

fbshipit-source-id: 7cd868bf16f6105d6f523048f29bdaa052837f45
2020-05-15 12:49:28 -07:00
João Vieira
a2d7297bbb Rename Flipper trace to Flipper export.
Summary: Rename visual references from Flipper trace to Flipper export.

Reviewed By: passy

Differential Revision: D21408566

fbshipit-source-id: 1021fec095f2f2f3e5394e7ea2f7d49fee186050
2020-05-07 04:05:27 -07:00
Chaiwat Ekkaewnumchai
8a06f4bd72 Unit Test for Multiple Selector Data Handler
Summary: per title

Reviewed By: mweststrate

Differential Revision: D21304005

fbshipit-source-id: 97231d49a2c6fb3faeafa15587bc140bdc1dbea3
2020-05-07 03:41:01 -07:00
Chaiwat Ekkaewnumchai
6daff06e19 (server) Click to Expand in Multiple Selector
Summary:
per title

Changelog: Add multiple selector to layout inspector to allow user to select components at a position

Reviewed By: mweststrate

Differential Revision: D21214898

fbshipit-source-id: 7b52d9d3c93e7ec0d28124a3a675ccfdd014c54d
2020-05-07 03:41:00 -07:00
Chaiwat Ekkaewnumchai
a6b69f7939 (server) Make Multiple Selector Collapsable
Summary: per title

Reviewed By: mweststrate

Differential Revision: D21214900

fbshipit-source-id: 61e565391ca7d5796bb22c9ece76ea5dabe97be7
2020-05-07 03:41:00 -07:00
Chaiwat Ekkaewnumchai
83a2203751 (server) Multiple Selector on Layout Inspector
Summary:
This diff adds multiple selector UI on layout plugin, which shows up when there are more than one component at a touch.

This UI allows user to do similar thing to element inspector. Expanding functionality on main component will be added in next diffs.

Reviewed By: mweststrate

Differential Revision: D21214899

fbshipit-source-id: 5c9cae93122cc4f7c326ccd0878d2b9dddebf62b
2020-05-07 03:41:00 -07:00
Chaiwat Ekkaewnumchai
a7163bf06d (server) Add New Parameter And Functions for Select Subscriber
Summary:
- add type to represent the returned component tree
```
expected data:
{
  [nodeID1]: [subtree1],
  [nodeID2]: [subtree2],
  ...
}
example:
{
   id1: {
    id2: {
      id3: {
        id4: {},
        id5: {
          id6: {}
        }
      }
    }
  }
}
```
- add functions to deal with a tree
  - `_getElementLeaves` for finding ids that don't have any child given the tree structure
  - `_getPathForNode` for finding path (similar to previous path parameter) for given id
- This diff still retain functionality in case of selector appear to touch only one element.

Reviewed By: mweststrate

Differential Revision: D21040427

fbshipit-source-id: e6704535a437ad47d9664cc16896b9f24c9d6736
2020-05-07 03:40:57 -07:00
Chaiwat Ekkaewnumchai
475a425a20 Change ElementID to Element for Sidebar Extension
Summary: Element also contains `id`, which is equivalent to ElementID used in the existing extension. This change will help the implementation of layout intern search easier.

Reviewed By: mweststrate

Differential Revision: D21385001

fbshipit-source-id: b8c6e6f052af8cfa54bf3a132571e40567cdee4b
2020-05-05 06:48:00 -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
Pritesh Nandgaonkar
17ccdeaf6f Change the export logic for the Inspector
Summary:
This enables the feature which showed the theme information in the layout plugin. It was disabled due to the OOM which occurred while exporting flipper trace. The OOM happened when we tried to serialise the whole layout hierarchy and the amount of info added per node by the theme info was quite heavy. Thus removing it solved the OOM problem at that point, but its not the correct solution.

The problem is that each node has too much information and sending it at one stretch is very heavy and causes OOM. So instead of sending it at one stretch, I have broken it into multiple calls at each level of the tree. This no longer causes OOM and we will be able to show theme information too.

Also for iOS we don't have AXNodes call or AXRoot feature implemented, so anyway I had to put a check to not make those calls, so instead I have kept the feature of fetching all nodes on the iOS instead, as there has been no problem on the iOS side with regards to the OOM. But I am indifferent, the same logic will work for iOS too, it might increase the time to export.

issue discussed [here](https://fb.workplace.com/groups/flippersupport/permalink/854729375007722/)

Reviewed By: jknoxville

Differential Revision: D21136057

fbshipit-source-id: becd237a6d53c50af082597f2e8ed790c25cb966
2020-04-23 04:31:17 -07:00
Timur Valiev
764ba546f7 Move ToolbarIcon to main ui components folder
Summary: there are two plugins which uses copy-pasted ToolbarIcon and at least one more where it will be helpful. Let's move it to components folder

Reviewed By: nikoant

Differential Revision: D21089290

fbshipit-source-id: a14dcd56633dd24016711e34308b94023fcb40ed
2020-04-21 09:23:46 -07:00
Anton Nikolaev
bcc133026e Add public plugins to the root package.json as workspaces (#969)
Summary:
Pull Request resolved: https://github.com/facebook/flipper/pull/969

Added all public plugins as workspaces to the root package.json. This means all these plugins will use the single root yarn.lock and installation of their dependencies will be faster. This also means that plugins can declare dependencies to other local packages included into workspaces and they will be symlinked automatically.

Changelog: Internals: plugins added as "yarn workspaces" into the root package.json to simplify dependency management between them

Reviewed By: mweststrate

Differential Revision: D20805231

fbshipit-source-id: e85c62d3195d1ea3c5c60def6ca12318a2b53466
2020-04-14 07:20:38 -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
10d990c32c Move plugins to "sonar/desktop/plugins"
Summary:
Plugins moved from "sonar/desktop/src/plugins" to "sonar/desktop/plugins".

Fixed all the paths after moving.

New "desktop" folder structure:
- `src` - Flipper desktop app JS code executing in Electron Renderer (Chrome) process.
- `static` - Flipper desktop app JS code executing in Electron Main (Node.js) process.
- `plugins` - Flipper desktop JS plugins.
- `pkg` - Flipper packaging lib and CLI tool.
- `doctor` - Flipper diagnostics lib and CLI tool.
- `scripts` - Build scripts for Flipper desktop app.
- `headless` - Headless version of Flipper desktop app.
- `headless-tests` - Integration tests running agains Flipper headless version.

Reviewed By: mweststrate

Differential Revision: D20344186

fbshipit-source-id: d020da970b2ea1e001f9061a8782bfeb54e31ba0
2020-03-14 14:35:18 -07:00