📃 June 2021 release notes
Widely available
The following features are now widely available:
-
Constraint validation API:
Methods that validate form controls before submission, such as
checkValidity(),reportValidity()andsetCustomValidity(). -
Interaction media queries:
The
pointer,any-pointer,hover, andany-hoverCSS media queries set styles based on the presence of pointing devices and their ability to hover over elements. For example, most smartphones match the(hover: none) and (pointer: coarse)media query.
New in Firefox
The following features are now available in Firefox:
-
aspect-ratio:
The
aspect-ratioCSS property controls the width-to-height ratio of elements. For<img>and<video>elements, thewidthandheightattributes used together withheight: autocontrol the aspect ratio while the image/video is loading. -
Event timing:
The
eventandfirst-inputperformance entries and thePerformanceEventTimingAPI measures the latency of user input events, such as mouse clicks or keypresses. They're used to calculate Interaction to Next Paint (INP), a common metric for perceived responsiveness. -
Font metric overrides:
The
ascent-override,descent-override, andline-gap-overridedescriptors adjust the display of a font declared in an@font-facestatement. This can help make fallback fonts look the same size. -
Forced colors:
The
forced-colorsCSS @media rule detects when a user has chosen to use a forced colors mode, also known as high-contrast mode, and theforced-color-adjustCSS property sets whether forced colors apply to an element. -
image-set():
The
image-set()CSS function provides a set of images at different resolutions or pixel densities, which the browser can pick from, depending on the device capabilities. -
Top-level await:
The
awaitkeyword, when used at the top level of a module (outside of an async function), delays parent module execution until after a promise fulfills. - Fixed-width SIMD (WebAssembly): 128-bit SIMD (Single Instruction Multiple Data) performs one instruction on multiple units of data, when running on hardware that supports such instructions. Also known as vector instructions.
New in Firefox for Android
The following features are now available in Firefox for Android:
-
aspect-ratio:
The
aspect-ratioCSS property controls the width-to-height ratio of elements. For<img>and<video>elements, thewidthandheightattributes used together withheight: autocontrol the aspect ratio while the image/video is loading. -
Event timing:
The
eventandfirst-inputperformance entries and thePerformanceEventTimingAPI measures the latency of user input events, such as mouse clicks or keypresses. They're used to calculate Interaction to Next Paint (INP), a common metric for perceived responsiveness. -
Font metric overrides:
The
ascent-override,descent-override, andline-gap-overridedescriptors adjust the display of a font declared in an@font-facestatement. This can help make fallback fonts look the same size. -
Forced colors:
The
forced-colorsCSS @media rule detects when a user has chosen to use a forced colors mode, also known as high-contrast mode, and theforced-color-adjustCSS property sets whether forced colors apply to an element. -
image-set():
The
image-set()CSS function provides a set of images at different resolutions or pixel densities, which the browser can pick from, depending on the device capabilities. -
Top-level await:
The
awaitkeyword, when used at the top level of a module (outside of an async function), delays parent module execution until after a promise fulfills. - Fixed-width SIMD (WebAssembly): 128-bit SIMD (Single Instruction Multiple Data) performs one instruction on multiple units of data, when running on hardware that supports such instructions. Also known as vector instructions.