facebook / facebook/facebook-ios-sdk

FBShareLinkContent quote doesn't work on webView

Open
#2,147 0 comments 0 reactions 0 assignees View on GitHub
bug needs-triage
Dominant language
Swift
Stars
8.1k
Forks
3.7k
PR merge metrics
No merged PRs in 30d

Description

### Checklist before submitting a bug report

- [x] I've updated to the latest released version of the SDK
- [X] I've searched for existing [GitHub issues](https://github.com/facebook/facebook-ios-sdk/issues)
- [X] I've looked for existing answers on [Stack Overflow](https://facebook.stackoverflow.com), the [Facebook Developer Community Forum](https://developers.facebook.com/community/) and the [Facebook Developers Group](https://www.facebook.com/groups/fbdevelopers)
- [X] I've read the [Code of Conduct](https://github.com/facebook/facebook-ios-sdk/blob/main/CODE_OF_CONDUCT.md)
- [X] This issue is not security related and can safely be disclosed publicly on GitHub

### Xcode version

14.0

### Facebook iOS SDK version

15.0.0 / 15.1.0

### Dependency Manager

Building from Source

### SDK Framework

Share

### Goals

Quote from FBSDKShareLinkContent to work on webView when FBSDKShareDialog is called. (Facebook app isn't installed so webView is called)

### Expected results

Quote to be displayed on webView just like how it is displayed on the app.
(Image is how it looks like when shared through app - Facebook App is installed)

![IMG_0163](https://user-images.githubusercontent.com/118438875/202429410-ffa5f16c-a8c5-4c40-b6a9-0ac03eae148a.PNG)

### Actual results

Quote didn't displayed on webView
(Image is how it looks like when shared through webView - Facebook App is not installed)

![IMG_0162](https://user-images.githubusercontent.com/118438875/202429291-ce6ab348-e20f-48ae-840f-0870766fe891.PNG)

### Steps to reproduce

1. Delete Facebook App from device
2. Share to facebook with quote

### Code samples & details

```swift
FBSDKShareLinkContent *content = [[FBSDKShareLinkContent alloc] init];
content.contentURL = [NSURL URLWithString:@"https://www.google.com"];
content.quote = @"Title\nContent";

[FBSDKShareDialog showFromViewController:presentingViewController
withContent:content
delegate:nil];
```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.