servo/components
Narfinger 991be359a3
libservo: Allow embedders to execute JavaScript scripts via the API (#35720)
This change adds a new `WebView` API `evaluate_javascript()`, which
allows embedders to
execute JavaScript code and wait for a reply asynchronously. Ongoing
script execution is
tracked by a libservo `JavaScriptEvaluator` struct, which maps an id to
the callback passed
to the `evaluate_javascript()` method. The id is used to track the
script and its execution
through the other parts of Servo.

Testing: This changes includes `WebView` unit tests.

---------

Signed-off-by: Narfinger <Narfinger@users.noreply.github.com>
Signed-off-by: Martin Robinson <mrobinson@igalia.com>
Co-authored-by: Martin Robinson <mrobinson@igalia.com>
2025-05-13 12:54:18 +00:00
..
allocator Organize component Cargo.toml dependencies (#36224) 2025-03-30 19:03:54 +00:00
background_hang_monitor Organize component Cargo.toml dependencies (#36224) 2025-03-30 19:03:54 +00:00
bluetooth Replace bluetooth Readme with corrected version from devices repository (#36429) 2025-04-10 18:02:45 +00:00
canvas canvas: rename snapshot(_data) to surface() -> SourceSurface/bytes() -> AsRef<[u8]> (#36793) 2025-05-01 14:18:56 +00:00
compositing Remove duplicate click event in simulate_mouse_click (#36957) 2025-05-13 10:25:09 +00:00
config [OH] allow setting log_filter via prefs.json (#36916) 2025-05-08 16:10:30 +00:00
constellation libservo: Allow embedders to execute JavaScript scripts via the API (#35720) 2025-05-13 12:54:18 +00:00
deny_public_fields Add rust-version to all Cargo.toml files (#33483) 2024-09-17 16:39:07 +00:00
devtools DevTools: Improve resource_available to handle multiple connections (#36933) 2025-05-09 12:06:33 +00:00
dom_struct script: Feature-gate all crown support. (#35055) 2025-01-18 21:36:15 +00:00
domobject_derive Update rustfmt to the 2024 style edition (#35764) 2025-03-03 11:26:53 +00:00
fonts Various memory measurement improvements (#36834) 2025-05-07 04:00:12 +00:00
geometry servoshell: Allow overriding screen resolution with a command-line argument (#34038) 2024-10-30 11:54:13 +00:00
hyper_serde Update rustfmt to the 2024 style edition (#35764) 2025-03-03 11:26:53 +00:00
jstraceable_derive Add rust-version to all Cargo.toml files (#33483) 2024-09-17 16:39:07 +00:00
layout layout: Add a repaint-only incremental layout mode (#36978) 2025-05-12 17:03:50 +00:00
malloc_size_of layout: Share styles to inline box children via SharedInlineStyles (#36896) 2025-05-12 09:38:50 +00:00
media compositing: Combine webrender_traits and compositing_traits (#36372) 2025-04-06 17:34:18 +00:00
metrics Move ScriptToConstellationMsg to constellation_traits (#36364) 2025-04-05 22:13:29 +00:00
net fix: ReadableStream::get_in_memory_bytes too large (#36914) 2025-05-12 16:00:14 +00:00
pixels pixels: Actually write pixels in MULTIPLY generic_transform_inplace operations (#36895) 2025-05-08 07:38:02 +00:00
profile Make the memory reporting multi-process aware (#35863) 2025-04-05 05:42:12 +00:00
rand Migrate to the 2024 edition (#35755) 2025-03-13 10:28:11 +00:00
range Add rust-version to all Cargo.toml files (#33483) 2024-09-17 16:39:07 +00:00
script libservo: Allow embedders to execute JavaScript scripts via the API (#35720) 2025-05-13 12:54:18 +00:00
script_bindings svg: Add mock SVGImageElement interface (#36975) 2025-05-13 10:43:10 +00:00
servo libservo: Allow embedders to execute JavaScript scripts via the API (#35720) 2025-05-13 12:54:18 +00:00
servo_tracing [tracing] Add convenience macro for function tracing (#36573) 2025-04-22 19:58:20 +00:00
shared libservo: Allow embedders to execute JavaScript scripts via the API (#35720) 2025-05-13 12:54:18 +00:00
timers Update rustfmt to the 2024 style edition (#35764) 2025-03-03 11:26:53 +00:00
url Various memory measurement improvements (#36834) 2025-05-07 04:00:12 +00:00
webdriver_server Fix origin relative coordinate for wheel scroll and refactoring (#36985) 2025-05-13 10:46:27 +00:00
webgl webgl: Use glow::Context::supported_extensions() to implement getSupportedExtensions() (#36911) 2025-05-08 08:34:52 +00:00
webgpu Introduce snapshot concept of canvas (#36119) 2025-04-23 07:32:47 +00:00
webxr libservo: Expose a ServoBuilder (#36549) 2025-04-16 16:58:52 +00:00