Conversation
ditman
left a comment
There was a problem hiding this comment.
This looks good to me; I'd move the link.dart file under src so users can't import it; that way I wouldn't worry much about making things _Private.
My only real concern would be to auto-applying a 'rel' attribute, or letting users set it alongside the 'target', so window.opener does not become an issue.
Everything else is nitpicking, and since most of this file is private anyways, it seems it can be refactored later, if needed/wanted.
packages/url_launcher/url_launcher_web/lib/url_launcher_web.dart
Outdated
Show resolved
Hide resolved
packages/url_launcher/url_launcher_web/lib/url_launcher_web.dart
Outdated
Show resolved
Hide resolved
ditman
left a comment
There was a problem hiding this comment.
Ship it, let's give this a shot!
| group('link', () { | ||
| testWidgets('creates anchor with correct attributes', |
There was a problem hiding this comment.
Thanks for the test! In a further PR, I think this should be separated to its own test file: link_integration.dart or similar.
There was a problem hiding this comment.
Yeah I want to also add more tests around hit testing but I couldn't make it work so it's gonna take some time. I wanted to land this ASAP to unbreak the url_launcher plugin.
|
The red Merging. |
|
Thanks for publishing this, @mdebbar! |
|
So what version does this work in, is it working now? |
|
@neiljaywarner This should work all the way up to flutter channel beta? |
|
@ditman will it get documentation on flutter.dev or similar "soon"? Also I might have had an issue where I didn't switch to most recent version bc nullsafety issue |
|
@neiljaywarner there is documentation for the widget, here: https://pub.dev/documentation/url_launcher/latest/link/Link-class.html (The widget comes in the url_launcher plugin) |
|
Unfortunately, the CMD+Left Mouse Click still not working to open the link in the new tab as users are used in the "classic" web app. |
Description
The design has been discussed in:
Issues:
Fixes flutter/flutter#68545