From a369bc9e39dce568d9cb6bd286a7ae30356673c7 Mon Sep 17 00:00:00 2001
From: Anssi Kostiainen
The following concepts, terms, and interfaces are defined in
- [[!HTML5]], [[!ECMASCRIPT]], [[!WEBIDL]], and [[!SECURE-CONTEXTS]]:
+ [[!HTML]], [[!HTML5]], [[!ECMASCRIPT]], [[!WEBIDL]], and [[!SECURE-CONTEXTS]]:
- The following concepts, terms, and interfaces are defined in - [[!HTML]], [[!HTML5]], [[!ECMASCRIPT]], [[!WEBIDL]], and [[!SECURE-CONTEXTS]]: + The following concepts, terms, and interfaces are defined in [[!HTML]], + [[!HTML5]], [[!ECMASCRIPT]], [[!WEBIDL]], and [[!SECURE-CONTEXTS]]:
null
, return this Navigator object's battery
From e9f54425110d88b4603a312f7f6f01ed089cec10 Mon Sep 17 00:00:00 2001
From: Anssi Kostiainen The following concepts, terms, and interfaces are defined in [[!HTML]], - [[!HTML5]], [[!ECMASCRIPT]], [[!WEBIDL]], and [[!SECURE-CONTEXTS]]: + [[!HTML5]], [[!ECMASCRIPT]], [[!WEBIDL]], [[!SECURE-CONTEXTS]], and + [[!FEATURE-POLICY]]:
+ The Battery Status API is a policy-controlled feature, as
+ defined by Feature Policy [[!FEATURE-POLICY]]. The feature name
+ for the Battery Status API is "battery
". The default
+ allowlist for the Battery Status API is ["self"]
. When
+ disabled in a document, the getBattery()
method
+ MUST return a promise which rejects with a
+ "SecurityError" DOMException.
+
Navigator
+ "https://html.spec.whatwg.org/#navigator">Navigator
- EventHandler
+ "https://html.spec.whatwg.org/#eventhandler">EventHandler
Document
Document
's browsing context's
+ active document's origin is not same origin-domain
+ with the origin of the current settings object of this
+ Navigator object, then reject this Navigator object's
+ battery promise with a "SecurityError"
+ DOMException, return this Navigator object's battery
+ promise and abort these steps.
null
, return this Navigator object's battery
@@ -523,9 +529,9 @@ battery
". The default
- allowlist for the Battery Status API is ["self"]
. When
- disabled in a document, the getBattery()
method
- MUST return a promise which rejects with a
+ allowlist« "self" »
.
+ When disabled in a document, the getBattery()
+ method MUST return a promise which rejects with a
"SecurityError" DOMException.
Document
's browsing context's
- active document's origin is not same origin-domain
- with the origin of the current settings object of this
- Navigator object, then reject this Navigator object's
- battery promise with a "SecurityError"
- DOMException, return this Navigator object's battery
- promise and abort these steps.
+ associated Document
is not allowed to use
+ the battery
feature, then reject this Navigator
+ object's battery promise with a "SecurityError"
+ DOMException, return this Navigator object's battery
+ promise and abort these steps.
+ Document
's browsing context's active
+ document's origin is not same origin-domain with
+ the origin of the current settings object of this
+ Navigator object.
+ null
, return this Navigator object's battery
@@ -526,13 +535,11 @@
- The Battery Status API is a policy-controlled feature, as
- defined by Feature Policy [[!FEATURE-POLICY]]. The feature name
- for the Battery Status API is "battery
". The default
- allowlist for the Battery Status API is « "self" »
.
- When disabled in a document, the getBattery()
- method MUST return a promise which rejects with a
- "SecurityError" DOMException.
+ The Battery Status API is a policy-controlled feature identified
+ by the string "battery
". It's default allowlist is
+ 'self'
. When disabled in a document, the
+ getBattery()
method MUST return a promise
+ which rejects with a "SecurityError" DOMException.
Document
SecurityError
NotAllowedError
+ DOMException
@@ -303,7 +307,7 @@ Document
is not allowed to use
the battery
feature, then reject this Navigator
- object's battery promise with a "SecurityError"
+ object's battery promise with a "NotAllowedError"
DOMException, return this Navigator object's battery
promise and abort these steps.
EventTarget
+
EventHandler
- EventTarget
-