Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[url_launcher]: (Web) When click on Link widget without calling followLink function still takes browser to that link #8588

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions packages/url_launcher/url_launcher_web/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
## 2.4.1

* Fixes when click on `Link` widget without calling `followLink` function still takes browser to that link.

## 2.4.0

* Enhances handling of out-of-order events.
Expand Down
1 change: 1 addition & 0 deletions packages/url_launcher/url_launcher_web/lib/src/link.dart
Original file line number Diff line number Diff line change
Expand Up @@ -499,6 +499,7 @@ class LinkViewController extends PlatformViewController {

_element.setAttribute('aria-hidden', 'true');
_element.setAttribute('tabIndex', '-1');
_element.setAttribute('onclick', 'event.preventDefault();');

final Map<String, dynamic> args = <String, dynamic>{
'id': viewId,
Expand Down
2 changes: 1 addition & 1 deletion packages/url_launcher/url_launcher_web/pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ name: url_launcher_web
description: Web platform implementation of url_launcher
repository: https://github.com/flutter/packages/tree/main/packages/url_launcher/url_launcher_web
issue_tracker: https://github.com/flutter/flutter/issues?q=is%3Aissue+is%3Aopen+label%3A%22p%3A+url_launcher%22
version: 2.4.0
version: 2.4.1

environment:
sdk: ^3.6.0
Expand Down