Commit Graph

1716 Commits

Author SHA1 Message Date
Daniel Büchele
262b1fd4a9 flowconfig TsStub
Reviewed By: passy

Differential Revision: D16647501

fbshipit-source-id: ed92153fcf48574c5ae032131cb8d8dc4b00baf2
2019-08-05 10:29:14 -07:00
Benjamin Elo
5aadbde4b9 Added missing key props
Summary: This was an error appearing in the console that was bugging me. About how arrays of React nodes should have a key prop.

Reviewed By: passy

Differential Revision: D16646487

fbshipit-source-id: b61841c001eb4a93f0a071557b921ca7365e2ac3
2019-08-05 09:39:06 -07:00
Benjamin Elo
c45724a767 Pass selectedApp as prop to FlipperPlugin
Summary: I have found it neccessary to get the current app name for the Navigation plugin. This passes the current selectedApp as a prop into any FlipperPlugin.

Reviewed By: jknoxville

Differential Revision: D16645855

fbshipit-source-id: 996d41b1a0e939427e66fa0df172ce1a6471f686
2019-08-05 03:59:10 -07:00
Pascal Hartig
e87a1a44c4 Upgrade deps in static/
Summary: Same as previous diff, but for `static/`.

Reviewed By: danielbuechele

Differential Revision: D16579860

fbshipit-source-id: aa4449ded8734270fb5e1ab400a95768c6a1c09f
2019-08-05 03:52:41 -07:00
Pascal Hartig
8b2009b2c7 Upgrade deps within range
Summary:
This is the result of a `yarn upgrade`. While this *shouldn't* break
anything, it easily can just as this broke the babel transform
because a previously transitively depended upon library was no
longer included.

It seems like a good idea to stay as close as possible to the upstream of all
the dependencies we have and with the release yesterday we now have one week to
check if the rest works as expected.

allow-large-files

Reviewed By: danielbuechele

Differential Revision: D16579807

fbshipit-source-id: f26d4536abd80f428e94b71e0fa98df612cbd809
2019-08-03 03:33:43 -07:00
Daniel Büchele
16e913a819 local icons
Summary:
Currently icons were always fetched remotely. We used a service worker to prefetch and cache some icons, that were critical to the UI.

In this diff, we are bundling icons at build time, with the app. In utils/icons.js we still specfify the list of icons which should be bundled. These are downloaded as part of the build step and bundled with the app. We are downloading the icons in 1x and 2x (the two most common pixel densities).

Reviewed By: jknoxville

Differential Revision: D16620764

fbshipit-source-id: 965a7793ad1f08aebb292606add00218429cdaf4
2019-08-02 09:00:00 -07:00
Zoltán Gilián
1717fba410 Add option to disable keyboard navigation in ManagedTable
Summary: This may be needed e.g. if there are multiple ManagedTables in the window.

Reviewed By: jknoxville, danielbuechele

Differential Revision: D16620862

fbshipit-source-id: 1880e9e6e8e9ece5f687b2768eae7c4f206f69da
2019-08-02 08:35:16 -07:00
Benjamin Elo
ea8a6546c9 Added providers to the auto complete sheet
Summary:
Okay so the main changes here are integrating the providers into the auto complete sheet and getting the search bar to work with it also.

For instance, in the search bar, I want to update the value string to whatever the user has highlighted in the auto complete sheet, without executing a new query. So thus, I had to create a new state variable in the search bar component for this.

I've also moved the custom hook into its own file to keep the component short in size. It had to be mainly rewritten to support providers instead of only bookmarks. Same goes for the entire AutoCompleteSheet component.

The bookmarksProvider is stored in the persisted state as to not regenerate every-time on render. It is only updated if the bookmarks are updated which are also now stored in the persistedState for the same reason.

Lastly, a DefaultProvider object was also made for the initial persisted state object.

Reviewed By: danielbuechele

Differential Revision: D16581644

