Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion files/en-us/web/api/document/arianotify/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,13 @@ title: "Document: ariaNotify() method"
short-title: ariaNotify()
slug: Web/API/Document/ariaNotify
page-type: web-api-instance-method
status:
- experimental
- non-standard
browser-compat: api.Document.ariaNotify
---

{{ApiRef("DOM")}}
{{ApiRef("DOM")}}{{SeeCompatTable}}{{non-standard_header}}

The **`ariaNotify()`** method of the {{domxref("Document")}} interface specifies that a given string of text should be announced by a {{glossary("screen reader")}} if available and activated.

Expand Down
2 changes: 1 addition & 1 deletion files/en-us/web/api/document/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ _This interface also inherits from the {{DOMxRef("Node")}} and {{DOMxRef("EventT
- : Returns an {{DOMxRef("HTMLCollection")}} of the available plugins.
- {{DOMxRef("Document.pointerLockElement")}} {{ReadOnlyInline}}
- : Returns the element set as the target for mouse events while the pointer is locked. `null` if lock is pending, pointer is unlocked, or if the target is in another document.
- {{DOMxRef("Document.prerendering")}} {{ReadOnlyInline}} {{experimental_inline}} {{non-standard_inline}}
- {{DOMxRef("Document.prerendering")}} {{ReadOnlyInline}} {{experimental_inline}}
- : Returns a boolean that indicates whether the document is currently in the process of prerendering, as initiated via the [Speculation Rules API](/en-US/docs/Web/API/Speculation_Rules_API).
- {{DOMxRef("Document.scripts")}} {{ReadOnlyInline}}
- : Returns an {{DOMxRef("HTMLCollection")}} of the {{HTMLElement("script")}} elements in the document.
Expand Down
3 changes: 1 addition & 2 deletions files/en-us/web/api/document/prerendering/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,10 @@ slug: Web/API/Document/prerendering
page-type: web-api-instance-property
status:
- experimental
- non-standard
browser-compat: api.Document.prerendering
---

{{ APIRef("Speculation Rules API") }}{{seecompattable}}{{non-standard_header}}
{{ APIRef("Speculation Rules API") }}{{seecompattable}}

The **`prerendering`** read-only property of the {{domxref("Document")}} interface returns `true` if the document is currently in the process of prerendering, as initiated via the [Speculation Rules API](/en-US/docs/Web/API/Speculation_Rules_API).

Expand Down
5 changes: 4 additions & 1 deletion files/en-us/web/api/element/arianotify/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,13 @@ title: "Element: ariaNotify() method"
short-title: ariaNotify()
slug: Web/API/Element/ariaNotify
page-type: web-api-instance-method
status:
- experimental
- non-standard
browser-compat: api.Element.ariaNotify
---

{{ApiRef("DOM")}}
{{ApiRef("DOM")}}{{SeeCompatTable}}{{non-standard_header}}

The **`ariaNotify()`** method of the {{domxref("Element")}} interface specifies that a given string of text should be announced by a {{glossary("screen reader")}} if available and activated.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,10 @@ slug: Web/API/PerformanceNavigationTiming/activationStart
page-type: web-api-instance-property
status:
- experimental
- non-standard
browser-compat: api.PerformanceNavigationTiming.activationStart
---

{{APIRef("Performance API")}}{{SeeCompatTable}}{{non-standard_header}}
{{APIRef("Performance API")}}{{SeeCompatTable}}

The **`activationStart`** read-only property represents the time between when a document starts prerendering and when it is activated.

Expand Down
2 changes: 1 addition & 1 deletion files/en-us/web/api/performancenavigationtiming/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ This interface also extends the following {{domxref('PerformanceResourceTiming')

The interface also supports the following properties:

- {{domxref('PerformanceNavigationTiming.activationStart')}} {{ReadOnlyInline}} {{experimental_inline}} {{non-standard_inline}}
- {{domxref('PerformanceNavigationTiming.activationStart')}} {{ReadOnlyInline}} {{experimental_inline}}
- : A {{domxref("DOMHighResTimeStamp")}} representing the time between when a document starts prerendering and when it is activated.
- {{domxref('PerformanceNavigationTiming.criticalCHRestart')}} {{ReadOnlyInline}} {{experimental_inline}}
- : A {{domxref("DOMHighResTimeStamp")}} representing the time at which the connection restart occurred due to {{HTTPHeader("Critical-CH")}} HTTP response header mismatch.
Expand Down
2 changes: 1 addition & 1 deletion files/en-us/web/api/request/destination/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ Possible values are:
- : The target is a service worker.
- `"sharedworker"`
- : The target is a shared worker.
- `"speculationrules"` {{experimental_inline}} {{non-standard_inline}}
- `"speculationrules"` {{experimental_inline}}
- : The target is a [speculation rules](/en-US/docs/Web/API/Speculation_Rules_API) JSON document.
- `"style"`
- : The target is a style
Expand Down
3 changes: 1 addition & 2 deletions files/en-us/web/api/speculation_rules_api/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ slug: Web/API/Speculation_Rules_API
page-type: web-api-overview
status:
- experimental
- non-standard
browser-compat:
- api.Document.prerendering
- api.Document.prerenderingchange_event
Expand All @@ -14,7 +13,7 @@ spec-urls:
- https://wicg.github.io/nav-speculation/prerendering.html
---

{{SeeCompatTable}}{{DefaultAPISidebar("Speculation Rules API")}}{{non-standard_header}}
{{SeeCompatTable}}{{DefaultAPISidebar("Speculation Rules API")}}

The **Speculation Rules API** is designed to improve performance for future navigations. It targets document URLs rather than specific resource files, and so makes sense for multi-page applications (MPAs) rather than single-page applications (SPAs).

Expand Down
2 changes: 2 additions & 0 deletions files/en-us/web/css/font-family/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,8 @@ font-family: "Gill Sans Extrabold", sans-serif;

- `system-ui`
- : Glyphs are taken from the default user interface font on a given platform. Because typographic traditions vary widely across the world, this generic is provided for typefaces that don't map cleanly into the other generics.
> [!NOTE]
> As the name implies, `system-ui` is intended to make UI elements look like native apps, and not for typesetting large paragraphs of text. It may cause the displayed typeface to be undesirable for some users—for example, the default Windows CJK font may render Latin scripts poorly, and the `lang` attribute may not affect the displayed font. Some operating systems do not allow customizing `system-ui`, while browsers generally allow customizing the `sans-serif` font family. For large paragraphs, use `sans-serif` or some other non-UI font family instead.
- `ui-serif`
- : The default user interface serif font.
- `ui-sans-serif`
Expand Down
2 changes: 2 additions & 0 deletions files/en-us/web/css/generic-family/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,8 @@ The `<generic-family>` {{glossary("enumerated")}} type is specified using one of

- `system-ui`
- : Glyphs are taken from the default user interface font on a given platform. Because typographic traditions vary widely across the world, this generic family is provided for typefaces that don't map cleanly into the others.
> [!NOTE]
> As the name implies, `system-ui` is intended to make UI elements look like native apps, and not for typesetting large paragraphs of text. It may cause the displayed typeface to be undesirable for some users—for example, the default Windows CJK font may render Latin scripts poorly, and the `lang` attribute may not affect the displayed font. Some operating systems do not allow customizing `system-ui`, while browsers generally allow customizing the `sans-serif` font family. For large paragraphs, use `sans-serif` or some other non-UI font family instead.

- `ui-serif`
- : The default user interface serif font. See the definition of `serif` above.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ The value of this attribute indicates the type of data represented by the script
The `charset` and `defer` attributes have no effect.
For information on using `module`, see our [JavaScript modules](/en-US/docs/Web/JavaScript/Guide/Modules) guide.
Unlike classic scripts, module scripts require the use of the CORS protocol for cross-origin fetching.
- [`speculationrules`](/en-US/docs/Web/HTML/Reference/Elements/script/type/speculationrules) {{experimental_inline}} {{non-standard_inline}}
- [`speculationrules`](/en-US/docs/Web/HTML/Reference/Elements/script/type/speculationrules) {{experimental_inline}}
- : This value indicates that the body of the element contains speculation rules.
Speculation rules take the form of a JSON object that determine what resources should be prefetched or prerendered by the browser. This is part of the {{domxref("Speculation Rules API", "", "", "nocode")}}.
- **Any other value**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,11 @@ slug: Web/HTML/Reference/Elements/script/type/speculationrules
page-type: html-attribute-value
status:
- experimental
- non-standard
browser-compat: html.elements.script.type.speculationrules
sidebar: htmlsidebar
---

{{SeeCompatTable}}{{non-standard_header}}
{{SeeCompatTable}}

The **`speculationrules`** value of the [`type`](/en-US/docs/Web/HTML/Reference/Elements/script/type) attribute of the [`<script>` element](/en-US/docs/Web/HTML/Reference/Elements/script) indicates that the body of the element contains speculation rules.

Expand Down Expand Up @@ -70,9 +69,9 @@ A `<script type="speculationrules">` element must contain a valid JSON structure

The JSON structure contains one or more fields at the top level, each one representing an action to define speculation rules for. At present the supported actions are:

- `"prefetch"` {{optional_inline}} {{experimental_inline}} {{non-standard_inline}}
- `"prefetch"` {{optional_inline}} {{experimental_inline}}
- : Rules for potential future navigations that should have their associated document response body downloaded, leading to significant performance improvements when those documents are navigated to. Note that none of the subresources referenced by the page are downloaded.
- `"prerender"` {{optional_inline}} {{experimental_inline}} {{non-standard_inline}}
- `"prerender"` {{optional_inline}} {{experimental_inline}}
- : Rules for potential future navigations that should have their associated documents fully downloaded, rendered, and loaded into an invisible tab. This includes loading all subresources, running all JavaScript, and even loading subresources and performing data fetches started by JavaScript. When those documents are navigated to, navigations will be instant, leading to major performance improvements.

> [!NOTE]
Expand All @@ -91,10 +90,10 @@ Each object can contain the following properties:
- `"list"`
- : Specifies that the URLs will come from a list, specified in the `"urls"` key. Note that the presence of a `"urls"` key implies `"source": "list"`, so it is optional.

- `"urls"` {{experimental_inline}} {{non-standard_inline}}
- `"urls"` {{experimental_inline}}
- : An array of strings representing a list of URLs to apply the rule to. These can be absolute or relative URLs. Relative URLs will be parsed relative to the document base URL (if inline in a document) or relative to the external resource URL (if externally fetched). `"urls"` and `"where"` cannot both be set in the same rule.

- `"where"` {{experimental_inline}} {{non-standard_inline}}
- `"where"` {{experimental_inline}}
- : An object representing the conditions by which the rule matches URLs contained in the associated document. Effectively, the `"where"` object represents a test that is performed on every link on the page to see whether the speculation rule is applied to it. `"where"` and `"urls"` cannot both be set in the same rule.

This object can contain exactly one of the following properties:
Expand All @@ -113,7 +112,7 @@ Each object can contain the following properties:

`"where"` conditions can be nested multiple levels deep to create complex conditions, or you can choose to split them into separate rules to keep them simple. See [where examples](#where_syntax_examples) for more explanation, and multiple examples of use.

- `"eagerness"` {{experimental_inline}} {{non-standard_inline}}
- `"eagerness"` {{experimental_inline}}
- : A string providing a hint to the browser as to how eagerly it should prefetch/prerender link targets in order to balance performance advantages against resource overheads. Possible values are:
- `"immediate"`
- : The author thinks the link is very likely to be followed, and/or the document may take significant time to fetch. Prefetch/prerender should start as soon as possible, subject only to considerations such as user preferences and resource limits.
Expand All @@ -126,10 +125,10 @@ Each object can contain the following properties:

If `"eagerness"` is not explicitly specified, list (`"urls"`) rules default to `immediate` and document (`"where"`) rules default to `conservative`. The browser takes this hint into consideration along with its own heuristics, so it may select a link that the author has hinted as less eager than another, if the less eager candidate is considered a better choice.

- `"expects_no_vary_search"` {{experimental_inline}} {{non-standard_inline}}
- `"expects_no_vary_search"` {{experimental_inline}}
- : A string providing a hint to the browser as to what {{httpheader("No-Vary-Search")}} header value will be set on responses for documents that it is receiving prefetch/prerender requests for. The browser can use this to determine ahead of time whether it is more useful to wait for an existing prefetch/prerender to finish, or start a new fetch request when the speculation rule is matched. See the [`"expects_no_vary_search"` example](#expects_no_vary_search_example) for more explanation of how this can be used.

- `"referrer_policy"` {{experimental_inline}} {{non-standard_inline}}
- `"referrer_policy"` {{experimental_inline}}
- : A string representing a specific referrer policy string to use when requesting the URLs specified in the rule — see [`Referrer-Policy`](/en-US/docs/Web/HTTP/Reference/Headers/Referrer-Policy) for possible values. The purpose of this is to allow the referring page to set a stricter policy specifically for the speculative request than the policy the page already has set (either by default, or by using `Referrer-Policy`).

> [!NOTE]
Expand All @@ -138,7 +137,7 @@ Each object can contain the following properties:
> [!NOTE]
> In the case of document rules, the matched link's specified referrer policy (e.g., using the [`referrerpolicy`](/en-US/docs/Web/HTML/Reference/Elements/a#referrerpolicy) attribute) will be used, unless the rule specifies a policy that overrides it.

- `"relative_to"` {{experimental_inline}} {{non-standard_inline}}
- `"relative_to"` {{experimental_inline}}
- : A string specifying where you want links matched by URL to be matched relative to. The value can be one of:
- `document`
- : URLs should be matched relative to the document the speculation rules are being set on.
Expand All @@ -147,7 +146,7 @@ Each object can contain the following properties:

This key setting is only relevant for rules defined in an external file (set using the {{httpheader("Speculation-Rules")}} header). When rules are specified inside the same document they are being set for (i.e., in an inline `<script>` element), it makes no difference.

- `"requires"` {{experimental_inline}} {{non-standard_inline}}
- `"requires"` {{experimental_inline}}
- : An array of strings representing capabilities of the browser parsing the rule, which must be available if the rule is to be applied to the specified URLs.

> [!WARNING]
Expand All @@ -161,10 +160,10 @@ Each object can contain the following properties:
- A future Safari implementation may possibly use something along the lines of [iCloud Private Relay](https://support.apple.com/en-us/102602).
- A future Firefox implementation might use something based on the [Mozilla VPN](https://www.mozilla.org/en-US/products/vpn/) product.

- `"tag"` {{experimental_inline}} {{non-standard_inline}}
- `"tag"` {{experimental_inline}}
- : A string used to identify a rule or ruleset. This will be included in the {{HTTPHeader("Sec-Speculation-Tags")}} request header for any speculations covered by that rule.

- `"target_hint"` {{experimental_inline}} {{non-standard_inline}}
- `"target_hint"` {{experimental_inline}}
- : A string indicating where the page expects the prerendered content to be activated.
The directive not supported for prefetch speculations.
Allowed values are:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ browser-compat: http.headers.Permissions-Policy.aria-notify
sidebar: http
---

{{SeeCompatTable}}
{{SeeCompatTable}}{{non-standard_header}}

The HTTP {{HTTPHeader("Permissions-Policy")}} header `aria-notify` directive controls whether the current document is allowed to use the {{domxref("Document.ariaNotify()")}} and {{domxref("Element.ariaNotify()")}} methods to fire {{glossary("screen reader")}} announcements.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,11 @@ slug: Web/HTTP/Reference/Headers/Sec-Speculation-Tags
page-type: http-header
status:
- experimental
- non-standard
browser-compat: http.headers.Sec-Speculation-Tags
sidebar: http
---

{{SeeCompatTable}}{{non-standard_header}}
{{SeeCompatTable}}

The HTTP **`Sec-Speculation-Tags`** {{Glossary("request header")}} contains one or more `tag` values from the [speculation rules](/en-US/docs/Web/API/Speculation_Rules_API) that resulted in the speculation. This allows a server to identify which rule(s) caused a speculation and potentially block them.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,11 @@ slug: Web/HTTP/Reference/Headers/Speculation-Rules
page-type: http-header
status:
- experimental
- non-standard
browser-compat: http.headers.Speculation-Rules
sidebar: http
---

{{SeeCompatTable}}{{non-standard_header}}
{{SeeCompatTable}}

The HTTP **`Speculation-Rules`** {{Glossary("response header")}} provides one or more URLs pointing to text resources containing speculation rule JSON definitions. When the response is an HTML document, these rules will be added to the document's speculation rule set. See the [Speculation Rules API](/en-US/docs/Web/API/Speculation_Rules_API) for more information.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,11 @@ slug: Web/HTTP/Reference/Headers/Supports-Loading-Mode
page-type: http-header
status:
- experimental
- non-standard
browser-compat: http.headers.Supports-Loading-Mode
sidebar: http
---

{{securecontext_header}}{{SeeCompatTable}}{{non-standard_header}}
{{securecontext_header}}{{SeeCompatTable}}

The HTTP **`Supports-Loading-Mode`** {{Glossary("response header")}} allows a response to opt-in to being loaded in a novel, higher-risk context that it would otherwise fail to be loaded in.

Expand Down Expand Up @@ -43,9 +42,9 @@ Supports-Loading-Mode: <client-hint-headers>

The `Supports-Loading-Mode` header value is a list of one or more tokens, which can include the following values:

- `credentialed-prerender` {{experimental_inline}} {{non-standard_inline}}
- `credentialed-prerender` {{experimental_inline}}
- : Indicates that a destination origin opts in to loading documents via cross-origin, same-site [prerendering](/en-US/docs/Web/API/Speculation_Rules_API#using_prerendering).
- `fenced-frame` {{experimental_inline}} {{non-standard_inline}}
- `fenced-frame` {{experimental_inline}}
- : The response can loaded inside a [fenced frame](/en-US/docs/Web/API/Fenced_frame_API). Without this explicit opt-in, all navigations inside of a fenced frame will fail.

## Examples
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -353,9 +353,9 @@ These properties are defined on `Map.prototype` and shared by all `Map` instance
- : Calls `callbackFn` once for each key-value pair present in the `Map` object, in insertion order. If a `thisArg` parameter is provided to `forEach`, it will be used as the `this` value for each callback.
- {{jsxref("Map.prototype.get()")}}
- : Returns the value corresponding to the key in this `Map`, or `undefined` if there is none.
- {{jsxref("Map.prototype.getOrInsert()")}}
- {{jsxref("Map.prototype.getOrInsert()")}} {{experimental_inline}}
- : Returns the value corresponding to the specified key in this `Map`. If the key is not present, it inserts a new entry with the key and a given default value, and returns the inserted value.
- {{jsxref("Map.prototype.getOrInsertComputed()")}}
- {{jsxref("Map.prototype.getOrInsertComputed()")}} {{experimental_inline}}
- : Returns the value corresponding to the specified key in this `Map`. If the key is not present, it inserts a new entry with the key and a default value computed from a given callback, and returns the inserted value.
- {{jsxref("Map.prototype.has()")}}
- : Returns a boolean indicating whether an entry with the specified key exists in this `Map` or not.
Expand Down
Loading