Commit Graph

213 Commits

Author SHA1 Message Date
Adam Ernst
2b050851a3 Split and fix FBCxxUtils
Summary: This target was bloating. Split it in two. Migrate to autotests.

Reviewed By: joshleibsly

Differential Revision: D16829348

fbshipit-source-id: 17f2a10371293ddb850c4556abeecee99a9d7bef
2019-08-15 09:53:48 -07:00
Spencer Baumgardner
d68dac2ce0 Convert nlohmann::json to NSDictionary
Summary: T46426056: Add utility to convert nlohmann::json to NSDictionary. Use same in instagram logging module.

Differential Revision: D16798341

fbshipit-source-id: 88923fcbcd1ffbed5a468cee4ba2f9482ba81a97
2019-08-14 17:29:00 -07:00
Oleksii Dykan
dbf0e3db43 Add size prop to layout inspector
Summary: Size is passed as a prop to every `CKComponent` and `CKFlexboxChild`. It is useful to see where it was set exactly

Reviewed By: kevin0571

Differential Revision: D16688496

fbshipit-source-id: 5f8dc39a967ab2d7d89d6a37a8152aa6b59db220
2019-08-07 10:24:19 -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
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
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
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
John Knox
f0be2c5b2e Remove unused import
Summary: This isn't necessary

Reviewed By: passy

Differential Revision: D16358413

fbshipit-source-id: b4bc0af3d671ed9be080eae24f69054cb2623ba4
2019-07-18 11:14:53 -07:00
Pritesh Nandgaonkar
aebca6bb57 Update OpenSSL dependency
Summary: Updated the OpenSSL dependency and released the new versions of Folly and RSocket.

Reviewed By: jknoxville

Differential Revision: D16222388

fbshipit-source-id: e894650a8c3ac764bc489e843e9a3ccf33688659
2019-07-12 09:35:52 -07:00
Roman Gorbunov
cf1347d2e3 Fixed bug with flipper live editing
Summary:
Fixed bug with live editing
Previously if the meaining of the value was changed in flipper you receive back same value as it was
Now you see correct changed value

Reviewed By: priteshrnandgaonkar

Differential Revision: D16162141

fbshipit-source-id: 1a68ea64603171e952382c5093470d2cc12f7bbe
2019-07-10 12:13:15 -07:00
Roman Gorbunov
8b2a886c19 Fixed a bug with accessibility button
Summary:
Fixed a bug with accessibility button
Now it's pressable

Reviewed By: kevin0571

Differential Revision: D16165294

fbshipit-source-id: 9c6ea464f2faa149aa78c0534c51a0f58bd249ad
2019-07-10 11:40:03 -07:00
Roman Gorbunov
7551b6da04 Added search in text of some components
Summary: Added a possibility to search for the text not only in name and id of components but also in text for all components, that conforms to a protocol <SKTextSearchable>

Reviewed By: priteshrnandgaonkar

Differential Revision: D16108297

fbshipit-source-id: 31da4ac6762c487ef644d62c9576d9eff43e8cd4
2019-07-08 03:43:55 -07:00
John Knox
b0f44d9a9b Add accessibilityIdentifier to iOS layout attributes
Summary: Apparently useful for debugging e2e tests which reference accessibility Identifiers

Reviewed By: passy

Differential Revision: D15874161

