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

fix(router): correct modifier key #25504

Closed
wants to merge 1 commit into from
Closed

fix(router): correct modifier key #25504

wants to merge 1 commit into from

Conversation

yuheiy
Copy link
Contributor

@yuheiy yuheiy commented Aug 15, 2018

On most browsers alt key will affect the behavior when clicking the link.

PR Checklist

Please check if your PR fulfills the following requirements:

PR Type

What kind of change does this PR introduce?

[x] Bugfix
[ ] Feature
[ ] Code style update (formatting, local variables)
[ ] Refactoring (no functional changes, no api changes)
[ ] Build related changes
[ ] CI related changes
[ ] Documentation content changes
[ ] angular.io application / infrastructure changes
[ ] Other... Please describe:

What is the current behavior?

router link ignores the alt key.

What is the new behavior?

Respect the behaviors of browsers.

Does this PR introduce a breaking change?

[ ] Yes
[x] No

@ngbot ngbot bot added this to the needsTriage milestone Jan 24, 2019
@atscott
Copy link
Contributor

atscott commented Aug 6, 2020

This seems accurate based on my own testing and relatively low risk. Can you update the commit message to be a little more descriptive? Could you also provide some more justification and research into what actually does usually happen when links are clicked when holding the alt key on several different browsers?

@atscott atscott added the action: cleanup The PR is in need of cleanup, either due to needing a rebase or in response to comments from reviews label Aug 6, 2020
@pullapprove pullapprove bot requested a review from atscott August 6, 2020 20:38
Copy link
Contributor

@atscott atscott left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Setting review to "request changes" per #25504 (comment)

…links, prioritize browser’s default behavior

In most browsers, clicking links with the Alt key has a special behavior, for example, Chrome downloads the target resource. As with other modifier keys, the router should stop the original navigation to avoid preventing the browser’s default behavior.
@yuheiy yuheiy closed this Aug 7, 2020
@yuheiy
Copy link
Contributor Author

yuheiy commented Aug 7, 2020

@atscott I’m really sorry, but I made a git mistake and lost your commit. Instead I worked from HEAD of master branch and created a new pull request. #38375

@angular-automatic-lock-bot
Copy link

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

@angular-automatic-lock-bot angular-automatic-lock-bot bot locked and limited conversation to collaborators Sep 7, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
action: cleanup The PR is in need of cleanup, either due to needing a rebase or in response to comments from reviews area: router cla: yes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants