iOS - As a Developer, I want to use Segment's trackLink() functionality in mobile webviews

Description

When navigationAction.navigationType != .linkActivated , this line of code returns false without evaluating the rest of the boolean statement. But when navigationAction.navigationType == .linkActivated it does evaluate the rest of the statement and thus makes a call to delegate?.webView(webView, shouldLoad: request). This calls DiscoveryHelper.navigate(to: url, from: self, bottomBar: bottomBar), which actually presents the course detail.

When trackLink() is use in the webpage, it makes navigationAction.navigationType = .other. This breaks the navigation.

Draft PR with a fix is up here :

We are currently attempting to consistently reproduce the issue in a sandbox environment, and then validate the fix. We also need to evaluate whether this fix might cause other issues.

Epic Link

None

Activity

Show:
Colin Brash
February 25, 2021, 1:24 PM

Sandbox is now working as expected, I’ll put up a PR a little later today.

Colin Brash
February 25, 2021, 12:14 PM

There have been several issues deploying this sandbox correctly. As of today there is currently a bug affecting the course card links (multiple ? characters are present due to a bug in how additional query parameters are being added, so the query parameters are not able to be correctly parsed).

A new sandbox with the bug fix is expected to be deployed later today.

Colin Brash
February 23, 2021, 12:09 PM

Priority

Unset

Assignee

Colin Brash

Fix versions

Sprint

None

Labels

None

Story Points

1

Reporter

Colin Brash