fbshipit-source-id: b6a71a8474b52546bd825c0d13c1487688c7a30e
2019-06-18 09:40:19 -07:00
suyimo
eb4de1f3b7 Add protect when save task (#466)
Summary:
Bugfix

Add protect when save task

If local cache resource are valid, we don't create a Task .So here are crash.
Pull Request resolved: https://github.com/facebook/flipper/pull/466

Reviewed By: passy

Differential Revision: D15851816

Pulled By: priteshrnandgaonkar

fbshipit-source-id: 753b3c5c9a6ed4c703c934a89e45fa30df99068c
2019-06-18 03:56:56 -07:00
Rain ⁣
aa649ff48f standardize C-like MIT copyright headers throughout fbsource
Summary:
`/*` is the standard throughout open source code. For example, Firefox uses single /*: https://hg.mozilla.org/mozilla-central/file/21d22b2f541258d3d1cf96c7ba5ad73e96e616b5/gfx/ipc/CompositorWidgetVsyncObserver.cpp#l3

In addition, Rust considers `/**` to be a doc comment (similar to Javadoc) and having such a comment at the beginning of the file causes `rustc` to barf.

Note that some JavaScript tooling requires `/**`. This is OK since JavaScript files were not covered by the linter in the first place, but it would be good to have that tooling fixed too.

Reviewed By: zertosh

Differential Revision: D15640366

fbshipit-source-id: b4ed4599071516364d6109720750d6a43304c089
2019-06-06 19:40:28 -07:00
Oleksii Dykan
cb79b3b9ba Fix layout plugin for CKFlexboxComponent and CKInsetComponent
Summary: Importing the extensions fixes the fact that responds to selector was returned false for `sonar_additionalDataOverride` selector

Reviewed By: priteshrnandgaonkar

Differential Revision: D15535414

fbshipit-source-id: ab465a1aab36cccd2129c5b0c29a7872dfd65015
2019-05-29 04:59:13 -07:00
Pritesh Nandgaonkar
7576e1c61d Fix watch tab bug
Summary:
This solves the watch tab crash discussed here D15266478, which got reverted.

Bug: [Here](diffusion/FBS/browse/master/xplat/sonar/iOS/Plugins/FlipperKitLayoutPlugin/FlipperKitLayoutPlugin/FlipperKitLayoutPlugin.mm;57c596a566bec49e343af51b93df65ed1377a2b9$338), when the node is `CKComponentRootView` the `[descriptor childForNode: node atIndex: i]` returns `SKComponentLayoutWrapper`. In the next iteration of the loop, node is `SKComponentLayoutWrapper`, the  `[descriptor childForNode: node atIndex: i]` returns `CKComponentRootView`, and hence the infinite recursion

I also tested T44431259, it is not regressed.

Reviewed By: passy

Differential Revision: D15451821

fbshipit-source-id: 25f10112f5f52bb1fa964316a4c7e91a3b29156d
2019-05-23 03:50:11 -07:00
Pritesh Nandgaonkar
0a514c3618 Back out "[Flipper] Use the tree node idenitifer as the component identifier"
Summary:
Original commit changeset: 4d83c1bee3fd

BUG:

{F159187385}

Reviewed By: passy

Differential Revision: D15415247

fbshipit-source-id: 6209a2c9c2b5da6b9405bf01e3cb7622b3431475
2019-05-20 09:46:50 -07:00
Jonathan Ballerano
bcc05296ef Back out "Fix the crash in the watch tab"
Summary: This resolves a crash related to the contents of certain CKComponents, which was apparently introduced by D15266478

Differential Revision: D15406260

fbshipit-source-id: efd1ad1a1bcb41451c56b74c240ad2dca069deb0
2019-05-17 22:42:35 -07:00
Pritesh Nandgaonkar
94231670f8 Commit Tutorial xcodeproj (#448)
Summary:
Commits the Tutorial Xcodproj. It was being ignored by .gitignore
## Changelog
Pull Request resolved: https://github.com/facebook/flipper/pull/448

Reviewed By: passy

Differential Revision: D15358598

Pulled By: priteshrnandgaonkar

fbshipit-source-id: ca6c16205ba7b5f66acb5545f468fb885806496d
2019-05-16 04:07:26 -07:00
Pritesh Nandgaonkar
07f327f46b Automate iOS release (#445)
Summary:
This PR sets up Circle CI to publish pods when github release is made. This PR also updates the Flipper-Folly pod as it didn't build on 32 bit architecture, because `thread_local` was not supported.

Automated publish of cocoapods through Circle CI.
Pull Request resolved: https://github.com/facebook/flipper/pull/445

Reviewed By: danielbuechele

Differential Revision: D15333975

Pulled By: priteshrnandgaonkar

fbshipit-source-id: 7db68efeeebbe344213917f10f9f3ce4132e8cbc
2019-05-14 07:24:10 -07:00
Pritesh Nandgaonkar
821232a9c6 Fix the crash in the watch tab
Summary:
BUG:

{F158264042}

Context: The code entered an infinite loop till it crashed. In the implementation of `- (SKSearchResultNode *)searchForQuery:(NSString *)query fromNode:(id)node withElementsAlreadyAdded:(NSMutableSet<NSString *> *)alreadyAdded`, we recurse through the child. In the case when the view was `CKRootComponent` it created a `SKComponentLayoutWrapper` in the call to `[descriptor childForNode: node atIndex: i];`. This wrapper's descriptor used to return the very same view from which it was created when it's children were asked. So this led to an infinite loop.

Reviewed By: kfirapps

Differential Revision: D15266478

fbshipit-source-id: 8035209746b7cb4b8773e2fcbdd4c0a148191304
2019-05-10 09:53:18 -07:00
Pascal Hartig
2885f87189 Update copyright headers (#433)
Summary:
Style is modified, so I think it's okay to add
our header there too.
Pull Request resolved: https://github.com/facebook/flipper/pull/433

Differential Revision: D15213091

Pulled By: passy

fbshipit-source-id: c02b67b022f12fdb3e0da39a308d33b073dcb9d3
2019-05-04 11:16:23 -07:00
Pritesh Nandgaonkar
b1be6400b8 Added custom swift plugin
Summary: Our very own SeaMammal plugin for iOS written in swift

Reviewed By: passy

Differential Revision: D15199381

fbshipit-source-id: 10b085c314328ff52ae3f5feef51f70d0ce12f1b
2019-05-03 09:53:53 -07:00
Pascal Hartig
65c0dd1a86 Add missing swift/objc headers
Summary: Per title

Reviewed By: danielbuechele

Differential Revision: D15199200

fbshipit-source-id: a4251311d7fd2d22d39ba89ba0052514abbc3e2c
2019-05-03 09:13:17 -07:00
Pritesh Nandgaonkar
c55bebd1be Tutorial app with sea mammals
Summary: Tutorial app for iOS. It follows the same theme as its android counterpart.

Reviewed By: passy

Differential Revision: D15184515

fbshipit-source-id: bb473c0fa863bb325bb33f8e42c8d6b3d9c640ff
2019-05-03 05:18:47 -07:00
Pascal Hartig
bbee7a3357 Update iOS license headers (and more)
Summary: Add the affiliates bit that the linter is checking for.

Reviewed By: jknoxville

Differential Revision: D15164826

fbshipit-source-id: 500ffe89ec0c2fd3acfbc374408d16a337cecfa4
2019-05-02 03:28:07 -07:00
Pritesh Nandgaonkar
5b26ce954f Upated the installation instruction for iOS
Summary: Updated the installation instruction for iOS. Also updated the sample app's podfile

Reviewed By: passy

Differential Revision: D15165222

fbshipit-source-id: 33fe27f687619b716b73cea5c3a3a898ea6edc79
2019-05-01 07:32:03 -07:00
Pritesh Nandgaonkar
34b0cad824 Moved Flipper podspec outside (#423)
Summary:
Removed the symlink and moved `Flipper.podspec` and `FlipperKit.podspec` to the root directory. Also published `Flipper.podspec` and `FlipperKit.podspec`on cocoapods

http://cocoapods.org/pods/Flipper
http://cocoapods.org/pods/FlipperKit

Also removed the stub podspec files.

Released Flipper and FlipperKit on Cocoapods
Pull Request resolved: https://github.com/facebook/flipper/pull/423

Reviewed By: passy

Differential Revision: D15146621

Pulled By: priteshrnandgaonkar

fbshipit-source-id: 86ee16773a81b0896548169cba49810250122ec1
2019-05-01 06:06:27 -07:00
Kfir Schindelhaim
b78dbb75b2 Use the tree node idenitifer as the component identifier
Summary: Now that we always build the component tree (CKTreeNode) in debug, we can just use the tree node identifier as the component identifier instead of creating a very long string.

Reviewed By: fabiomassimo

Differential Revision: D15046568

fbshipit-source-id: 4d83c1bee3fd7ac85ee4bd6e9f4f47812509e0c3
2019-04-26 10:15:02 -07:00
Kfir Schindelhaim
1c35b705eb Use the cached layout wrapper if it exists
Summary:
- We cache the layout wrapper, but never used it actually.
- This should make the Layout plugin faster.

Reviewed By: fabiomassimo

Differential Revision: D15046463

fbshipit-source-id: b61f28d9a981e782b76abe78037d37665f7d8ba3
2019-04-26 10:15:02 -07:00
Kfir Schindelhaim
c764322c1a Layout plugin integration for reused nodes information
Summary:
- Expose the reused component counter into the layout plugin

https://pxl.cl/wVJf

Reviewed By: priteshrnandgaonkar

Differential Revision: D14952906

fbshipit-source-id: 784a02dbf44d80d95fdd3a804f58ecd0f51a3e1f
2019-04-26 10:15:02 -07:00
Pritesh Nandgaonkar
4049720759 Update CK and Yoga dependencies
Summary:
Updates CK and Yoga to latest dependencies.
Also removed the code from the post_install script which changed the min ios version of the yoga dependency, its no longer required.

Reviewed By: kfirapps

Differential Revision: D15098129

fbshipit-source-id: d00938db1df59d74253ae412a4bd835a0aa286b7
2019-04-26 07:11:56 -07:00
Scott Hoyt
7bbb8c10c4 Extend FKUserDefaultsPlugin to support app suite user defaults.
Summary:
`FKUserDefaultsPlugin` is initialized with an `appSuiteName` but doesn't use this to monitor the app suite user defaults. This adds that capability.

In Flipper, "App Suite UserDefaults" defaults will show up in the drop down selector for user defaults.

Reviewed By: priteshrnandgaonkar

Differential Revision: D14922399

fbshipit-source-id: 3876976ccd0968fdec35f7605107202e1f9d7cee
2019-04-24 10:22:27 -07:00
Pascal Hartig
6fa40aad77 Flipper Release: v0.20.0
Summary:
== Highlights

* Improved UI when exporting Flipper data. (45999a5292)

== Fixes

* The Shared Preference Plugin on Android will search for all shared pref files instead of only the package name by default. (825ecb8e23)
* When restarting Flipper and the previously selected plugin no longer exists, the UI would crash. (c4a8e73543)

Commit log: https://github.com/facebook/flipper/compare/v0.19.0...v0.20.0

Reviewed By: danielbuechele

Differential Revision: D14951753

fbshipit-source-id: dbafc2d41cd25b2ede218b3fe3e99745226939a9
2019-04-17 10:37:33 -07:00
Kevin Lin
7f20c34e34 Remove unneeded TODO
Summary: Remove unneeded TODO.

Reviewed By: priteshrnandgaonkar

Differential Revision: D14882889

fbshipit-source-id: cbcb26bb90a315b5c36f4573bfcb416b8a0b4c46
2019-04-11 03:50:49 -07:00
Pritesh Nandgaonkar
2dacea8541 Published Flipper-PeerTalk dependency on Cocoapods (#395)
Summary:
I have published the new tag of Peertalk on my [fork](https://github.com/priteshrnandgaonkar/peertalk) and published a [Flipper-PeerTalk](80e4cd9a05/Specs/d/6/6/Flipper-PeerTalk/0.0.4/Flipper-PeerTalk.podspec.json) pod on cocoapods. There was no reply on the [request](https://github.com/rsms/peertalk/issues/48) to publish the new version of the peertalk on their repository and it was blocking us to publish Flipper and FlipperKit pods to Cocoapods. For more context follow the issue #132. With this PR we would have all our dependencies on cocoapods and thus we can now publish Flipper and FlipperKit pods on the cocoapods master repository.

I have also added the Flipper-PeerTalk podspec file for future updates.
Pull Request resolved: https://github.com/facebook/flipper/pull/395

Reviewed By: passy

Differential Revision: D14642440

Pulled By: priteshrnandgaonkar

fbshipit-source-id: 7847c19cddea358ffb62d2c6f16fc06d1afa1ea1
2019-04-01 08:49:16 -07:00
Pritesh Nandgaonkar
8a19a859f2 Update Componentkit, Yoga, YogaKit
Summary: Fixed the broken master for flipper iOS  oss

Reviewed By: jknoxville

Differential Revision: D14686908

fbshipit-source-id: abdcacf279449f83c98d1635c65ff8759ee17926
2019-04-01 06:59:59 -07:00
Pritesh Nandgaonkar
d044ae991f Fix the broken iOS OSS job
Summary:
Fixes the iOS OSS job which was failing. The root cause of the problem is as follows:

- RSocket was referring the master branch of rsocket/rsocket-cpp, fixed it by forking it and making its own release, unfortunately they don't make a release.
- Folly referred to the January's release. The current master branch of RSocket doesn't build with the latest release of the Folly, [this commit](b51dc569eb) is responsible for the breakage. Thus I made a Rsocket release, right before this [commit](b51dc569eb), so that it builds.Although, the current master branch of Folly builds with the current master branch of rsocket, but we will have to wait on Folly team to make a release. Once they do that I will update bit RSocket and Folly releases.

Reviewed By: jknoxville

Differential Revision: D14668686

fbshipit-source-id: 6b0362632c26355a69a3f33a031b71c88e7dd45b
2019-03-29 05:31:16 -07:00
Andrey Mishanin
a0e0b434ee Removed UIView (CKComponentAttachController)
Summary: Remove ObjC categories so we can strip dead code

Reviewed By: kfirapps

Differential Revision: D14665041

fbshipit-source-id: 243dee61a5b7cfd854191bfb5fa3a570b4ac1a4b
2019-03-28 09:23:41 -07:00
Pascal Hartig
9ff6cfa9a4 Flipper Release: v0.19.0
Summary:
== Highlights

- **Layout 2.0**: We have a new layout inspector that was rewritten from the ground to address all sorts of small bugs that like nodes not expanding that should all be gone now.
- **New Crash Reporter**: Flipper will now detect crashes on your device and give you easy access to them through a device plugin that you can find next to logs. Learn more at https://fbflipper.com/docs/crash-reporter-plugin.html.
- **Import/Export**: You can now import and export Flipper sessions as data to share them with others. Learn more at https://fbflipper.com/docs/share-flipper-data.html.

== Fixes

- Improved error reporting for what was previously summarised under "RecurringError". (bf9be74ad2)
- Fixed an issue where the color picker could get cut off. (f9ec0cd326) (https://github.com/facebook/flipper/issues/396)

Full list: https://github.com/facebook/flipper/compare/v0.18.0...v0.19.0

Reviewed By: priteshrnandgaonkar

Differential Revision: D14665281

fbshipit-source-id: 78ed042d38642356180f25455d0d17a03ed59c6b
2019-03-28 08:29:51 -07:00
Kevin Lin
deef14d3a2 Rename CKComponentDataSourceAttachController to CKComponentAttachController
Summary:
`CKComponentDataSourceAttachContrlller` doesn't have to be tied with datasource. It's totally legit to use it in hosting view as well.
Renaming it to `CKComponentAttachController` and move it to `Core` folder.

Reviewed By: priteshrnandgaonkar

Differential Revision: D14526150

fbshipit-source-id: f48a8d27a3bfa5170e22a397fe1b32e806bc3c55
2019-03-20 06:09:22 -07:00
Pascal Hartig
c7633cb585 Flipper Release: v0.18.0
Summary:
= Highlights

This is a bit of a boring release, to be frank. Most of the stuff happened behind the scenes, but a lot of preparation for interesting stuff happened behind the scenes, so stay tuned!

= Fixes

- Upgraded to Electron 4.0.8 (e0127b8438)
- Fixes to node expansion in the layout inspector.
- Connectivity improvements.

See https://github.com/facebook/flipper/compare/v0.17.1...v0.18.0 for reference.

Reviewed By: jknoxville

Differential Revision: D14477605

fbshipit-source-id: 0d927ba08fa5fab9d95c76ec763f5b9dd5bc104d
2019-03-15 08:51:09 -07:00
Pascal Hartig
d025bbd0bf Flipper Release: v0.17.1
Summary:
== Bugfix Release ==

Fixes #394 in which using the network inspector can cause the plugin view to crash. Also fixes an issue where native background plugins can fail to connect (d720b20870).

Reviewed By: danielbuechele

Differential Revision: D14384823

fbshipit-source-id: 7cee49d22ec2ed8f076cf3aeb980d4ba3a273a3f
2019-03-08 04:55:40 -08:00
Pritesh Nandgaonkar
88f976b09b Flipper Release: v0.17.0
Summary:
- The Android library now uses AndroidX instead of the support-library.
- Folly and RSocket dependencies uploaded to cocoapods (f8bd473828).

- Improved Unicode support in the Network Inspector plugin (f4b2ce9a2b).
- Fixed MacOS release creation.
- Several UI fixes regarding in-app search and the toolbar.

Reviewed By: passy

Differential Revision: D14269567

fbshipit-source-id: 2d2f965316bd1ddfb375a2db48fb715095693c43
2019-03-05 06:28:26 -08:00
Pritesh Nandgaonkar
af317eed2b Export and import all the nodes
Summary:
This diff does the following

- Support to export the entire view hierarchy for iOS
- Android is not supported yet
- This diff adds a call `getAllNodes` to the client side of iOS, which returns the entire view hierarchy
- Currently the search doesn't work on the imported layout plugin data. Also the imported layout plugin data doesn't expand the way it does when component is mounted, reason being the client passed to the plugin is not functional for the archived case

I will work on fixing the last points in the next diffs stacked on the current one.

For Android:
- Currently the export function will export whatever is currently displayed on the Flipper app, not the entire view hierarchy

Support for Android will also come up in later diffs.

Reviewed By: jknoxville

Differential Revision: D14209157

fbshipit-source-id: 3ad3e39edfd994913dc19cc239bfbbe011a9757c
2019-02-28 09:40:50 -08:00