Skip to content

Commit

Permalink
Replace {{event)}} with domxref (batch #4) (#14584)
Browse files Browse the repository at this point in the history
  • Loading branch information
teoli2003 authored Apr 2, 2022
1 parent fba577c commit 593f9ac
Show file tree
Hide file tree
Showing 29 changed files with 50 additions and 50 deletions.
2 changes: 1 addition & 1 deletion files/en-us/mozilla/firefox/releases/31/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ New ECMAScript 2015 features implemented:
- The {{domxref("CanvasRenderingContext2D.isPointInPath()")}}, {{domxref("CanvasRenderingContext2D.isPointInStroke()")}}, {{domxref("CanvasRenderingContext2D.clip()")}}, {{domxref("CanvasRenderingContext2D.fill()")}} and {{domxref("CanvasRenderingContext2D.stroke()")}} methods have been updated to optionally accept a {{domxref("Path2D")}} object.
- Implemented {{domxref("HTMLMediaElement.fastSeek()")}}.
- The `Connection` interface has been renamed to {{domxref("NetworkInformation")}} and has been modified to match the new specification ({{bug(960426)}}).
- The {{domxref("Navigator.sendBeacon()")}} has been implemented; this allows asynchronous transmission of analytics or other data in a manner that doesn't rely on the transmitting page remaining loaded, so that it can be used in an {{event("unload")}} or {{event("beforeunload")}} handler.
- The {{domxref("Navigator.sendBeacon()")}} has been implemented; this allows asynchronous transmission of analytics or other data in a manner that doesn't rely on the transmitting page remaining loaded, so that it can be used in an {{event("unload")}} or {{domxref("Window.beforeunload_event", "beforeunload")}} handler.

### MathML

Expand Down
2 changes: 1 addition & 1 deletion files/en-us/mozilla/firefox/releases/44/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ Highlights:
- To fight unwanted pop-ups, prompts requested in {{domxref("WindowEventHandlers/onbeforeunload", "Window.onbeforeunload")}} of pages that have not been interacted with are no more displayed ({{bug(636905)}}).
- The deprecated method {{domxref("MessageEvent.initMessageEvent()")}} has been reimplemented for backward compatibility ({{bug(949376)}}).
- The obsolete property `DocumentType.internalSubset` has been removed ({{bug(801545)}}).
- For compatibility with existing sites, the properties {{domxref("Window.orientation")}} and {{domxref("Window.onorientationchange")}}, as well as the {{event("orientationchange")}} event have been implemented ({{bug(920734)}}).
- For compatibility with existing sites, the properties {{domxref("Window.orientation")}} and {{domxref("Window.onorientationchange")}}, as well as the {{domxref("Window.orientationchange_event", "orientationchange")}} event have been implemented ({{bug(920734)}}).
- An {{HTMLElement("iframe")}} with explicit fullscreen request should not exit fullscreen implicitly ({{bug(1187801)}}).
- The events {{event("mouseover")}}, {{event("mouseout")}}, {{event("mouseenter")}}, {{event("mouseleave")}}, {{event("pointermove")}}, {{event("pointerover")}}, {{event("pointerout")}}, {{event("pointerenter")}} and {{event("pointerleave")}} are now triggered for disabled form elements ({{bug(218093)}}).
- The method {{domxref("Element.webkitMatchesSelector()")}} has been added ({{bug(1216193)}}) to improve interoperability.
Expand Down
2 changes: 1 addition & 1 deletion files/en-us/mozilla/firefox/releases/62/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ _No changes._
#### Removals
- The {{event("userproximity")}} and {{event("deviceproximity")}} events (see also {{domxref("UserProximityEvent")}} and {{domxref("DeviceProximityEvent")}}) have been disabled by default behind the `device.sensors.proximity.enabled` preference ({{bug(1462308)}}).
- The `userproximity` and `deviceproximity` events, as well as the `UserProximityEvent` and `DeviceProximityEvent`interfaces, have been disabled by default behind the `device.sensors.proximity.enabled` preference ({{bug(1462308)}}).
- The `devicelight` event of type `DeviceLightEvent` has been disabled by default behind the `device.sensors.ambientLight.enabled` preference ({{bug(1462308)}}).
- The {{event("DOMSubtreeModified")}} and {{event("DOMAttrModified")}} [mutation events](/en-US/docs/Web/API/MutationEvent) are no longer thrown when the {{htmlattrxref("style")}} attribute is changed via the CSSOM ({{bug(1460295)}}.
- Support for {{domxref("CSSStyleDeclaration.getPropertyCSSValue()")}} has been removed ({{bug(1408301)}}).
Expand Down
2 changes: 1 addition & 1 deletion files/en-us/mozilla/firefox/releases/91/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ No changes
It also provides events that allow changes to the viewport to be monitored. ({{bug(1551302)}}).
- The [Gamepad API](/en-US/docs/Web/API/Gamepad_API) is now protected by {{httpheader('Feature-Policy/gamepad','Feature-Policy: gamepad')}}.
If disallowed by the [feature policy](/en-US/docs/Web/HTTP/Feature_Policy), calls to {{domxref('Navigator.getGamepads()')}} will throw a `SecurityError` {{domxref('DOMException')}},
and the {{event("gamepadconnected")}} and {{event("gamepaddisconnected")}} events will not fire.
and the {{domxref("Window.gamepadconnected_event", "gamepadconnected")}} and {{domxref("Window.gamepaddisconnected_event", "gamepaddisconnected")}} events will not fire.
The default `allowlist` is `*`; this default will be updated to `self` in a future release, in order to match the specification. ({{bug(1704005)}}).
- `Window.clientInformation` has been added as an alias for {{domxref("Window.navigator")}}, in order to match recent specification updates and improve compatibility with other major browsers ({{bug(1717072)}}).

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ The Screen Orientation API is made to prevent or handle such a change.

### Listening orientation change

The {{event("orientationchange")}} event is triggered each time the device change the orientation of the screen and the orientation itself can be read with the {{domxref("Screen.orientation")}} property.
The {{domxref("Window.orientationchange_event", "orientationchange")}} event is triggered each time the device change the orientation of the screen and the orientation itself can be read with the {{domxref("Screen.orientation")}} property.

```js
screen.addEventListener("orientationchange", function () {
Expand All @@ -161,9 +161,9 @@ The {{domxref("Screen.lockOrientation()")}} accepts a string (or series of strin
screen.lockOrientation('landscape');
```

> **Note:** A screen lock is web application dependent. If application A is locked to `landscape` and application B is locked to `portrait`, switching from application A to B or B to A will not fire an {{event("orientationchange")}} event because both applications will keep the orientation they had.
> **Note:** A screen lock is web application dependent. If application A is locked to `landscape` and application B is locked to `portrait`, switching from application A to B or B to A will not fire an {{domxref("Window.orientationchange_event", "orientationchange")}} event because both applications will keep the orientation they had.
>
> However, locking the orientation can fire an {{event("orientationchange")}} event if the orientation had to be changed to satisfy the lock requirements.
> However, locking the orientation can fire an {{domxref("Window.orientationchange_event", "orientationchange")}} event if the orientation had to be changed to satisfy the lock requirements.
## Firefox OS and Android: Orientation lock using the manifest

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,4 +38,4 @@ explained](/en-US/docs/Web/Guide/Events/Orientation_and_motion_data_explained) f
- [Orientation and motion data
explained](/en-US/docs/Web/Guide/Events/Orientation_and_motion_data_explained)
- {{DOMxRef("window.deviceorientation_event", "deviceorientation") }} event
- {{ event("deviceorientation") }}
- {{domxref("Window.deviceorientation_event", "deviceorientation")}}
2 changes: 1 addition & 1 deletion files/en-us/web/api/deviceorientationevent/alpha/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,4 +36,4 @@ A number.
- [Orientation and motion data
explained](/en-US/docs/Web/Guide/Events/Orientation_and_motion_data_explained)
- {{DOMxRef("window.deviceorientation_event", "deviceorientation") }} event
- {{ event("deviceorientation") }}
- {{domxref("Window.deviceorientation_event", "deviceorientation")}}
2 changes: 1 addition & 1 deletion files/en-us/web/api/deviceorientationevent/beta/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,4 +37,4 @@ A number.
- [Orientation and motion data
explained](/en-US/docs/Web/Guide/Events/Orientation_and_motion_data_explained)
- {{DOMxRef("window.deviceorientation_event", "deviceorientation") }} event
- {{ event("deviceorientation") }}
- {{domxref("Window.deviceorientation_event", "deviceorientation")}}
2 changes: 1 addition & 1 deletion files/en-us/web/api/deviceorientationevent/gamma/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,4 +38,4 @@ A number.
- [Orientation and motion data
explained](/en-US/docs/Web/Guide/Events/Orientation_and_motion_data_explained)
- {{DOMxRef("window.deviceorientation_event", "deviceorientation") }} event
- {{ event("deviceorientation") }}
- {{domxref("Window.deviceorientation_event", "deviceorientation")}}
4 changes: 2 additions & 2 deletions files/en-us/web/api/deviceorientationevent/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 +53,8 @@ window.addEventListener('deviceorientation', function(event) {

## See also

- {{ event("deviceorientation") }}
- {{domxref("Window.deviceorientation_event", "deviceorientation")}}
- {{ domxref("DeviceMotionEvent") }}
- {{ event("devicemotion") }}
- {{domxref("Window.devicemotion_event", "devicemotion")}}
- [Detecting device orientation](/en-US/docs/Web/API/Detecting_device_orientation)
- [Orientation and motion data explained](/en-US/docs/Web/Guide/Events/Orientation_and_motion_data_explained)
2 changes: 1 addition & 1 deletion files/en-us/web/api/gamepad/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ browser-compat: api.Gamepad

The **`Gamepad`** interface of the [Gamepad API](/en-US/docs/Web/API/Gamepad_API) defines an individual gamepad or other controller, allowing access to information such as button presses, axis positions, and id.

A Gamepad object can be returned in one of two ways: via the `gamepad` property of the {{event("gamepadconnected")}} and {{event("gamepaddisconnected")}} events, or by grabbing any position in the array returned by the {{domxref("Navigator.getGamepads()")}} method.
A Gamepad object can be returned in one of two ways: via the `gamepad` property of the {{domxref("Window.gamepadconnected_event", "gamepadconnected")}} and {{domxref("Window.gamepaddisconnected_event", "gamepaddisconnected")}} events, or by grabbing any position in the array returned by the {{domxref("Navigator.getGamepads()")}} method.

## Properties

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ Each gamepad has a unique ID associated with it, which is available on the event

## Disconnecting a gamepad

When a gamepad is disconnected, and if a page has previously received data for that gamepad (e.g. {{ domxref("Window/gamepadconnected_event", "gamepadconnected") }}), a second event is dispatched to the focused window, {{ event("gamepaddisconnected") }}:
When a gamepad is disconnected, and if a page has previously received data for that gamepad (e.g. {{ domxref("Window/gamepadconnected_event", "gamepadconnected") }}), a second event is dispatched to the focused window, {{domxref("Window.gamepaddisconnected_event", "gamepaddisconnected")}}:

```js
window.addEventListener("gamepaddisconnected", function(e) {
Expand Down
4 changes: 2 additions & 2 deletions files/en-us/web/api/gamepadevent/gamepad/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ browser-compat: api.GamepadEvent.gamepad
The **`GamepadEvent.gamepad`** property of the
**{{domxref("GamepadEvent")}} interface** returns a {{domxref("Gamepad")}}
object, providing access to the associated gamepad data for fired
{{event("gamepadconnected")}} and {{event("gamepaddisconnected")}} events.
{{domxref("Window.gamepadconnected_event", "gamepadconnected")}} and {{domxref("Window.gamepaddisconnected_event", "gamepaddisconnected")}} events.

## Value

Expand All @@ -22,7 +22,7 @@ A {{domxref("Gamepad")}} object.
## Examples

The `gamepad` property being called on a fired
{{event("gamepadconnected")}} event.
{{domxref("Window.gamepadconnected_event", "gamepadconnected")}} event.

```js
window.addEventListener("gamepadconnected", function(e) {
Expand Down
6 changes: 3 additions & 3 deletions files/en-us/web/api/htmlbodyelement/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,11 +41,11 @@ _No specific methods; inherits methods from its parent, {{domxref("HTMLElement")
_No specific event handlers; inherits event handlers from its parent, {{domxref("HTMLElement")}} and from {{domxref("WindowEventHandlers")}}._

- {{domxref("WindowEventHandlers.onafterprint")}}
- : Is an [event handler](/en-US/docs/Web/Events/Event_handlers) representing the code to be called when the {{event("afterprint")}} event is raised.
- : Is an [event handler](/en-US/docs/Web/Events/Event_handlers) representing the code to be called when the {{domxref("Window.afterprint_event", "afterprint")}} event is raised.
- {{domxref("WindowEventHandlers.onbeforeprint")}}
- : Is an [event handler](/en-US/docs/Web/Events/Event_handlers) representing the code to be called when the {{event("beforeprint")}} event is raised.
- : Is an [event handler](/en-US/docs/Web/Events/Event_handlers) representing the code to be called when the {{domxref("Window.beforeprint_event", "beforeprint")}} event is raised.
- {{domxref("WindowEventHandlers.onbeforeunload")}}
- : Is an [event handler](/en-US/docs/Web/Events/Event_handlers) representing the code to be called when the {{event("beforeunload")}} event is raised.
- : Is an [event handler](/en-US/docs/Web/Events/Event_handlers) representing the code to be called when the {{domxref("Window.beforeunload_event", "beforeunload")}} event is raised.
- {{domxref("WindowEventHandlers.onhashchange")}}
- : Is an [event handler](/en-US/docs/Web/Events/Event_handlers) representing the code to be called when the {{event("hashchange")}} event is raised.
- {{domxref("WindowEventHandlers.onlanguagechange")}} {{experimental_inline}}
Expand Down
6 changes: 3 additions & 3 deletions files/en-us/web/api/htmlframesetelement/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,11 +34,11 @@ _No specific method; inherits methods from its parent, {{domxref("HTMLElement")}
_No specific event handler; inherits event handlers from its parent, {{domxref("HTMLElement")}} and from {{domxref("WindowEventHandlers")}}._

- {{domxref("WindowEventHandlers.onafterprint")}}
- : Is an [event handler](/en-US/docs/Web/Events/Event_handlers) representing the code to be called when the {{event("afterprint")}} event is raised.
- : Is an [event handler](/en-US/docs/Web/Events/Event_handlers) representing the code to be called when the {{domxref("Window.afterprint_event", "afterprint")}} event is raised.
- {{domxref("WindowEventHandlers.onbeforeprint")}}
- : Is an [event handler](/en-US/docs/Web/Events/Event_handlers) representing the code to be called when the {{event("beforeprint")}} event is raised.
- : Is an [event handler](/en-US/docs/Web/Events/Event_handlers) representing the code to be called when the {{domxref("Window.beforeprint_event", "beforeprint")}} event is raised.
- {{domxref("WindowEventHandlers.onbeforeunload")}}
- : Is an [event handler](/en-US/docs/Web/Events/Event_handlers) representing the code to be called when the {{event("beforeunload")}} event is raised.
- : Is an [event handler](/en-US/docs/Web/Events/Event_handlers) representing the code to be called when the {{domxref("Window.beforeunload_event", "beforeunload")}} event is raised.
- {{domxref("WindowEventHandlers.onhashchange")}}
- : Is an [event handler](/en-US/docs/Web/Events/Event_handlers) representing the code to be called when the {{event("hashchange")}} event is raised.
- {{domxref("WindowEventHandlers.onlanguagechange")}} {{experimental_inline}}
Expand Down
4 changes: 2 additions & 2 deletions files/en-us/web/api/webvr_api/using_the_webvr_api/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -451,8 +451,8 @@ You should note that we've used a conditional expression to detect whether the l
The WebVR spec features a number of events that are fired, allowing our app code to react to changes in the state of the VR display (see [Window events](/en-US/docs/Web/API/WebVR_API#window_events)). For example:

- {{event("vrdisplaypresentchange")}} — Fires when the presenting state of a VR display changes — i.e. goes from presenting to not presenting, or vice versa.
- {{event("vrdisplayconnect")}} — Fires when a compatible VR display has been connected to the computer.
- {{event("vrdisplaydisconnect")}} — Fires when a compatible VR display has been disconnected from the computer.
- {{domxref("Window.vrdisplayconnect_event", "vrdisplayconnect")}} — Fires when a compatible VR display has been connected to the computer.
- {{domxref("Window.vrdisplaydisconnect_event", "vrdisplaydisconnect")}} — Fires when a compatible VR display has been disconnected from the computer.

To demonstrate how they work, our simple demo includes the following example:

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ The last thing to do here is set the `initialRun` variable to `false`, as the in

### Gamepad events

To finish off this section, we'll look at the gamepad-associated events. There are two we need concern ourselves with — {{event("gamepadconnected")}} and {{event("gamepaddisconnected")}} — and it is fairly obvious what they do.
To finish off this section, we'll look at the gamepad-associated events. There are two we need concern ourselves with — {{domxref("Window.gamepadconnected_event", "gamepadconnected")}} and {{domxref("Window.gamepaddisconnected_event", "gamepaddisconnected")}} — and it is fairly obvious what they do.

At the end of our example we first include the `removeGamepads()` function:

Expand Down
2 changes: 1 addition & 1 deletion files/en-us/web/api/window/devicemotion_event/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -66,5 +66,5 @@ window.addEventListener("devicemotion", handleMotionEvent, true);

## See also

- {{domxref("Window/deviceorientation_event", "deviceorientation")}}
- {{domxref("Window.deviceorientation_event_event", "deviceorientation")}}
- [DeviceOrientation Event](https://www.w3.org/TR/orientation-event/#devicemotion)
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,6 @@ var handleOrientationEvent = function(frontToBack, leftToRight, rotateDegrees) {

## See also

- [`devicemotion`](/en-US/docs/Web/API/Window/devicemotion_event)
- [`devicemotion`](/en-US/docs/Web/API/Window.devicemotion_event)
- [Detecting device orientation](/en-US/docs/Web/Events/Detecting_device_orientation)
- [Orientation and motion data explained](/en-US/docs/Web/Events/Orientation_and_motion_data_explained)
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ An {{domxref("DeviceOrientationEvent")}}. Inherits from {{domxref("Event")}}.

## See also

- {{ event("deviceorientation") }}
- {{domxref("Window.deviceorientation_event", "deviceorientation")}}
- {{ domxref("DeviceOrientationEvent") }}
- {{DOMxRef("window.deviceorientation_event", "deviceorientation") }} event
- [Detecting device orientation](/en-US/docs/Web/Events/Detecting_device_orientation)
8 changes: 4 additions & 4 deletions files/en-us/web/api/window/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -319,9 +319,9 @@ _This interface inherits event handlers from the {{domxref("EventTarget")}} inte
- {{domxref("GlobalEventHandlers.onabort")}}
- : Called when the loading of a resource has been aborted, such as by a user canceling the load while it is still in progress
- {{domxref("WindowEventHandlers.onafterprint")}}
- : Called when the print dialog box is closed. See {{event("afterprint")}} event.
- : Called when the print dialog box is closed. See {{domxref("Window.afterprint_event", "afterprint")}} event.
- {{domxref("WindowEventHandlers.onbeforeprint")}}
- : Called when the print dialog box is opened. See {{event("beforeprint")}} event.
- : Called when the print dialog box is opened. See {{domxref("Window.beforeprint_event", "beforeprint")}} event.
- {{domxref("WindowEventHandlers.onbeforeunload")}}
- : An event handler property for before-unload events on the window.
- {{domxref("GlobalEventHandlers.onblur")}}
Expand Down Expand Up @@ -407,9 +407,9 @@ Listen to these events using [`addEventListener()`](/en-US/docs/Web/API/EventTar
Also available via the {{domxref("WindowEventHandlers/onlanguagechange", "onlanguagechange")}} property.
- {{domxref("Window/orientationchange_event", "orientationchange")}} {{deprecated_inline}}
- : Fired when the orientation of the device has changed.
- {{domxref("Window/devicemotion_event", "devicemotion")}}
- {{domxref("Window.devicemotion_event", "devicemotion")}}
- : Fired at a regular interval, indicating the amount of physical force of acceleration the device is receiving and the rate of rotation, if available.
- {{domxref("Window/deviceorientation_event", "deviceorientation")}}
- {{domxref("Window.deviceorientation_event", "deviceorientation")}}
- : Fired when fresh data is available from the magnetometer orientation sensor about the current orientation of the device as compared to the Earth coordinate frame.
- {{domxref("Window/resize_event", "resize")}}
- : Fired when the window has been resized.
Expand Down
Loading

0 comments on commit 593f9ac

Please sign in to comment.