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

Activation delegation through post messages #4369

Closed
wants to merge 4 commits into from

Conversation

mustaqahmed
Copy link
Contributor

@mustaqahmed mustaqahmed commented Feb 15, 2019

Proposed spec changes for activation delegation through postMessage() calls.

This PR is based on UAv2 changes in #3851.

Fixes #4364


💥 Error: Wattsi server error 💥

PR Preview failed to build. (Last tried on Jan 15, 2021, 7:59 AM UTC).

More

PR Preview relies on a number of web services to run. There seems to be an issue with the following one:

🚨 Wattsi Server - Wattsi Server is the web service used to build the WHATWG HTML spec.

🔗 Related URL

<html>
<head><title>504 Gateway Time-out</title></head>
<body bgcolor="white">
<center><h1>504 Gateway Time-out</h1></center>
<hr><center>nginx/1.10.3</center>
</body>
</html>

If you don't have enough information above to solve the error by yourself (or to understand to which web service the error is related to, if any), please file an issue.

Replaced most of Section 6.3 with the new user activation model, preserved only
a part (events triggering user activation) into a new Section 6.4 which needs to
be addressed through a separate issue.
mustaqahmed added a commit to mustaqahmed/html-build that referenced this pull request Feb 21, 2019
mustaqahmed added a commit to mustaqahmed/web that referenced this pull request Feb 21, 2019
mustaqahmed added a commit to mustaqahmed/web that referenced this pull request Feb 21, 2019
mustaqahmed added a commit to mustaqahmed/web that referenced this pull request Feb 21, 2019
@mounirlamouri
Copy link
Member

Why not having something directly on the Window like transferUserActivation() or whatever name makes sense here? If we go forward with the model of non-scoped user activations, it doesn't seem required to have them associated with postMessage() and it would allow for a more flexible API.

@annevk
Copy link
Member

annevk commented Mar 7, 2019

@mounirlamouri does it need to work cross-origin? Is this something we might want to use eventually to grant capabilities in workers?

@mustaqahmed
Copy link
Contributor Author

@annevk:

  • Yes, we need cross-origin support for sure. The Chrome use case we are planning to fix through this API is for activating a cross-origin child frame.
  • The workers question is tricky: any of the two APIs we are discussing here (window.postMessage() or window.transferUserActivation()) could be extended to include workers in future. However, while working on UAv2 I have never found a convincing example where a worker should expect user activation. This is debatable though, perhaps we can discuss it through a separate issue.

@annevk
Copy link
Member

annevk commented Mar 7, 2019

In that case I'm strongly opposed to a new method on Window that needs to be reachable across origins through WindowProxy. postMessage() seems vastly preferable.

@mustaqahmed
Copy link
Contributor Author

Motivated by the feedback from TAG and a new use-case we want to support, we have switched our focus to an alternate proposal: Capability Delegation.

@mustaqahmed mustaqahmed deleted the activation-delegation-pr branch April 21, 2021 21:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

User Activation: ability to transfer activation to another frame
3 participants