fbshipit-source-id: 88723a4081d96250f723a4cd7b1ade101bf3e8f3
2019-08-02 01:58:02 -07:00
Sara Valderrama
f591475f85 A few mini-fixes for the accessibility layout inspector
Summary:
- fix mutual selection of elements in ax and non-ax tree (simplifies linkedNode logic as well)
- remove unneeded extraInfo attributes (focused, nonAXwithAXchild, & hasAXNode were not/no longer being used)
- use 50/50 fixed width view for trees when both are visible

Reviewed By: jknoxville

Differential Revision: D16390355

fbshipit-source-id: bbf9ea887f8f1035df8b4b0562ddcc4de291f004
2019-08-01 22:03:26 -07:00
Pritesh Nandgaonkar
3ed71680a1 Remove the unwanted parantheses
Summary:
Bug:

{F173026649}

Reviewed By: danielbuechele

Differential Revision: D16583186

fbshipit-source-id: 277a81fbabf0c93d1a69b7f35dcb9d8d06ca4fce
2019-07-31 11:13:24 -07:00
Pritesh Nandgaonkar
8c9eb30060 Run export flipper trace in background
Summary: Adds the capability to run the export in the background along with the display of the status in the title bar.

Reviewed By: danielbuechele

Differential Revision: D16567026

fbshipit-source-id: 3955243cd7f094a7ee33eef3511804ff6e6476be
2019-07-31 10:44:26 -07:00
Pascal Hartig
84b64b75dc Precache ratings icons
Summary:
Supersedes D16580111.

Makes sure that rating icons are prefetched.

Reviewed By: bnelo12

Differential Revision: D16582032

fbshipit-source-id: d07db936f284d7aedb0f8dbfdae7738b305eb848
2019-07-31 10:39:29 -07:00
Benjamin Elo
7a55fbc8dd Added auto complete provider utility functions
Summary:
These are a series of utility functions for the auto complete system in the nav bar.

Essentially, the auto complete system will gather information from Providers. Providers provide auto complete information from various sources i.e. bookmarks, recently viewed, or uri match patterns from the build.

There are two main functions in this commit. The first is to turn the bookmarks Map into a Provider (bookmarksToAutoCompleteProvider). This runs in O(n) time where n is the number of bookmarks. A provider has an associated icon and matchPatterns to match what the user types to a uri. Here I concatenate the commonName and the uri of the bookmark together for the match pattern so that the user can search for both.

filterProvidersToLineItems takes an Array of providers and returns line items. These are objects that will be displayed by the nav bar auto complete system. This has a little bit of a longer running time. O(mnop). Where m is the number of providers, n is the number of items in the largest provider, o is the length of the query and p is the length of the line items. This may seem bad, but I've tested the performance using 364 entries and it completes the function in less than a millisecond.

The Providers will have precedence in the final auto complete box. With the most recent provder taking the most precedence, followed by bookmarks, followed by match patterns.

Reviewed By: danielbuechele

Differential Revision: D16568500

fbshipit-source-id: 00b043d51051ee86b3dbe18564e6f582b19e5359
2019-07-31 10:18:55 -07:00
Roman Gorbunov
00e8f43e37 Improvement of live editing
Summary:
Live editing is now working faster.
We had an issue that it took about 5 seconds to see the view changed and 10 seconds to see tha value in the flipper, now it's done immidiately

Reviewed By: priteshrnandgaonkar

Differential Revision: D16500961

