diff --git a/README.md b/README.md index 0525b5e1..1b2e0344 100644 --- a/README.md +++ b/README.md @@ -11,7 +11,7 @@ Playwright is a Java library to automate [Chromium](https://www.chromium.org/Hom | | Linux | macOS | Windows | | :--- | :---: | :---: | :---: | -| Chromium 127.0.6533.5 | :white_check_mark: | :white_check_mark: | :white_check_mark: | +| Chromium 127.0.6533.17 | :white_check_mark: | :white_check_mark: | :white_check_mark: | | WebKit 17.4 | ✅ | ✅ | ✅ | | Firefox 127.0 | :white_check_mark: | :white_check_mark: | :white_check_mark: | diff --git a/playwright/src/main/java/com/microsoft/playwright/BrowserContext.java b/playwright/src/main/java/com/microsoft/playwright/BrowserContext.java index fc2d28db..b566795a 100644 --- a/playwright/src/main/java/com/microsoft/playwright/BrowserContext.java +++ b/playwright/src/main/java/com/microsoft/playwright/BrowserContext.java @@ -279,14 +279,12 @@ public interface BrowserContext extends AutoCloseable { } class ExposeBindingOptions { /** - * Whether to pass the argument as a handle, instead of passing by value. When passing a handle, only one argument is - * supported. When passing by value, multiple arguments are supported. + * @deprecated This option will be removed in the future. */ public Boolean handle; /** - * Whether to pass the argument as a handle, instead of passing by value. When passing a handle, only one argument is - * supported. When passing by value, multiple arguments are supported. + * @deprecated This option will be removed in the future. */ public ExposeBindingOptions setHandle(boolean handle) { this.handle = handle; @@ -723,21 +721,6 @@ public interface BrowserContext extends AutoCloseable { * } * } * - *

An example of passing an element handle: - *

{@code
-   * context.exposeBinding("clicked", (source, args) -> {
-   *   ElementHandle element = (ElementHandle) args[0];
-   *   System.out.println(element.textContent());
-   *   return null;
-   * }, new BrowserContext.ExposeBindingOptions().setHandle(true));
-   * page.setContent("" +
-   *   "\n" +
-   *   "
Click me
\n" + - * "
Or click me
\n"); - * }
- * * @param name Name of the function on the window object. * @param callback Callback function that will be called in the Playwright's context. * @since v1.8 @@ -785,21 +768,6 @@ public interface BrowserContext extends AutoCloseable { * } * } * - *

An example of passing an element handle: - *

{@code
-   * context.exposeBinding("clicked", (source, args) -> {
-   *   ElementHandle element = (ElementHandle) args[0];
-   *   System.out.println(element.textContent());
-   *   return null;
-   * }, new BrowserContext.ExposeBindingOptions().setHandle(true));
-   * page.setContent("" +
-   *   "\n" +
-   *   "
Click me
\n" + - * "
Or click me
\n"); - * }
- * * @param name Name of the function on the window object. * @param callback Callback function that will be called in the Playwright's context. * @since v1.8 diff --git a/playwright/src/main/java/com/microsoft/playwright/Clock.java b/playwright/src/main/java/com/microsoft/playwright/Clock.java index 9d2c2a7e..668dfaab 100644 --- a/playwright/src/main/java/com/microsoft/playwright/Clock.java +++ b/playwright/src/main/java/com/microsoft/playwright/Clock.java @@ -169,7 +169,8 @@ public interface Clock { * *

Usage *

{@code
-   * page.clock().pauseAt(Instant.parse("2020-02-02"));
+   * SimpleDateFormat format = new SimpleDateFormat("yyy-MM-dd");
+   * page.clock().pauseAt(format.parse("2020-02-02"));
    * page.clock().pauseAt("2020-02-02");
    * }
* @@ -187,7 +188,8 @@ public interface Clock { * *

Usage *

{@code
-   * page.clock().pauseAt(Instant.parse("2020-02-02"));
+   * SimpleDateFormat format = new SimpleDateFormat("yyy-MM-dd");
+   * page.clock().pauseAt(format.parse("2020-02-02"));
    * page.clock().pauseAt("2020-02-02");
    * }
* @@ -205,7 +207,8 @@ public interface Clock { * *

Usage *

{@code
-   * page.clock().pauseAt(Instant.parse("2020-02-02"));
+   * SimpleDateFormat format = new SimpleDateFormat("yyy-MM-dd");
+   * page.clock().pauseAt(format.parse("2020-02-02"));
    * page.clock().pauseAt("2020-02-02");
    * }
* @@ -223,8 +226,8 @@ public interface Clock { * *

Usage *

{@code
-   * page.clock().setFixedTime(Instant.now());
-   * page.clock().setFixedTime(Instant.parse("2020-02-02"));
+   * page.clock().setFixedTime(new Date());
+   * page.clock().setFixedTime(new SimpleDateFormat("yyy-MM-dd").parse("2020-02-02"));
    * page.clock().setFixedTime("2020-02-02");
    * }
* @@ -237,8 +240,8 @@ public interface Clock { * *

Usage *

{@code
-   * page.clock().setFixedTime(Instant.now());
-   * page.clock().setFixedTime(Instant.parse("2020-02-02"));
+   * page.clock().setFixedTime(new Date());
+   * page.clock().setFixedTime(new SimpleDateFormat("yyy-MM-dd").parse("2020-02-02"));
    * page.clock().setFixedTime("2020-02-02");
    * }
* @@ -251,8 +254,8 @@ public interface Clock { * *

Usage *

{@code
-   * page.clock().setFixedTime(Instant.now());
-   * page.clock().setFixedTime(Instant.parse("2020-02-02"));
+   * page.clock().setFixedTime(new Date());
+   * page.clock().setFixedTime(new SimpleDateFormat("yyy-MM-dd").parse("2020-02-02"));
    * page.clock().setFixedTime("2020-02-02");
    * }
* @@ -265,8 +268,8 @@ public interface Clock { * *

Usage *

{@code
-   * page.clock().setSystemTime(Instant.now());
-   * page.clock().setSystemTime(Instant.parse("2020-02-02"));
+   * page.clock().setSystemTime(new Date());
+   * page.clock().setSystemTime(new SimpleDateFormat("yyy-MM-dd").parse("2020-02-02"));
    * page.clock().setSystemTime("2020-02-02");
    * }
* @@ -278,8 +281,8 @@ public interface Clock { * *

Usage *

{@code
-   * page.clock().setSystemTime(Instant.now());
-   * page.clock().setSystemTime(Instant.parse("2020-02-02"));
+   * page.clock().setSystemTime(new Date());
+   * page.clock().setSystemTime(new SimpleDateFormat("yyy-MM-dd").parse("2020-02-02"));
    * page.clock().setSystemTime("2020-02-02");
    * }
* @@ -291,8 +294,8 @@ public interface Clock { * *

Usage *

{@code
-   * page.clock().setSystemTime(Instant.now());
-   * page.clock().setSystemTime(Instant.parse("2020-02-02"));
+   * page.clock().setSystemTime(new Date());
+   * page.clock().setSystemTime(new SimpleDateFormat("yyy-MM-dd").parse("2020-02-02"));
    * page.clock().setSystemTime("2020-02-02");
    * }
* diff --git a/playwright/src/main/java/com/microsoft/playwright/Page.java b/playwright/src/main/java/com/microsoft/playwright/Page.java index 9b08a92e..d4010991 100644 --- a/playwright/src/main/java/com/microsoft/playwright/Page.java +++ b/playwright/src/main/java/com/microsoft/playwright/Page.java @@ -1042,14 +1042,12 @@ public interface Page extends AutoCloseable { } class ExposeBindingOptions { /** - * Whether to pass the argument as a handle, instead of passing by value. When passing a handle, only one argument is - * supported. When passing by value, multiple arguments are supported. + * @deprecated This option will be removed in the future. */ public Boolean handle; /** - * Whether to pass the argument as a handle, instead of passing by value. When passing a handle, only one argument is - * supported. When passing by value, multiple arguments are supported. + * @deprecated This option will be removed in the future. */ public ExposeBindingOptions setHandle(boolean handle) { this.handle = handle; @@ -4629,21 +4627,6 @@ public interface Page extends AutoCloseable { * } * } * - *

An example of passing an element handle: - *

{@code
-   * page.exposeBinding("clicked", (source, args) -> {
-   *   ElementHandle element = (ElementHandle) args[0];
-   *   System.out.println(element.textContent());
-   *   return null;
-   * }, new Page.ExposeBindingOptions().setHandle(true));
-   * page.setContent("" +
-   *   "\n" +
-   *   "
Click me
\n" + - * "
Or click me
\n"); - * }
- * * @param name Name of the function on the window object. * @param callback Callback function that will be called in the Playwright's context. * @since v1.8 @@ -4694,21 +4677,6 @@ public interface Page extends AutoCloseable { * } * } * - *

An example of passing an element handle: - *

{@code
-   * page.exposeBinding("clicked", (source, args) -> {
-   *   ElementHandle element = (ElementHandle) args[0];
-   *   System.out.println(element.textContent());
-   *   return null;
-   * }, new Page.ExposeBindingOptions().setHandle(true));
-   * page.setContent("" +
-   *   "\n" +
-   *   "
Click me
\n" + - * "
Or click me
\n"); - * }
- * * @param name Name of the function on the window object. * @param callback Callback function that will be called in the Playwright's context. * @since v1.8 diff --git a/scripts/DRIVER_VERSION b/scripts/DRIVER_VERSION index a0fdd66f..50aceaa7 100644 --- a/scripts/DRIVER_VERSION +++ b/scripts/DRIVER_VERSION @@ -1 +1 @@ -1.45.0-beta-1718733727000 +1.45.0