October in Servo: video captions and inert content

本文为原文前 6,000 字符的节选翻译,完整内容请查看原文。

October in Servo: video captions and inert content

October in Servo: video captions and inert content Plus WebAudio nodes, image inputs, and more! Posted 2026-11-25 Servo 0.8.0 contains all of the changes we landed in October, spanning 588 commits (a new record)! Servo now renders subtitles and captions over

Servo 十月:视频字幕与 inert 内容。外加 WebAudio 节点、图像输入等功能!发布于 2026 年 11 月 25 日。Servo 0.8.0 包含了我们在十月份完成的所有更改,共计 588 次提交(创下新纪录)!Servo 现在可以在

We’ve shipped new web platform features: the spelling-error and grammar-error values for text-decoration-line (@yezhizhen, #48883) the progress() CSS math function (@Loirooriol, #48474) (@SilvioPilato, #48265) the :focus-visible pseudoclass (@TimvdLippe, #49255, #49304) the beforeinput event (@dzfrias, #48519) the element (@mrobinson, #48755) the auto and stable values for the text-wrap-style property (@nicoburns, #48958) inert trees and the interactivity property (@skyz1, @TimvdLippe, #48967)

我们发布了新的 Web 平台功能:text-decoration-line 的 spelling-error 和 grammar-error 值(@yezhizhen, #48883)、progress() CSS 数学函数(@Loirooriol, #48474)、(@SilvioPilato, #48265)、:focus-visible 伪类(@TimvdLippe, #49255, #49304)、beforeinput 事件(@dzfrias, #48519)、 元素(@mrobinson, #48755)、text-wrap-style 属性的 auto 和 stable 值(@nicoburns, #48958)以及 inert 树和 interactivity 属性(@skyz1, @TimvdLippe, #48967)。

Plus a bunch of new DOM APIs: the DelayNode and ConvolverNode WebAudio nodes (@kevlu93, @TimvdLippe, #48658, #47957) the timeout property of XMLHTTPRequest in worker globals (@CynthiaOketch, #48854, #49023) the hspace and vspace attributes on (@TimvdLippe, #48605) the hspace, vspace, width, and height attributes on (@TimvdLippe, #49031) the target property of HTMLBaseElement (@sabbCodes, #48985) the CloseWatcher interface, and the closedBy and requestClose() members of HTMLDialogElement (@skyz1, @lukewarlow, @TimvdLippe, #48955)

此外还有一系列新的 DOM API:DelayNode 和 ConvolverNode WebAudio 节点(@kevlu93, @TimvdLippe, #48658, #47957)、Worker 全局作用域中 XMLHTTPRequest 的 timeout 属性(@CynthiaOketch, #48854, #49023)、 上的 hspace 和 vspace 属性(@TimvdLippe, #48605)、 上的 hspace、vspace、width 和 height 属性(@TimvdLippe, #49031)、HTMLBaseElement 的 target 属性(@sabbCodes, #48985)以及 CloseWatcher 接口,还有 HTMLDialogElement 的 closedBy 和 requestClose() 成员(@skyz1, @lukewarlow, @TimvdLippe, #48955)。

Real world compat Flutter web content no longer hangs now that we fixed a serious performance problem with typed arrays (@jdm, #48640). Example We’re interested to hear how well your favourite websites run in Servo! Report successes in this Zulip thread or this Github discussion, and failures in our GitHub issues.

真实世界兼容性:由于我们修复了类型化数组的一个严重性能问题,Flutter Web 内容现在不再挂起(@jdm, #48640)。示例:我们很想听听您最喜爱的网站在 Servo 中运行得如何!请在此 Zulip 主题或此 GitHub 讨论中报告成功案例,并在我们的 GitHub 问题中报告失败案例。

Work in progress With respect to accessibility in Servo, we report many more ARIA roles for DOM elements (@alice, @mrobinson, #48839). These can be inspected with the Get Computed Role WebDriver command (@lolaodelola, #47339). Accessibility integration can be turned on with the accessibility_enabled preference.

开发中:关于 Servo 的可访问性,我们为 DOM 元素报告了更多的 ARIA 角色(@alice, @mrobinson, #48839)。这些可以通过 Get Computed Role WebDriver 命令进行检查(@lolaodelola, #47339)。可访问性集成可以通过 accessibility_enabled 首选项开启。

WebGL2 support received lots of attention this month, with fixes to getParameter(), drawBuffers(), readBuffers(), vertexAttribIPointer(), DEPTH_STENCIL_ATTACHMENT, getUniformLocation(), vertexAttrib4x(), pixelStorei(), texStorage2D(), texStorage3D(), texImage3D(), getInternalformatParameter(), blitFramebuffer(), and texSubImage2D() (@mxmgorin, #48651, #48620, #48678, #48689, #48751, #48681, #48911, #48972, #48590, #49201, #49289, #48560, #48571). The feature remains gated behind the dom_webgl2_enabled preference.

本月 WebGL2 支持受到了高度关注,修复了 getParameter()、drawBuffers()、readBuffers()、vertexAttribIPointer()、DEPTH_STENCIL_ATTACHMENT、getUniformLocation()、vertexAttrib4x()、pixelStorei()、texStorage2D()、texStorage3D()、texImage3D()、getInternalformatParameter()、blitFramebuffer() 和 texSubImage2D()(@mxmgorin, #48651, #48620, #48678, #48689, #48751, #48681, #48911, #48972, #48590, #49201, #49289, #48560, #48571)。该功能仍受 dom_webgl2_enabled 首选项控制。

Reading and writing mapped WebGPU buffers got a significant speed increase (@sagudev, @jdm, #48372). WebGPU can be enabled with the dom_webgpu_enabled preference. JS script compilation can now occur off the main thread when the dom_script_asynch preference is enabled (@Gae24, #45687). Right now this only applies to non-module scripts.

读取和写入映射的 WebGPU 缓冲区速度显著提升(@sagudev, @jdm, #48372)。WebGPU 可以通过 dom_webgpu_enabled 首选项启用。当启用 dom_script_asynch 首选项时,JS 脚本编译现在可以在主线程之外进行(@Gae24, #45687)。目前这仅适用于非模块脚本。

Initial support for the backdrop-filter property has merged (@shubhamg13, #48829). This can be enabled with the layout_css_backdrop_filter_enabled preference. ServiceWorkers now fire the statechange event when changing states during initialization (@gterzian, #48749). ServiceWorkerContainer can listen for message and messageerror events (@gterzian, #48680). Service Workers remain gated behind the dom_serviceworker_enabled preference.

backdrop-filter 属性的初步支持已合并(@shubhamg13, #48829)。可以通过 layout_css_backdrop_filter_enabled 首选项启用。ServiceWorkers 现在在初始化期间更改状态时会触发 statechange 事件(@gterzian, #48749)。ServiceWorkerContainer 可以监听 message 和 messageerror 事件(@gterzian, #48680)。Service Workers 仍受 dom_serviceworker_enabled 首选项控制。

The Geolocation API has been implemented (@webbeef, #48406). No platform-specific backends to provide the device geolocation data have merged yet, so it remains disabled behind the dom_geolocation_enabled preference. DOM interfaces for MathML elements now exist, gated behind the mathml_core_enabled preference (@tannal, #48631). There is no MathML-specific layout implemented yet.

Geolocation API 已实现(@webbeef, #48406)。由于尚未合并提供设备地理位置数据的特定平台后端,因此它仍处于禁用状态,受 dom_geolocation_enabled 首选项控制。MathML 元素的 DOM 接口现已存在,受 mathml_core_enabled 首选项控制(@tannal, #48631)。目前尚未实现 MathML 特定的布局。

A new, native SVG implementation is in progress (@mu-mostafa98, @jdm, #48467). This work is still in the early stages, but is intended to replace Servo’s dependency on the resvg crate to better integrate with page styling and animations. IndexedDB cursors now support the update() and delete() methods (@kuntal-devrat, #48402). The feature can be enabled with the dom_indexeddb_enabled preference.

一项新的原生 SVG 实现正在进行中(@mu-mostafa98, @jdm, #48467)。这项工作仍处于早期阶段,旨在取代 Servo 对 resvg crate 的依赖,以便更好地与页面样式和动画集成。IndexedDB 游标现在支持 update() 和 delete() 方法(@kuntal-devrat, #48402)。该功能可以通过 dom_indexeddb_enabled 首选项启用。

Support for LargestContentfulPaint performance timing improved, with image URLs (@shubhamg13, #48668), the loadTime value (@shubhamg13, #48676), ignoring non-paintable elements (@shubhamg13, #48856, #48898), video URLs (@shubhamg13, #48931), and following containing blocks (@shubhamg13, #48551). This work is behind the largest_contentful_paint_enabled preference. We added support for a new performance timing metric: ContainerTiming (@jasonwilliams, #46966). This can be enabled with the container_timing_enabled preference.

LargestContentfulPaint 性能计时的支持得到了改进,包括图像 URL(@shubhamg13, #48668)、loadTime 值(@shubhamg13, #48676)、忽略不可绘制元素(@shubhamg13, #48856, #48898)、视频 URL(@shubhamg13, #48931)以及遵循包含块(@shubhamg13, #48551)。这项工作受 largest_contentful_paint_enabled 首选项控制。我们增加了对一种新的性能计时指标的支持:ContainerTiming(@jasonwilliams, #46966)。可以通过 container_timing_enabled 首选项启用。

Our support for adoptedStylesheets improved along with a new implementation of the ObservableArray specification concept (@jerensl, @arihant2math, #48506). This is currently hidden behind the dom_adoptedstylesheet_enabled preference.

我们对 adoptedStylesheets 的支持得到了改进,同时还实现了 ObservableArray 规范概念的新实现(@jerensl, @arihant2math, #48506)。目前该功能隐藏在 dom_adoptedstylesheet_enabled 首选项之后。

Embedding API The Android Compose migration is complete, and embedders now only need to interact with the Servo library component (@veyndan, #48592, #48601, #48595, #48574, #48609, #48778, #48780, #49266). Embedders no longer need to trigger the soft keyboard display; this is controlled by a parameter to the Servo component (@veyndan, #48757).

嵌入 API:Android Compose 迁移已完成,嵌入者现在只需与 Servo 库组件交互(@veyndan, #48592, #48601, #48595, #48574, #48609, #48778, #48780, #49266)。嵌入者不再需要触发软键盘显示;这由 Servo 组件的一个参数控制(@veyndan, #48757)。

There’s a new API method to report the network status of the embedder: NetworkManager::set_online_state (@xbwwj, #47568). This data is exposed via the onLine property of the Navigator interface in web content. Embedders can now disable all support for developer tools, which can reduce the size of the final binary (@janeoa, #47255). This is controlled by the devtools feature and enabled by default; it is also part of the new default_tooling feature.

有一个新的 API 方法用于报告嵌入者的网络状态:NetworkManager::set_online_state(@xbwwj, #47568)。此数据通过 Web 内容中 Navigator 接口的 onLine 属性公开。嵌入者现在可以禁用对开发人员工具的所有支持,这可以减小最终二进制文件的大小(@janeoa, #47255)。这由 devtools 功能控制,默认启用;它也是新的 default_tooling 功能的一部分。

Users of the C API can set preferences that accept f64 and f64 array parameters (@fran6co, #49325), as well as the HiDPI scale factor for each WebView (@fran6co, #49327). WebViews can also be resized via the C API (@fran6co, #49326). The layout_grid_enabled preference has been removed, since C

C API 的用户可以设置接受 f64 和 f64 数组参数的首选项(@fran6co, #49325),以及每个 WebView 的 HiDPI 缩放因子(@fran6co, #49327)。WebView 也可以通过 C API 调整大小(@fran6co, #49326)。layout_grid_enabled 首选项已被移除,因为 C