fbshipit-source-id: 742ce628a887bab06c1b883d9710c477af2508e7
2019-07-31 03:13:38 -07:00
Pascal Hartig
43a3c33347 Travis wait (#506)
Summary:
Depends on https://github.com/facebook/flipper/issues/505.

The test case there works for the JS part but times out during the XCode build. This gives us a bit more time.
Pull Request resolved: https://github.com/facebook/flipper/pull/506

Reviewed By: priteshrnandgaonkar

Differential Revision: D16561461

Pulled By: passy

fbshipit-source-id: 15cc18b8c57732ef73a874256305542d439b3d2c
2019-07-31 01:44:58 -07:00
Pascal Hartig
9c2ae7632c Bump node in Travis to 11 (#505)
Summary:
Attempt to fix the spurious failed assertions coming from libuv in Travis.
Pull Request resolved: https://github.com/facebook/flipper/pull/505

Reviewed By: priteshrnandgaonkar

Differential Revision: D16561381

Pulled By: passy

fbshipit-source-id: 4b30e9cadc37071404ec0198f96b7cd20761325a
2019-07-31 01:44:58 -07:00
Sidd Srinivasan
0c37a93a84 Add path to adb in production env
Summary: Move from adding adb path in tracery plugin to adding flipper as a whole. Se discussion here: D16494684

Reviewed By: jknoxville

Differential Revision: D16542414

fbshipit-source-id: abb2f4989693025a8bfe7d12f4c328870a962204
2019-07-30 07:07:18 -07:00
Pritesh Nandgaonkar
b1fd70a3c3 Show status message with percentage for the seriailization
Reviewed By: passy

Differential Revision: D16382096

fbshipit-source-id: 17c44a7befcef82815dc9d2379898e23a36a05c8
2019-07-30 06:50:23 -07:00
Pascal Hartig
c2a07f0607 Flipper Bump: v0.23.5-SNAPSHOT
Summary: victorversion

Reviewed By: jknoxville

Differential Revision: D16559673

fbshipit-source-id: 6f92601443e1f74a3906b7ab0971c7780aba8995
2019-07-30 03:09:42 -07:00
Pascal Hartig
6194541822 Flipper Release: v0.23.4
Summary:
# New Features

- Select plugins to include in your exports.

# Fixes and chores

- Run TSC in Travis.
- Restore Android build in Travis.

[Full Changelog](https://github.com/facebook/flipper/compare/v0.23.3...v0.23.4)

Reviewed By: jknoxville, danielbuechele

Differential Revision: D16559674

fbshipit-source-id: 919f758f8750d26d9e49b6721d05264880d0abc5
2019-07-30 03:09:41 -07:00
Pascal Hartig
81fddbaff4 Bump lodash from 4.17.10 to 4.17.15
Summary: This is just to clear a security warning.

Reviewed By: danielbuechele

Differential Revision: D16542869

fbshipit-source-id: 910c421292efeff2d65769e0c00cea7e4653233d
2019-07-30 02:38:29 -07:00
Pascal Hartig
dd59daffa3 Disable onMessageCallback logging
Summary:
Will post about this in more detail later but in short, this is taking
up wayyyy too much space.

Reviewed By: danielbuechele

Differential Revision: D16543587

fbshipit-source-id: 8130a1a8378e5a6ffde669d651063ef92eb021c0
2019-07-29 10:42:05 -07:00
Benjamin Elo
0609811224 Added dropdown sheet for nav bar
Summary:
Here I've added a drop down sheet for the nav bar. Currently it only supports showing the first five bookmarks with no filtering.

I use a custom hook to handle navigation with the keyboard in the nav bar, so that works well.

So you can use the arrow keys to select a uri from the dropdown, or by using the mouse.

Reviewed By: danielbuechele

Differential Revision: D16542218

fbshipit-source-id: 4c242fd3097297fc599b36523bb4821bbc172f88
2019-07-29 10:13:37 -07:00
Daniel Büchele
d0d3daf710 fix lint command
Reviewed By: jknoxville

Differential Revision: D16543448

fbshipit-source-id: ff37739ada0f5b4060a6c363da584e19a534aca1
2019-07-29 10:04:28 -07:00
Pascal Hartig
0c862e1e12 Force trusty for Android builds (#503)
Summary:
The Android build is currently broken and this coincided with the switch from `trusty` to `xenial`.

![Screenshot 2019-07-29 15 58 46](https://user-images.githubusercontent.com/9906/62058727-c923bd80-b219-11e9-8edd-231bc700dda3.png)
(green build)

![Screenshot 2019-07-29 15 58 52](https://user-images.githubusercontent.com/9906/62058731-ca54ea80-b219-11e9-8773-29f3ff412bde.png)
(red build)

It looks like Travis messed up their provisioning profiles and is shipping non-Android images for Android build tasks. Not cool.

https://travis-ci.org/facebook/flipper/jobs/564982262
Pull Request resolved: https://github.com/facebook/flipper/pull/503

Reviewed By: danielbuechele

Differential Revision: D16542462

Pulled By: passy

fbshipit-source-id: 99878f623d912e4b9a2b72953ca479fcc6e55adf
2019-07-29 09:49:45 -07:00
Pascal Hartig
e84b03f8c3 Upgrade Flow to 104
Summary: No breaking changes affecting us, just one FlowFixMe that's no longer necessary. Yay.

Reviewed By: jknoxville

Differential Revision: D16541069

fbshipit-source-id: 12d1fadf57daf1ec23d043206f99b0eb61b28e5b
2019-07-29 08:04:32 -07:00
Daniel Büchele
8e0fd24fed Run TSC
Summary: Run TSC in Sandcastle to make sure everything is typed nicely.

Reviewed By: jknoxville

Differential Revision: D16202412

fbshipit-source-id: 23064d5a0b327c32d0b633f9234882a46f88270e
2019-07-29 06:39:11 -07:00
Daniel Büchele
2c7371d264 typescript eslint plugin
Summary: This is required to properly run eslint in Atom/VSCode on TypeScript files

Reviewed By: jknoxville

Differential Revision: D16201418

fbshipit-source-id: 31da04c2d313e9147e0f868c1af15bf3115e6d6a
2019-07-29 06:39:11 -07:00
Pascal Hartig
2dd580f24a Fix flow errors (#502)
Summary:
We had a brief moment without Flow coverage, where this must have snuck
in. Not sure if there's a better type for `node` given the current
structure, but the rest should be obvious.
Pull Request resolved: https://github.com/facebook/flipper/pull/502

Test Plan: flow

Reviewed By: jknoxville

Differential Revision: D16533248

Pulled By: passy

fbshipit-source-id: 51e493208050e4af531e161fb49eda77fdf2494e
2019-07-29 06:08:37 -07:00
Benjamin Elo
4372fccacc Alphabetize bookmarks
Summary: The bookmarks would appear in different order upon reloading the app. Here I have a fixed order.

Reviewed By: jknoxville

Differential Revision: D16540496

fbshipit-source-id: ebc3e1065dbd2ae76b919a943c2cc7f81d857ca8
2019-07-29 04:29:46 -07:00
Benjamin Elo
fc28b904a0 Added ability to remove bookmarks
Summary: Here I add the ability to remove bookmarks. If a bookmark already exists, a different dialouge menu appears.

Reviewed By: danielbuechele

Differential Revision: D16540394

fbshipit-source-id: 5d6737e1efb1a9663519bf17084ef3b55a6ba28e
2019-07-29 04:29:45 -07:00
Benjamin Elo
292efb0bb3 Moved NavPlugin types into seperate file
Summary: Moved Flow types into their own file. I will be adding more types as part of the auto complete for the navigation bar and this is to keep the code more organized.

Reviewed By: danielbuechele

Differential Revision: D16540279

fbshipit-source-id: d69ac0d05f91e9d92fcda37325c791ddc83a52c9
2019-07-29 03:47:49 -07:00
Benjamin Elo
84f9a1d8b5 Added ability to save bookmarks in Nav Plugin
Summary:
This is a glue commit that glues all the components I've added in the past together.

Favouriting a page (i.e. clicking on the star) adds it as a bookmark.

There's four main parts to make your rreview easier:
1. Add bookmarks and favouriting to all the components that support it, including their parents. (NavigationInfoBox, SearchBar, Timeline)

2. Persist bookmarks using the indexedDB. (index.js)

3. Add saving to db through the SaveBookmarksDialog

4. Various other changes due to a changed architecture. i.e. moving bookmarks from persistedState to state.

Still to come.

1. Removing bookmarks.

2. Pressing enter to save the bookmarks when the SaveBookmarksDialog pops up.

3. Alphabetizing bookmarks? Order seems to jump around.

Reviewed By: jknoxville

Differential Revision: D16518013

fbshipit-source-id: 2e0cef14123c611db43cca360bc66dc4c05b11ed
2019-07-28 12:50:31 -07:00
Benjamin Elo
e4601a89f3 Added IndexedDB utility functions for reading and writing bookmarks
Summary:
These are utility function for reading from the IndexedDB and writing to it. This will be used for persistant storage of bookmarks.

The reason I chose IndexedDB over local storage is due to the poor efficiency of stringifying and parsing a long list of bookmarks everytime we read and write to local storage.

With IndexedDB we can modify a single value at a time.

Bookmarks are passed around as a Map, with the key being the uri's and the common names being the values. This allows me to check if a specified uri is in the Map in O(1) time, so that I can highlight the star icon in the UI with gold.

Reviewed By: jknoxville

Differential Revision: D16498744

fbshipit-source-id: 7c7af28bf4eb3fcc985a71dfd61ffbdb8481b6a6
2019-07-28 12:50:31 -07:00
Brian Vaughn
f6a4ad59c0 Update react-devtools-core to 3.6.3 to fix React Inspector
Summary:
It appears that Electron (or the version of Chromium it uses) has a bug that causes a `webview` process to crash if `URL.createObjectURL` is used.

Before releasing `react-devtools-core` 3.5.0, we updated Webpack and the loaders we used. Apparently the version of `style-loader` we now use makes use of the `URL.createObjectURL` API for CSS source maps. This triggers the `webview` crash I mentioned above.

The fix for this is to disable CSS source maps, in which case the loader just uses a `<style>` tag. This diff updates Nuclide to pull in this fixed version.

Reviewed By: bestander

Differential Revision: D16518772

fbshipit-source-id: a779b7d310f869793fa05988d138ce6a46840d8c
2019-07-26 14:47:03 -07:00
Pritesh Nandgaonkar
e7198040ea Add UI to select plugins
Summary: Adds UI to the select the plugin to export. It lists the plugins which has currently some data in the redux store and it also lists those plugins which has implemented `exportPersistedState` function, as it might happen that the redux store may not have the data for a plugin but it will still export the data by calling `exportPersistedState`, which will ping the mobile client to get the data at point while we export the flipper trace.

Reviewed By: jknoxville

Differential Revision: D16468408

fbshipit-source-id: 452a7caf7199dd2b8df330bbb10d0a90008e92ec
2019-07-26 10:53:27 -07:00
Cory Wilhite
aa470a9aef Compile out objc_msgSend_stret on 64 bit machines
Summary: objc_msgSend_stret isn't available when building for 64 bit devices so this line breaks. objc_msgSend is the correct function to call in 64 bit, but Flipper doesn't run for devices so its fine either way.

Reviewed By: jasonhotsauce

Differential Revision: D16502377

fbshipit-source-id: cfc20880bcccd086dc34fad74a6eef2c9a17cb17
2019-07-25 16:42:36 -07:00
Sara Valderrama
594565de31 Fix icons url redundancy for variant argument
Summary: Update Flipper icon request URL (variant argument was appended twice in certain cases).

Reviewed By: jknoxville

Differential Revision: D16443282

fbshipit-source-id: e64e03e40030baa1a7e6067cfc2a9aaf7a75302a
2019-07-25 13:26:06 -07:00
John Knox
b0140c6364 Add rating tooltip
Summary: I felt it would be good to say what these stars are actually for.

Reviewed By: passy

Differential Revision: D16457243

fbshipit-source-id: 961933f71efdcb6835936d5e1da7fe817eccc996
2019-07-25 07:12:45 -07:00
Benjamin Elo
dbfc7ae416 Added SaveBookmarkDialog component
Summary: This adds a dialog box component that allow saving of bookmarks.

Reviewed By: jknoxville

Differential Revision: D16491842

fbshipit-source-id: fc8332bba491ad0583564fd6a85b5ad225bbd461
2019-07-25 06:54:39 -07:00
John Knox
4d4a872208 Flipper Bump: v0.23.4-SNAPSHOT
Summary: Follow up release to fix https://github.com/facebook/flipper/issues/498

Reviewed By: passy

Differential Revision: D16487948

fbshipit-source-id: 33e0246752c986ac2c8149bc82e26d8db6aee053
2019-07-25 04:52:45 -07:00
John Knox
39d40cc4c3 Flipper Release: v0.23.3
Summary: Follow up release to fix https://github.com/facebook/flipper/issues/498

Reviewed By: passy

Differential Revision: D16487947

fbshipit-source-id: fbdd18ebd7af260450d93016f25f5e215419d8aa
2019-07-25 04:52:45 -07:00
John Knox
d0a61d6455 Back out "[flipper] Add 1h tolerance to ssl certs"
Summary:
Original commit changeset: bdbd61bce1bc

That change appears to be causing some issues for open source users: https://github.com/facebook/flipper/issues/498

To mitigate the issue I'm reverting it, the change turns out to be unnecessary anyway.

Reviewed By: passy

Differential Revision: D16486136

fbshipit-source-id: 70decca6e017a6a2903cc484641fb2e736dc5d7c
2019-07-25 04:11:59 -07:00
Roman Gorbunov
a903c7ddc6 CKCenterLayoutComponent live editing
Summary:
CKCenterLayoutComponent's options are now live editable

P.S. Now it takes some time to see the view changed and the new value of everything on flipper side

Reviewed By: kevin0571

Differential Revision: D16458390

fbshipit-source-id: a5344253641633dd8c985549c2d9bc6f64da1f74
2019-07-25 04:03:04 -07:00
Roman Gorbunov
a6b374aba7 CKRatioLayoutComponent live editing
Summary:
CKRatioLayoutComponent's ratio is now live editable

P.S. Now it takes some time to see the view changed and the new value of everything on flipper side

Reviewed By: kevin0571

Differential Revision: D16458380

fbshipit-source-id: 0f06426477b6747f6ad71716dc66e69316b23208
2019-07-25 04:03:03 -07:00
Roman Gorbunov
b697d147d1 CKFlexboxComponent live editing
Summary:
CKFlexboxComponent's insets are now live editable

P.S. Now it takes some time to see the view changed and the new value of everything on flipper side

Reviewed By: kevin0571

Differential Revision: D16379743

fbshipit-source-id: 69bc9b7cb6b2103ff34b5c4489b240ac7562a85d
2019-07-25 04:03:03 -07:00
Roman Gorbunov
f42badeb88 CKInsetComponent live editing
Summary:
CKInsetComponent's insets are now live editable
P.S. Now it takes some time to see the view changed and the new value of insets on flipper side

Reviewed By: kevin0571

Differential Revision: D16338109

fbshipit-source-id: 9c6648e72d55a09df9d715637e82901d1b5dcec8
2019-07-25 04:03:03 -07:00
Roman Gorbunov
f2bc5d3fb2 Generic solution for live editing
Summary: Preparation for making components live editable

Reviewed By: kevin0571

Differential Revision: D16379961

fbshipit-source-id: d0ea3d753eb588fe7b55f2345124427b4a5a58b5
2019-07-25 04:03:03 -07:00
Roman Gorbunov
cb374ffccd Flipper sent messages while editing
Summary: In previous version when you edited something in the flipper, after each symbol flipper sent a message to edit a value to mobile side. Now "change message" will be sent only after pressing "Enter" button.

Reviewed By: priteshrnandgaonkar

Differential Revision: D16338101

fbshipit-source-id: 6605663d0b0059fdb2d20cb279e133afc25d47f1
2019-07-25 04:03:02 -07:00
Roman Gorbunov
89911acd84 Made a DataStorage for live editing in flipper
Summary: Theadsafe Data Storage for new insets in CKInsetComponent

Reviewed By: kevin0571

Differential Revision: D16338091

fbshipit-source-id: 3b77652a4d08cfebce115a606af3fc3440a1aca0
2019-07-25 04:03:02 -07:00