Crate meyerhold

Crate meyerhold 

Source
Expand description

§meyerhold

Progressive reader for Playwright MCP snapshot JSON files.

§Usage

use meyerhold::{Meyerhold, ListType};

// Parse from JSON string
let json_str = r#"{"content":[{"text":"snapshot content..."}]}"#;
let mh = Meyerhold::from_str(json_str)?;

// Get summary
let summary = mh.summary();
println!("URL: {}", summary.page_url);

// List elements
let buttons = mh.elements(ListType::Buttons);
for btn in buttons {
    println!("[{}] {}", btn.ref_id, btn.label);
}

// Search
let results = mh.search("Sign in", false)?;

Structs§

Element
An interactive element extracted from snapshot.
Meyerhold
Main interface for working with Playwright MCP snapshots.
SearchResult
A search result with context.
SnapshotSummary
Summary information extracted from a snapshot.

Enums§

ContentItem
Content item representing any element in page/DOM order.
ListType
Type of elements to list.
MeyerholdError
Errors that can occur when working with Playwright MCP snapshots.
Section
Section types for extraction.

Constants§

DEFAULT_TEXT_CHAR_LIMIT
Default character limit for text preview.