From e34e1d4fb1bd4523c59772ca9947674efc7845e8 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Marcos=20C=C3=A1ceres?=
Date: Fri, 13 Dec 2019 11:53:09 +1100
Subject: [PATCH 1/3] Editorial: use new HTML activation model
This is refactor to use HTML's new activation model. The
api currently uses transient activation.
---
index.html | 7 +++----
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/index.html b/index.html
index 83ce767..d142847 100644
--- a/index.html
+++ b/index.html
@@ -170,10 +170,9 @@
-
If the [=relevant global object=] of [=this=] does not have
- [=transient activation=], or a file type is being blocked due to
- security considerations, return a promise rejected with with
- a {{"NotAllowedError"}} {{DOMException}}.
+ If a file type is being blocked due to security considerations,
+ return a promise rejected with with a {{"NotAllowedError"}}
+ {{DOMException}}.
Set {{[[sharePromise]]}} to be a new promise.
From 3ecdbf019f2d7c747a34ca18adddb124d761aac1 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Marcos=20C=C3=A1ceres?=
Date: Fri, 13 Dec 2019 15:03:50 +1100
Subject: [PATCH 2/3] BREAKING CHANGE: make share() consume user activation
---
index.html | 13 +++++++++++++
1 file changed, 13 insertions(+)
diff --git a/index.html b/index.html
index d142847..a48b919 100644
--- a/index.html
+++ b/index.html
@@ -137,6 +137,14 @@
|data:ShareData|, run the following steps:
+ - Let |window| be [=relevant global object=] of [=this=].
+
+ - If |window| does not have [=transient activation=], return [=a
+ promise rejected with=] with a {{"NotAllowedError"}}
+ {{DOMException}}.
+
+ - [=Consume user activation=] of |window|.
+
- If {{[[sharePromise]]}} is not `null`, return a promise
rejected with {{InvalidStateError}}.
@@ -435,6 +443,11 @@
guard against this, but implementors will want to be aware that it is a
possibility.
+
- To prevent multiple share UIs from being displayed simultaneously,
+ as well as to mitigate some other behavior that could confuse end
+ users, calling {{Navigator/share()}} [=consume user activation|consumes
+ the user activation=] of the relevant {{Window}}.
+