playwright-ruby-client 1.63.0 → 1.64.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/documentation/docs/api/api_request_context.md +47 -0
- data/documentation/docs/api/browser.md +2 -0
- data/documentation/docs/api/browser_type.md +1 -0
- data/documentation/docs/api/clock.md +1 -0
- data/documentation/docs/api/credentials.md +6 -3
- data/documentation/docs/api/frame.md +6 -1
- data/documentation/docs/api/locator.md +38 -0
- data/documentation/docs/api/page.md +32 -1
- data/documentation/docs/api/request.md +1 -1
- data/documentation/docs/api/response.md +2 -1
- data/documentation/docs/api/tracing.md +2 -2
- data/documentation/docs/api/web_mcp.md +34 -0
- data/documentation/docs/article/guides/playwright_on_alpine_linux.md +1 -1
- data/documentation/docs/include/api_coverage.md +12 -0
- data/lib/playwright/channel_owners/api_request_context.rb +16 -0
- data/lib/playwright/channel_owners/browser_context.rb +4 -31
- data/lib/playwright/channel_owners/frame.rb +4 -3
- data/lib/playwright/channel_owners/local_utils.rb +5 -0
- data/lib/playwright/channel_owners/page.rb +10 -2
- data/lib/playwright/channel_owners/tracing.rb +2 -0
- data/lib/playwright/connection.rb +6 -2
- data/lib/playwright/credentials_impl.rb +2 -1
- data/lib/playwright/errors.rb +4 -1
- data/lib/playwright/locator_impl.rb +22 -8
- data/lib/playwright/screencast.rb +4 -2
- data/lib/playwright/transport.rb +21 -5
- data/lib/playwright/utils.rb +20 -0
- data/lib/playwright/version.rb +2 -2
- data/lib/playwright/web_mcp_impl.rb +21 -0
- data/lib/playwright_api/api_request_context.rb +38 -0
- data/lib/playwright_api/browser.rb +4 -2
- data/lib/playwright_api/browser_context.rb +4 -4
- data/lib/playwright_api/browser_type.rb +2 -1
- data/lib/playwright_api/clock.rb +1 -0
- data/lib/playwright_api/credentials.rb +7 -4
- data/lib/playwright_api/frame.rb +8 -2
- data/lib/playwright_api/locator.rb +38 -3
- data/lib/playwright_api/page.rb +40 -11
- data/lib/playwright_api/request.rb +5 -5
- data/lib/playwright_api/response.rb +2 -1
- data/lib/playwright_api/tracing.rb +2 -2
- data/lib/playwright_api/web_mcp.rb +26 -0
- data/lib/playwright_api/worker.rb +4 -4
- data/sig/playwright.rbs +21 -8
- metadata +5 -2
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
module Playwright
|
|
2
|
+
#
|
|
3
|
+
# `WebMCP` exposes the tools that a frame registers through the experimental `WebMCP` browser API, `navigator.modelContext`. It lists the tools and calls them.
|
|
4
|
+
#
|
|
5
|
+
# Instances are accessed through [`property: Frame.webmcp`]. [`property: Page.webmcp`] is the instance of the main frame.
|
|
6
|
+
#
|
|
7
|
+
# **NOTE**: WebMCP is an experimental browser feature. Chromium enables it with the `--enable-features=WebMCP` launch argument, Firefox with the `dom.modelcontext.enabled` and `dom.modelcontext.testing.enabled` preferences. WebKit does not implement it.
|
|
8
|
+
#
|
|
9
|
+
# Tool names, descriptions, input schemas and results are provided by the page, so treat them as untrusted input.
|
|
10
|
+
class WebMCP < PlaywrightApi
|
|
11
|
+
|
|
12
|
+
#
|
|
13
|
+
# Calls a tool registered by the frame and returns its result. The result is whatever the tool's `execute` function resolved to, typically an object with a `content` array. A result with `isError: true` is returned as is. The method throws when the tool is not registered or its `execute` function throws.
|
|
14
|
+
def call_tool(name, input: nil, timeout: nil)
|
|
15
|
+
wrap_impl(@impl.call_tool(unwrap_impl(name), input: unwrap_impl(input), timeout: unwrap_impl(timeout)))
|
|
16
|
+
end
|
|
17
|
+
|
|
18
|
+
#
|
|
19
|
+
# Returns the tools currently registered by the frame. Throws if the browser was launched without WebMCP support, see the note above for the launch options that enable it.
|
|
20
|
+
#
|
|
21
|
+
# [`property: Page.webmcp`] covers the main frame only, child frames list their tools through their own [`property: Frame.webmcp`].
|
|
22
|
+
def tools(timeout: nil)
|
|
23
|
+
wrap_impl(@impl.tools(timeout: unwrap_impl(timeout)))
|
|
24
|
+
end
|
|
25
|
+
end
|
|
26
|
+
end
|
|
@@ -64,13 +64,13 @@ module Playwright
|
|
|
64
64
|
end
|
|
65
65
|
|
|
66
66
|
# @nodoc
|
|
67
|
-
def
|
|
68
|
-
wrap_impl(@impl.
|
|
67
|
+
def context=(req)
|
|
68
|
+
wrap_impl(@impl.context=(unwrap_impl(req)))
|
|
69
69
|
end
|
|
70
70
|
|
|
71
71
|
# @nodoc
|
|
72
|
-
def
|
|
73
|
-
wrap_impl(@impl.
|
|
72
|
+
def page=(req)
|
|
73
|
+
wrap_impl(@impl.page=(unwrap_impl(req)))
|
|
74
74
|
end
|
|
75
75
|
|
|
76
76
|
# -- inherited from EventEmitter --
|
data/sig/playwright.rbs
CHANGED
|
@@ -150,7 +150,7 @@ module Playwright
|
|
|
150
150
|
def check: (String selector, ?force: bool, ?noWaitAfter: bool, ?position: Hash[untyped, untyped], ?scroll: ("auto" | "none"), ?strict: bool, ?timeout: Float, ?trial: bool) -> void
|
|
151
151
|
def child_frames: -> Array[untyped]
|
|
152
152
|
def click: (String selector, ?button: ("left" | "right" | "middle"), ?clickCount: Integer, ?delay: Float, ?force: bool, ?modifiers: Array[untyped], ?noWaitAfter: bool, ?position: Hash[untyped, untyped], ?scroll: ("auto" | "none"), ?strict: bool, ?timeout: Float, ?trial: bool) -> void
|
|
153
|
-
def content: -> String
|
|
153
|
+
def content: (?includeShadow: bool) -> String
|
|
154
154
|
def dblclick: (String selector, ?button: ("left" | "right" | "middle"), ?delay: Float, ?force: bool, ?modifiers: Array[untyped], ?noWaitAfter: bool, ?position: Hash[untyped, untyped], ?scroll: ("auto" | "none"), ?strict: bool, ?timeout: Float, ?trial: bool) -> void
|
|
155
155
|
def dispatch_event: (String selector, String type_, ?eventInit: untyped, ?strict: bool, ?timeout: Float) -> void
|
|
156
156
|
def drag_and_drop: (String source, String target, ?force: bool, ?noWaitAfter: bool, ?scroll: ("auto" | "none"), ?sourcePosition: Hash[untyped, untyped], ?steps: Integer, ?strict: bool, ?targetPosition: Hash[untyped, untyped], ?timeout: Float, ?trial: bool) -> void
|
|
@@ -207,6 +207,8 @@ module Playwright
|
|
|
207
207
|
def wait_for_selector: (String selector, ?state: ("attached" | "detached" | "visible" | "hidden"), ?strict: bool, ?timeout: Float) -> (nil | ElementHandle)
|
|
208
208
|
def wait_for_timeout: (Float timeout) -> void
|
|
209
209
|
def wait_for_url: ((String | Regexp | function) url, ?timeout: Float, ?waitUntil: ("load" | "domcontentloaded" | "networkidle" | "commit")) -> void
|
|
210
|
+
|
|
211
|
+
attr_reader webmcp: WebMCP
|
|
210
212
|
end
|
|
211
213
|
|
|
212
214
|
class Worker
|
|
@@ -273,7 +275,7 @@ module Playwright
|
|
|
273
275
|
def check: (String selector, ?force: bool, ?noWaitAfter: bool, ?position: Hash[untyped, untyped], ?scroll: ("auto" | "none"), ?strict: bool, ?timeout: Float, ?trial: bool) -> void
|
|
274
276
|
def click: (String selector, ?button: ("left" | "right" | "middle"), ?clickCount: Integer, ?delay: Float, ?force: bool, ?modifiers: Array[untyped], ?noWaitAfter: bool, ?position: Hash[untyped, untyped], ?scroll: ("auto" | "none"), ?strict: bool, ?timeout: Float, ?trial: bool) -> void
|
|
275
277
|
def close: (?reason: String, ?runBeforeUnload: bool) -> void
|
|
276
|
-
def content: -> String
|
|
278
|
+
def content: (?includeShadow: bool) -> String
|
|
277
279
|
def context: -> BrowserContext
|
|
278
280
|
def dblclick: (String selector, ?button: ("left" | "right" | "middle"), ?delay: Float, ?force: bool, ?modifiers: Array[untyped], ?noWaitAfter: bool, ?position: Hash[untyped, untyped], ?scroll: ("auto" | "none"), ?strict: bool, ?timeout: Float, ?trial: bool) -> void
|
|
279
281
|
def dispatch_event: (String selector, String type_, ?eventInit: untyped, ?strict: bool, ?timeout: Float) -> void
|
|
@@ -294,6 +296,7 @@ module Playwright
|
|
|
294
296
|
def get_by_alt_text: ((String | Regexp) text, ?exact: bool) -> Locator
|
|
295
297
|
def get_by_label: ((String | Regexp) text, ?exact: bool) -> Locator
|
|
296
298
|
def get_by_placeholder: ((String | Regexp) text, ?exact: bool) -> Locator
|
|
299
|
+
def get_by_ref: (String ref) -> Locator
|
|
297
300
|
def get_by_role: (("alert" | "alertdialog" | "application" | "article" | "banner" | "blockquote" | "button" | "caption" | "cell" | "checkbox" | "code" | "columnheader" | "combobox" | "complementary" | "contentinfo" | "definition" | "deletion" | "dialog" | "directory" | "document" | "emphasis" | "feed" | "figure" | "form" | "generic" | "grid" | "gridcell" | "group" | "heading" | "img" | "insertion" | "link" | "list" | "listbox" | "listitem" | "log" | "main" | "marquee" | "math" | "meter" | "menu" | "menubar" | "menuitem" | "menuitemcheckbox" | "menuitemradio" | "navigation" | "none" | "note" | "option" | "paragraph" | "presentation" | "progressbar" | "radio" | "radiogroup" | "region" | "row" | "rowgroup" | "rowheader" | "scrollbar" | "search" | "searchbox" | "separator" | "slider" | "spinbutton" | "status" | "strong" | "subscript" | "superscript" | "switch" | "tab" | "table" | "tablist" | "tabpanel" | "term" | "textbox" | "time" | "timer" | "toolbar" | "tooltip" | "tree" | "treegrid" | "treeitem") role, ?checked: bool, ?description: (String | Regexp), ?disabled: bool, ?exact: bool, ?expanded: bool, ?includeHidden: bool, ?level: Integer, ?name: (String | Regexp), ?pressed: bool, ?selected: bool) -> Locator
|
|
298
301
|
def get_by_test_id: ((String | Regexp) testId) -> Locator
|
|
299
302
|
def get_by_testid: ((String | Regexp) testId) -> Locator
|
|
@@ -382,6 +385,7 @@ module Playwright
|
|
|
382
385
|
attr_reader request: APIRequestContext
|
|
383
386
|
attr_reader screencast: untyped
|
|
384
387
|
attr_reader touchscreen: Touchscreen
|
|
388
|
+
attr_reader webmcp: WebMCP
|
|
385
389
|
end
|
|
386
390
|
|
|
387
391
|
class BrowserContext
|
|
@@ -439,8 +443,8 @@ module Playwright
|
|
|
439
443
|
def contexts: -> Array[untyped]
|
|
440
444
|
def connected?: -> bool
|
|
441
445
|
def new_browser_cdp_session: -> CDPSession
|
|
442
|
-
def new_context: (?acceptDownloads: bool, ?baseURL: String, ?bypassCSP: bool, ?clientCertificates: Array[untyped], ?colorScheme: ("light" | "dark" | "no-preference" | "null"), ?contrast: ("no-preference" | "more" | "null"), ?deviceScaleFactor: Float, ?extraHTTPHeaders: Hash[untyped, untyped], ?forcedColors: ("active" | "none" | "null"), ?geolocation: Hash[untyped, untyped], ?hasTouch: bool, ?httpCredentials: (Hash[untyped, untyped] | Array[untyped]), ?ignoreHTTPSErrors: bool, ?isMobile: bool, ?javaScriptEnabled: bool, ?locale: String, ?noViewport: bool, ?offline: bool, ?permissions: Array[untyped], ?proxy: Hash[untyped, untyped], ?record_har_content: ("omit" | "embed" | "attach"), ?record_har_mode: ("full" | "minimal"), ?record_har_omit_content: bool, ?record_har_path: (String | File), ?record_har_url_filter: (String | Regexp), ?record_video_dir: (String | File), ?record_video_size: Hash[untyped, untyped], ?reducedMotion: ("reduce" | "no-preference" | "null"), ?screen: Hash[untyped, untyped], ?serviceWorkers: ("allow" | "block"), ?storageState: ((String | File) | Hash[untyped, untyped]), ?strictSelectors: bool, ?timezoneId: String, ?userAgent: String, ?viewport: (nil | Hash[untyped, untyped])) ?{ (BrowserContext) -> untyped } -> BrowserContext
|
|
443
|
-
def new_page: (?acceptDownloads: bool, ?baseURL: String, ?bypassCSP: bool, ?clientCertificates: Array[untyped], ?colorScheme: ("light" | "dark" | "no-preference" | "null"), ?contrast: ("no-preference" | "more" | "null"), ?deviceScaleFactor: Float, ?extraHTTPHeaders: Hash[untyped, untyped], ?forcedColors: ("active" | "none" | "null"), ?geolocation: Hash[untyped, untyped], ?hasTouch: bool, ?httpCredentials: (Hash[untyped, untyped] | Array[untyped]), ?ignoreHTTPSErrors: bool, ?isMobile: bool, ?javaScriptEnabled: bool, ?locale: String, ?noViewport: bool, ?offline: bool, ?permissions: Array[untyped], ?proxy: Hash[untyped, untyped], ?record_har_content: ("omit" | "embed" | "attach"), ?record_har_mode: ("full" | "minimal"), ?record_har_omit_content: bool, ?record_har_path: (String | File), ?record_har_url_filter: (String | Regexp), ?record_video_dir: (String | File), ?record_video_size: Hash[untyped, untyped], ?reducedMotion: ("reduce" | "no-preference" | "null"), ?screen: Hash[untyped, untyped], ?serviceWorkers: ("allow" | "block"), ?storageState: ((String | File) | Hash[untyped, untyped]), ?strictSelectors: bool, ?timezoneId: String, ?userAgent: String, ?viewport: (nil | Hash[untyped, untyped])) ?{ (Page) -> untyped } -> Page
|
|
446
|
+
def new_context: (?acceptDownloads: bool, ?baseURL: String, ?bypassCSP: bool, ?clientCertificates: Array[untyped], ?colorScheme: ("light" | "dark" | "no-preference" | "null"), ?contrast: ("no-preference" | "more" | "null"), ?deviceScaleFactor: Float, ?extraHTTPHeaders: Hash[untyped, untyped], ?forcedColors: ("active" | "none" | "null"), ?geolocation: Hash[untyped, untyped], ?hasTouch: bool, ?httpCredentials: (Hash[untyped, untyped] | Array[untyped]), ?ignoreHTTPSErrors: bool, ?isMobile: bool, ?javaScriptEnabled: bool, ?locale: String, ?noViewport: bool, ?offline: bool, ?permissions: Array[untyped], ?proxy: Hash[untyped, untyped], ?record_har_content: ("omit" | "embed" | "attach"), ?record_har_mode: ("full" | "minimal"), ?record_har_omit_content: bool, ?record_har_path: (String | File), ?record_har_url_filter: (String | Regexp), ?record_video_dir: (String | File), ?record_video_fps: Integer, ?record_video_size: Hash[untyped, untyped], ?reducedMotion: ("reduce" | "no-preference" | "null"), ?screen: Hash[untyped, untyped], ?serviceWorkers: ("allow" | "block"), ?storageState: ((String | File) | Hash[untyped, untyped]), ?strictSelectors: bool, ?timezoneId: String, ?userAgent: String, ?viewport: (nil | Hash[untyped, untyped])) ?{ (BrowserContext) -> untyped } -> BrowserContext
|
|
447
|
+
def new_page: (?acceptDownloads: bool, ?baseURL: String, ?bypassCSP: bool, ?clientCertificates: Array[untyped], ?colorScheme: ("light" | "dark" | "no-preference" | "null"), ?contrast: ("no-preference" | "more" | "null"), ?deviceScaleFactor: Float, ?extraHTTPHeaders: Hash[untyped, untyped], ?forcedColors: ("active" | "none" | "null"), ?geolocation: Hash[untyped, untyped], ?hasTouch: bool, ?httpCredentials: (Hash[untyped, untyped] | Array[untyped]), ?ignoreHTTPSErrors: bool, ?isMobile: bool, ?javaScriptEnabled: bool, ?locale: String, ?noViewport: bool, ?offline: bool, ?permissions: Array[untyped], ?proxy: Hash[untyped, untyped], ?record_har_content: ("omit" | "embed" | "attach"), ?record_har_mode: ("full" | "minimal"), ?record_har_omit_content: bool, ?record_har_path: (String | File), ?record_har_url_filter: (String | Regexp), ?record_video_dir: (String | File), ?record_video_fps: Integer, ?record_video_size: Hash[untyped, untyped], ?reducedMotion: ("reduce" | "no-preference" | "null"), ?screen: Hash[untyped, untyped], ?serviceWorkers: ("allow" | "block"), ?storageState: ((String | File) | Hash[untyped, untyped]), ?strictSelectors: bool, ?timezoneId: String, ?userAgent: String, ?viewport: (nil | Hash[untyped, untyped])) ?{ (Page) -> untyped } -> Page
|
|
444
448
|
def bind: (String title, ?host: String, ?port: Integer, ?workspaceDir: String) -> Hash[untyped, untyped]
|
|
445
449
|
def start_tracing: (?page: Page, ?categories: Array[untyped], ?path: (String | File), ?screenshots: bool) -> void
|
|
446
450
|
def stop_tracing: -> String
|
|
@@ -453,7 +457,7 @@ module Playwright
|
|
|
453
457
|
def connect_over_cdp: (String endpointURL, ?artifactsDir: (String | File), ?headers: Hash[untyped, untyped], ?isLocal: bool, ?noDefaults: bool, ?slowMo: Float, ?timeout: Float) ?{ (untyped) -> untyped } -> Browser
|
|
454
458
|
def executable_path: -> String
|
|
455
459
|
def launch: (?args: Array[untyped], ?artifactsDir: (String | File), ?channel: String, ?chromiumSandbox: bool, ?downloadsPath: (String | File), ?env: Hash[untyped, untyped], ?executablePath: (String | File), ?firefoxUserPrefs: Hash[untyped, untyped], ?handleSIGHUP: bool, ?handleSIGINT: bool, ?handleSIGTERM: bool, ?headless: bool, ?ignoreDefaultArgs: (bool | Array[untyped]), ?proxy: Hash[untyped, untyped], ?slowMo: Float, ?timeout: Float, ?tracesDir: (String | File)) ?{ (Browser) -> untyped } -> Browser
|
|
456
|
-
def launch_persistent_context: ((String | File) userDataDir, ?acceptDownloads: bool, ?args: Array[untyped], ?artifactsDir: (String | File), ?baseURL: String, ?bypassCSP: bool, ?channel: String, ?chromiumSandbox: bool, ?clientCertificates: Array[untyped], ?colorScheme: ("light" | "dark" | "no-preference" | "null"), ?contrast: ("no-preference" | "more" | "null"), ?deviceScaleFactor: Float, ?downloadsPath: (String | File), ?env: Hash[untyped, untyped], ?executablePath: (String | File), ?extraHTTPHeaders: Hash[untyped, untyped], ?firefoxUserPrefs: Hash[untyped, untyped], ?forcedColors: ("active" | "none" | "null"), ?geolocation: Hash[untyped, untyped], ?handleSIGHUP: bool, ?handleSIGINT: bool, ?handleSIGTERM: bool, ?hasTouch: bool, ?headless: bool, ?httpCredentials: (Hash[untyped, untyped] | Array[untyped]), ?ignoreDefaultArgs: (bool | Array[untyped]), ?ignoreHTTPSErrors: bool, ?isMobile: bool, ?javaScriptEnabled: bool, ?locale: String, ?noViewport: bool, ?offline: bool, ?permissions: Array[untyped], ?proxy: Hash[untyped, untyped], ?record_har_content: ("omit" | "embed" | "attach"), ?record_har_mode: ("full" | "minimal"), ?record_har_omit_content: bool, ?record_har_path: (String | File), ?record_har_url_filter: (String | Regexp), ?record_video_dir: (String | File), ?record_video_size: Hash[untyped, untyped], ?reducedMotion: ("reduce" | "no-preference" | "null"), ?screen: Hash[untyped, untyped], ?serviceWorkers: ("allow" | "block"), ?slowMo: Float, ?strictSelectors: bool, ?timeout: Float, ?timezoneId: String, ?tracesDir: (String | File), ?userAgent: String, ?viewport: (nil | Hash[untyped, untyped])) ?{ (untyped) -> untyped } -> BrowserContext
|
|
460
|
+
def launch_persistent_context: ((String | File) userDataDir, ?acceptDownloads: bool, ?args: Array[untyped], ?artifactsDir: (String | File), ?baseURL: String, ?bypassCSP: bool, ?channel: String, ?chromiumSandbox: bool, ?clientCertificates: Array[untyped], ?colorScheme: ("light" | "dark" | "no-preference" | "null"), ?contrast: ("no-preference" | "more" | "null"), ?deviceScaleFactor: Float, ?downloadsPath: (String | File), ?env: Hash[untyped, untyped], ?executablePath: (String | File), ?extraHTTPHeaders: Hash[untyped, untyped], ?firefoxUserPrefs: Hash[untyped, untyped], ?forcedColors: ("active" | "none" | "null"), ?geolocation: Hash[untyped, untyped], ?handleSIGHUP: bool, ?handleSIGINT: bool, ?handleSIGTERM: bool, ?hasTouch: bool, ?headless: bool, ?httpCredentials: (Hash[untyped, untyped] | Array[untyped]), ?ignoreDefaultArgs: (bool | Array[untyped]), ?ignoreHTTPSErrors: bool, ?isMobile: bool, ?javaScriptEnabled: bool, ?locale: String, ?noViewport: bool, ?offline: bool, ?permissions: Array[untyped], ?proxy: Hash[untyped, untyped], ?record_har_content: ("omit" | "embed" | "attach"), ?record_har_mode: ("full" | "minimal"), ?record_har_omit_content: bool, ?record_har_path: (String | File), ?record_har_url_filter: (String | Regexp), ?record_video_dir: (String | File), ?record_video_fps: Integer, ?record_video_size: Hash[untyped, untyped], ?reducedMotion: ("reduce" | "no-preference" | "null"), ?screen: Hash[untyped, untyped], ?serviceWorkers: ("allow" | "block"), ?slowMo: Float, ?strictSelectors: bool, ?timeout: Float, ?timezoneId: String, ?tracesDir: (String | File), ?userAgent: String, ?viewport: (nil | Hash[untyped, untyped])) ?{ (untyped) -> untyped } -> BrowserContext
|
|
457
461
|
def name: -> String
|
|
458
462
|
end
|
|
459
463
|
|
|
@@ -467,8 +471,8 @@ module Playwright
|
|
|
467
471
|
end
|
|
468
472
|
|
|
469
473
|
class Tracing
|
|
470
|
-
def start: (?ariaSnapshots: bool, ?live: bool, ?name: String, ?screenshots: bool, ?screenSnapshots: bool, ?snapshots: bool, ?sources: bool, ?title: String) ->
|
|
471
|
-
def start_chunk: (?name: String, ?title: String) ->
|
|
474
|
+
def start: (?ariaSnapshots: bool, ?live: bool, ?name: String, ?screenshots: bool, ?screenSnapshots: bool, ?snapshots: bool, ?sources: bool, ?title: String) -> untyped
|
|
475
|
+
def start_chunk: (?name: String, ?title: String) -> untyped
|
|
472
476
|
def start_har: ((String | File) path, ?content: ("omit" | "embed" | "attach"), ?mode: ("full" | "minimal"), ?urlFilter: (String | Regexp)) -> untyped
|
|
473
477
|
def group: (String name, ?location: Hash[untyped, untyped]) -> untyped
|
|
474
478
|
def group_end: -> void
|
|
@@ -551,6 +555,7 @@ module Playwright
|
|
|
551
555
|
def visible: -> Locator
|
|
552
556
|
def wait_for: (?state: ("attached" | "detached" | "visible" | "hidden"), ?timeout: Float) -> void
|
|
553
557
|
def wait_for_function: (String expression, ?arg: untyped, ?timeout: Float) -> void
|
|
558
|
+
def within: (Locator locator) -> Locator
|
|
554
559
|
end
|
|
555
560
|
|
|
556
561
|
class FrameLocator
|
|
@@ -587,6 +592,9 @@ module Playwright
|
|
|
587
592
|
end
|
|
588
593
|
|
|
589
594
|
class APIRequestContext
|
|
595
|
+
def add_cookies: (Array[untyped] cookies) -> void
|
|
596
|
+
def clear_cookies: (?domain: (String | Regexp), ?name: (String | Regexp), ?path: (String | Regexp)) -> void
|
|
597
|
+
def cookies: (?urls: (String | Array[untyped])) -> Array[untyped]
|
|
590
598
|
def delete: (String url, ?data: (String | String | untyped), ?failOnStatusCode: bool, ?form: (Hash[untyped, untyped] | untyped), ?headers: Hash[untyped, untyped], ?ignoreHTTPSErrors: bool, ?maxRedirects: Integer, ?maxRetries: Integer, ?multipart: (Hash[untyped, untyped] | untyped), ?params: (Hash[untyped, untyped] | String), ?timeout: Float) -> APIResponse
|
|
591
599
|
def dispose: (?reason: String) -> void
|
|
592
600
|
def fetch: ((String | Request) urlOrRequest, ?data: (String | String | untyped), ?failOnStatusCode: bool, ?form: (Hash[untyped, untyped] | untyped), ?headers: Hash[untyped, untyped], ?ignoreHTTPSErrors: bool, ?maxRedirects: Integer, ?maxRetries: Integer, ?method: String, ?multipart: (Hash[untyped, untyped] | untyped), ?params: (Hash[untyped, untyped] | String), ?timeout: Float) -> APIResponse
|
|
@@ -677,10 +685,15 @@ module Playwright
|
|
|
677
685
|
|
|
678
686
|
class Credentials
|
|
679
687
|
def install: -> void
|
|
680
|
-
def create: (String rpId, ?id: String, ?privateKey: String, ?publicKey: String, ?userHandle: String) -> Hash[untyped, untyped]
|
|
688
|
+
def create: (String rpId, ?id: String, ?privateKey: String, ?publicKey: String, ?signCount: Integer, ?userHandle: String) -> Hash[untyped, untyped]
|
|
681
689
|
def delete: (String id) -> void
|
|
682
690
|
def get: (?id: String, ?rpId: String) -> Array[untyped]
|
|
683
691
|
end
|
|
684
692
|
|
|
693
|
+
class WebMCP
|
|
694
|
+
def call_tool: (String name, ?input: untyped, ?timeout: Float) -> untyped
|
|
695
|
+
def tools: (?timeout: Float) -> Array[untyped]
|
|
696
|
+
end
|
|
697
|
+
|
|
685
698
|
def self.create: (playwright_cli_executable_path: String) { (Playwright) -> void } -> void
|
|
686
699
|
end
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: playwright-ruby-client
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 1.
|
|
4
|
+
version: 1.64.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- YusukeIwaki
|
|
@@ -267,6 +267,7 @@ files:
|
|
|
267
267
|
- documentation/docs/api/selectors.md
|
|
268
268
|
- documentation/docs/api/touchscreen.md
|
|
269
269
|
- documentation/docs/api/tracing.md
|
|
270
|
+
- documentation/docs/api/web_mcp.md
|
|
270
271
|
- documentation/docs/api/web_socket.md
|
|
271
272
|
- documentation/docs/api/web_storage.md
|
|
272
273
|
- documentation/docs/api/worker.md
|
|
@@ -382,6 +383,7 @@ files:
|
|
|
382
383
|
- lib/playwright/version.rb
|
|
383
384
|
- lib/playwright/video.rb
|
|
384
385
|
- lib/playwright/waiter.rb
|
|
386
|
+
- lib/playwright/web_mcp_impl.rb
|
|
385
387
|
- lib/playwright/web_socket_client.rb
|
|
386
388
|
- lib/playwright/web_socket_transport.rb
|
|
387
389
|
- lib/playwright/web_storage_impl.rb
|
|
@@ -415,6 +417,7 @@ files:
|
|
|
415
417
|
- lib/playwright_api/selectors.rb
|
|
416
418
|
- lib/playwright_api/touchscreen.rb
|
|
417
419
|
- lib/playwright_api/tracing.rb
|
|
420
|
+
- lib/playwright_api/web_mcp.rb
|
|
418
421
|
- lib/playwright_api/web_socket.rb
|
|
419
422
|
- lib/playwright_api/web_storage.rb
|
|
420
423
|
- lib/playwright_api/worker.rb
|
|
@@ -443,5 +446,5 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
443
446
|
requirements: []
|
|
444
447
|
rubygems_version: 3.6.9
|
|
445
448
|
specification_version: 4
|
|
446
|
-
summary: The Ruby binding of playwright driver 1.
|
|
449
|
+
summary: The Ruby binding of playwright driver 1.64.0
|
|
447
450
|
test_files: []
|