files/en-us/mozilla/firefox/releases/125/index.md
This article provides information about the changes in Firefox 125 that affect developers. Firefox 125 was released on April 16, 2024.
No notable changes.
display: block; layouts. This brings all the layout positions from flex and grid to block, enabling developers to align block-level elements without converting their container to a flex or grid container. (Firefox bug 1882853).transform-box now supports the values content-box and stroke-box. For the reference box, the content-box value uses the content box and the stroke-box value uses the stroke bounding box that contains an SVG's shape (Firefox bug 1868374).content-visibility CSS property value auto is now enabled by default. This allows content to skip rendering if it is not relevant to the user. (Firefox bug 1874874).Intl.Segmenter("ja-JP", { granularity: "word" }).
You can also split strings into graphemes or sentences.
(Firefox bug 1423593, Firefox bug 1883914.)The Popover API is now fully supported, allowing the creation of top level "popover" UI elements that might be used for action menus, custom "toast" notifications, form element suggestions, content pickers, and so on. The popover and its triggering button/input can be created using either HTML attributes or JavaScript, and styled using CSS.
The following Web APIs are implemented:
HTMLButtonElement properties popoverTargetElement and popoverTargetAction.HTMLInputElement properties popoverTargetElement and popoverTargetAction.HTMLElement property popover, hidePopover(), showPopover(), and togglePopover() methods, and beforetoggle and toggle_event events (of type ToggleEvent).The following CSS pseudo class and element are now supported for use with popovers:
:popover-open::backdrop has been extended to support popoversThe following HTML global attributes are supported:
The {{domxref("RTCIceTransport")}} properties {{domxref("RTCIceTransport/state","state")}} and {{domxref("RTCIceTransport/gatheringState","gatheringState")}}, and their associated events {{domxref("RTCIceTransport/statechange_event","statechange")}} and {{domxref("RTCIceTransport/gatheringstatechange_event","gatheringstatechange")}}, are now supported, along with the {{domxref("RTCDtlsTransport.iceTransport")}} property (which returns the underlying RTCIceTransport for a {{domxref("RTCDtlsTransport")}}).
These allow much finer-grained monitoring than provided by the {{domxref("RTCPeerConnection")}} properties {{domxref("RTCPeerConnection.iceGatheringState","iceGatheringState")}} and {{domxref("RTCPeerConnection.connectionState","connectionState")}}.
(Firefox bug 1811912)
{{domxref("Element.ariaBrailleLabel")}} and {{domxref("Element.ariaBrailleRoleDescription")}} are now supported, respectively reflecting the global ARIA HTML attributes aria-braillelabel and aria-brailleroledescription. (Firefox bug 1861201).
Added support to allow web applications to gracefully recover if a canvas temporarily loses its 2D context, which might happen if the canvas is running hardware-accelerated on a GPU, and its driver crashes (Firefox bug 1887729). Here are some additional details on the events for lost and restored canvas contexts:
contextlost and contextrestored events, which are fired on at HTMLCanvasElement when the context is lost and recovered, respectively, and can also check the context using CanvasRenderingContext2D.isContextLost().contextlost, a browser will try and restart the lost context, by default, but code can prevent this by cancelling the event.OffScreenCanvas events contextlost and contextrestored, along with OffscreenCanvasRenderingContext2D.isContextLost().Added support for the shadowrootclonable attribute of the <template> element, and the shadowRootClonable property of the HTMLTemplateElement interface that reflects it.
These set the clonable property of a ShadowRoot that has been created declaratively using the <template> element.
(Firefox bug 1880188).
The readText() method of the Clipboard interface is now supported for asynchronously reading text from the system clipboard.
When reading clipboard data that is not provided by the same-origin page, a paste context menu will appear for the user to confirm. (Firefox bug 1877400).
SVGAElement.text property has been removed. The {{domxref("Node.textContent", "textContent")}} property (inherited from Node) is broadly supported and should be used instead. (Firefox bug 1880689).<input> elements with type="file" (Firefox bug 1855040).visibilityState to be updated (Firefox bug 1877469).proxyAuthorization is now passed to the {{httpheader("Proxy-Authorization")}} request header sent to HTTP proxies (in addition to the existing support for HTTPS proxies) as part of a CONNECT request (Firefox bug 1794464).These features are shipping in Firefox 125 but only in developer releases or behind a preference. To try these out, you can search for the related preference on the about:config page to see if they're enabled or disabled. To learn more about these features, see the Experimental features page.
CSS transition-behavior: layout.css.transition-behavior.enabled.
The {{cssxref("transition-behavior")}} property is enabled by default in the Nightly release. Authors can use this property to control whether to apply CSS transitions to properties with a discrete animation type (Firefox bug 1882408, Firefox bug 1805727).
UA styles for <h1> nested into sectioning elements: layout.css.h1-in-section-ua-styles.enabled.
The <h1> heading doesn't decrease in font size now when nested within sectioning elements <article>, <aside>, <nav>, and <section>. The UA styles for <h1> nested within sectioning elements are no longer relevant since the outline algorithm has been removed from the HTML specification. (Firefox bug 1883896).
[!NOTE] The preference for this feature works in reverse: it's set to
falsein the Nightly build, which removes the UA styling for headings nested in sectioning elements. It's set totruein all other channels, which retains the existing UA styling for the nested headings.