effect-playwright 0.2.0 → 0.2.2

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.
@@ -1,4 +1,4 @@
1
- import { d as PlaywrightPageService, o as PlaywrightBrowser, s as PlaywrightBrowserService, v as PlaywrightFrameService, x as PlaywrightError } from "../index-K6LNMeXC.mjs";
1
+ import { S as PlaywrightError, d as PlaywrightPageService, o as PlaywrightBrowser, s as PlaywrightBrowserService, y as PlaywrightFrameService } from "../index-BdIazBpL.mjs";
2
2
  import { Context, Effect, Layer, Stream } from "effect";
3
3
  import { BrowserType, LaunchOptions } from "playwright-core";
4
4
  import { Scope as Scope$1 } from "effect/Scope";
@@ -16,7 +16,7 @@ declare const allPages: (browser: PlaywrightBrowserService) => Effect.Effect<Pla
16
16
  * Returns all frames in the browser from all pages in all contexts.
17
17
  * @category util
18
18
  */
19
- declare const allFrames: (browser: PlaywrightBrowserService) => Effect.Effect<(readonly PlaywrightFrameService[])[], PlaywrightError, never>;
19
+ declare const allFrames: (browser: PlaywrightBrowserService) => Effect.Effect<PlaywrightFrameService[], PlaywrightError, never>;
20
20
  /**
21
21
  * Returns a stream of all framenavigated events for all current and future pages in the browser.
22
22
  * In all current contexts (but not future contexts).
@@ -1,5 +1,5 @@
1
1
  import { t as __exportAll } from "../chunk-BiucMVzj.mjs";
2
- import { n as PlaywrightBrowser, t as Playwright } from "../src-Bf0XqK7M.mjs";
2
+ import { n as PlaywrightBrowser, t as Playwright } from "../src-BBJfAuBn.mjs";
3
3
  import { Array, Context, Effect, Layer, Stream, pipe } from "effect";
4
4
 
5
5
  //#region src/experimental/browser-utils.ts
@@ -17,7 +17,7 @@ const allPages = (browser) => browser.contexts.pipe(Effect.flatMap((contexts) =>
17
17
  * Returns all frames in the browser from all pages in all contexts.
18
18
  * @category util
19
19
  */
20
- const allFrames = (browser) => allPages(browser).pipe(Effect.flatMap((pages) => Effect.all(pages.map((page) => page.frames))));
20
+ const allFrames = (browser) => allPages(browser).pipe(Effect.flatMap((pages) => Effect.all(pages.map((page) => page.frames))), Effect.map(Array.flatten));
21
21
  /**
22
22
  * Returns a stream of all framenavigated events for all current and future pages in the browser.
23
23
  * In all current contexts (but not future contexts).
@@ -1,7 +1,7 @@
1
1
  import { Context, Effect, Layer, Option, Scope, Stream } from "effect";
2
2
  import { Browser, BrowserContext, BrowserType, ConnectOverCDPOptions, ConsoleMessage, Dialog, Download, ElementHandle, FileChooser, Frame, JSHandle, Locator, Page, Request, Response, WebError, WebSocket, Worker, chromium } from "playwright-core";
3
3
  import { Scope as Scope$1 } from "effect/Scope";
4
- import * as effect_Types0 from "effect/Types";
4
+ import * as effect_Types5 from "effect/Types";
5
5
  import * as effect_Cause0 from "effect/Cause";
6
6
 
7
7
  //#region src/errors.d.ts
@@ -13,7 +13,7 @@ import * as effect_Cause0 from "effect/Cause";
13
13
  * @since 0.1.0
14
14
  */
15
15
  type PlaywrightErrorReason = "Timeout" | "Unknown";
16
- declare const PlaywrightError_base: new <A extends Record<string, any> = {}>(args: effect_Types0.Equals<A, {}> extends true ? void : { readonly [P in keyof A as P extends "_tag" ? never : P]: A[P] }) => effect_Cause0.YieldableError & {
16
+ declare const PlaywrightError_base: new <A extends Record<string, any> = {}>(args: effect_Types5.Equals<A, {}> extends true ? void : { readonly [P in keyof A as P extends "_tag" ? never : P]: A[P] }) => effect_Cause0.YieldableError & {
17
17
  readonly _tag: "PlaywrightError";
18
18
  } & Readonly<A>;
19
19
  /**
@@ -332,7 +332,7 @@ declare class PlaywrightFrame extends PlaywrightFrame_base {
332
332
  }
333
333
  //#endregion
334
334
  //#region src/common.d.ts
335
- declare const PlaywrightRequest_base: new <A extends Record<string, any> = {}>(args: effect_Types0.Equals<A, {}> extends true ? void : { readonly [P in keyof A as P extends "_tag" ? never : P]: A[P] }) => Readonly<A> & {
335
+ declare const PlaywrightRequest_base: new <A extends Record<string, any> = {}>(args: effect_Types5.Equals<A, {}> extends true ? void : { readonly [P in keyof A as P extends "_tag" ? never : P]: A[P] }) => Readonly<A> & {
336
336
  readonly _tag: "PlaywrightRequest";
337
337
  };
338
338
  /**
@@ -362,7 +362,7 @@ declare class PlaywrightRequest extends PlaywrightRequest_base<{
362
362
  }> {
363
363
  static make(request: Request): PlaywrightRequest;
364
364
  }
365
- declare const PlaywrightResponse_base: new <A extends Record<string, any> = {}>(args: effect_Types0.Equals<A, {}> extends true ? void : { readonly [P in keyof A as P extends "_tag" ? never : P]: A[P] }) => Readonly<A> & {
365
+ declare const PlaywrightResponse_base: new <A extends Record<string, any> = {}>(args: effect_Types5.Equals<A, {}> extends true ? void : { readonly [P in keyof A as P extends "_tag" ? never : P]: A[P] }) => Readonly<A> & {
366
366
  readonly _tag: "PlaywrightResponse";
367
367
  };
368
368
  /**
@@ -391,7 +391,7 @@ declare class PlaywrightResponse extends PlaywrightResponse_base<{
391
391
  }> {
392
392
  static make(response: Response): PlaywrightResponse;
393
393
  }
394
- declare const PlaywrightWorker_base: new <A extends Record<string, any> = {}>(args: effect_Types0.Equals<A, {}> extends true ? void : { readonly [P in keyof A as P extends "_tag" ? never : P]: A[P] }) => Readonly<A> & {
394
+ declare const PlaywrightWorker_base: new <A extends Record<string, any> = {}>(args: effect_Types5.Equals<A, {}> extends true ? void : { readonly [P in keyof A as P extends "_tag" ? never : P]: A[P] }) => Readonly<A> & {
395
395
  readonly _tag: "PlaywrightWorker";
396
396
  };
397
397
  /**
@@ -404,7 +404,7 @@ declare class PlaywrightWorker extends PlaywrightWorker_base<{
404
404
  }> {
405
405
  static make(worker: Worker): PlaywrightWorker;
406
406
  }
407
- declare const PlaywrightDialog_base: new <A extends Record<string, any> = {}>(args: effect_Types0.Equals<A, {}> extends true ? void : { readonly [P in keyof A as P extends "_tag" ? never : P]: A[P] }) => Readonly<A> & {
407
+ declare const PlaywrightDialog_base: new <A extends Record<string, any> = {}>(args: effect_Types5.Equals<A, {}> extends true ? void : { readonly [P in keyof A as P extends "_tag" ? never : P]: A[P] }) => Readonly<A> & {
408
408
  readonly _tag: "PlaywrightDialog";
409
409
  };
410
410
  /**
@@ -421,7 +421,7 @@ declare class PlaywrightDialog extends PlaywrightDialog_base<{
421
421
  }> {
422
422
  static make(dialog: Dialog): PlaywrightDialog;
423
423
  }
424
- declare const PlaywrightFileChooser_base: new <A extends Record<string, any> = {}>(args: effect_Types0.Equals<A, {}> extends true ? void : { readonly [P in keyof A as P extends "_tag" ? never : P]: A[P] }) => Readonly<A> & {
424
+ declare const PlaywrightFileChooser_base: new <A extends Record<string, any> = {}>(args: effect_Types5.Equals<A, {}> extends true ? void : { readonly [P in keyof A as P extends "_tag" ? never : P]: A[P] }) => Readonly<A> & {
425
425
  readonly _tag: "PlaywrightFileChooser";
426
426
  };
427
427
  /**
@@ -436,7 +436,7 @@ declare class PlaywrightFileChooser extends PlaywrightFileChooser_base<{
436
436
  }> {
437
437
  static make(fileChooser: FileChooser): PlaywrightFileChooser;
438
438
  }
439
- declare const PlaywrightDownload_base: new <A extends Record<string, any> = {}>(args: effect_Types0.Equals<A, {}> extends true ? void : { readonly [P in keyof A as P extends "_tag" ? never : P]: A[P] }) => Readonly<A> & {
439
+ declare const PlaywrightDownload_base: new <A extends Record<string, any> = {}>(args: effect_Types5.Equals<A, {}> extends true ? void : { readonly [P in keyof A as P extends "_tag" ? never : P]: A[P] }) => Readonly<A> & {
440
440
  readonly _tag: "PlaywrightDownload";
441
441
  };
442
442
  /**
@@ -1001,4 +1001,4 @@ declare class Playwright extends Playwright_base {
1001
1001
  static readonly layer: Layer.Layer<Playwright, never, never>;
1002
1002
  }
1003
1003
  //#endregion
1004
- export { PlaywrightErrorReason as S, PlaywrightWorker as _, NewPageOptions as a, PlaywrightLocatorService as b, PlaywrightBrowserContext as c, PlaywrightPageService as d, PlaywrightDialog as f, PlaywrightResponse as g, PlaywrightRequest as h, NewContextOptions as i, PlaywrightBrowserContextService as l, PlaywrightFileChooser as m, PlaywrightService as n, PlaywrightBrowser as o, PlaywrightDownload as p, LaunchOptions$1 as r, PlaywrightBrowserService as s, Playwright as t, PlaywrightPage as u, PlaywrightFrameService as v, PlaywrightError as x, PlaywrightLocator as y };
1004
+ export { PlaywrightErrorReason as C, PlaywrightError as S, PlaywrightWorker as _, NewPageOptions as a, PlaywrightLocator as b, PlaywrightBrowserContext as c, PlaywrightPageService as d, PlaywrightDialog as f, PlaywrightResponse as g, PlaywrightRequest as h, NewContextOptions as i, PlaywrightBrowserContextService as l, PlaywrightFileChooser as m, PlaywrightService as n, PlaywrightBrowser as o, PlaywrightDownload as p, LaunchOptions$1 as r, PlaywrightBrowserService as s, Playwright as t, PlaywrightPage as u, PlaywrightFrame as v, PlaywrightLocatorService as x, PlaywrightFrameService as y };
package/dist/index.d.mts CHANGED
@@ -1,2 +1,2 @@
1
- import { S as PlaywrightErrorReason, _ as PlaywrightWorker, a as NewPageOptions, b as PlaywrightLocatorService, c as PlaywrightBrowserContext, d as PlaywrightPageService, f as PlaywrightDialog, g as PlaywrightResponse, h as PlaywrightRequest, i as NewContextOptions, l as PlaywrightBrowserContextService, m as PlaywrightFileChooser, n as PlaywrightService, o as PlaywrightBrowser, p as PlaywrightDownload, r as LaunchOptions, s as PlaywrightBrowserService, t as Playwright, u as PlaywrightPage, x as PlaywrightError, y as PlaywrightLocator } from "./index-K6LNMeXC.mjs";
2
- export { LaunchOptions, NewContextOptions, NewPageOptions, Playwright, PlaywrightBrowser, PlaywrightBrowserContext, PlaywrightBrowserContextService, PlaywrightBrowserService, PlaywrightDialog, PlaywrightDownload, PlaywrightError, PlaywrightErrorReason, PlaywrightFileChooser, PlaywrightLocator, PlaywrightLocatorService, PlaywrightPage, PlaywrightPageService, PlaywrightRequest, PlaywrightResponse, PlaywrightService, PlaywrightWorker };
1
+ import { C as PlaywrightErrorReason, S as PlaywrightError, _ as PlaywrightWorker, a as NewPageOptions, b as PlaywrightLocator, c as PlaywrightBrowserContext, d as PlaywrightPageService, f as PlaywrightDialog, g as PlaywrightResponse, h as PlaywrightRequest, i as NewContextOptions, l as PlaywrightBrowserContextService, m as PlaywrightFileChooser, n as PlaywrightService, o as PlaywrightBrowser, p as PlaywrightDownload, r as LaunchOptions, s as PlaywrightBrowserService, t as Playwright, u as PlaywrightPage, v as PlaywrightFrame, x as PlaywrightLocatorService, y as PlaywrightFrameService } from "./index-BdIazBpL.mjs";
2
+ export { LaunchOptions, NewContextOptions, NewPageOptions, Playwright, PlaywrightBrowser, PlaywrightBrowserContext, PlaywrightBrowserContextService, PlaywrightBrowserService, PlaywrightDialog, PlaywrightDownload, PlaywrightError, PlaywrightErrorReason, PlaywrightFileChooser, PlaywrightFrame, PlaywrightFrameService, PlaywrightLocator, PlaywrightLocatorService, PlaywrightPage, PlaywrightPageService, PlaywrightRequest, PlaywrightResponse, PlaywrightService, PlaywrightWorker };
package/dist/index.mjs CHANGED
@@ -1,3 +1,3 @@
1
- import { a as PlaywrightDownload, c as PlaywrightResponse, d as PlaywrightLocator, f as PlaywrightError, i as PlaywrightDialog, l as PlaywrightWorker, n as PlaywrightBrowser, o as PlaywrightFileChooser, r as PlaywrightBrowserContext, s as PlaywrightRequest, t as Playwright, u as PlaywrightPage } from "./src-Bf0XqK7M.mjs";
1
+ import { a as PlaywrightDownload, c as PlaywrightResponse, d as PlaywrightFrame, f as PlaywrightLocator, i as PlaywrightDialog, l as PlaywrightWorker, n as PlaywrightBrowser, o as PlaywrightFileChooser, p as PlaywrightError, r as PlaywrightBrowserContext, s as PlaywrightRequest, t as Playwright, u as PlaywrightPage } from "./src-BBJfAuBn.mjs";
2
2
 
3
- export { Playwright, PlaywrightBrowser, PlaywrightBrowserContext, PlaywrightDialog, PlaywrightDownload, PlaywrightError, PlaywrightFileChooser, PlaywrightLocator, PlaywrightPage, PlaywrightRequest, PlaywrightResponse, PlaywrightWorker };
3
+ export { Playwright, PlaywrightBrowser, PlaywrightBrowserContext, PlaywrightDialog, PlaywrightDownload, PlaywrightError, PlaywrightFileChooser, PlaywrightFrame, PlaywrightLocator, PlaywrightPage, PlaywrightRequest, PlaywrightResponse, PlaywrightWorker };
@@ -415,4 +415,4 @@ var Playwright = class Playwright extends Context.Tag("effect-playwright/index/P
415
415
  };
416
416
 
417
417
  //#endregion
418
- export { PlaywrightDownload as a, PlaywrightResponse as c, PlaywrightLocator as d, PlaywrightError as f, PlaywrightDialog as i, PlaywrightWorker as l, PlaywrightBrowser as n, PlaywrightFileChooser as o, PlaywrightBrowserContext as r, PlaywrightRequest as s, Playwright as t, PlaywrightPage as u };
418
+ export { PlaywrightDownload as a, PlaywrightResponse as c, PlaywrightFrame as d, PlaywrightLocator as f, PlaywrightDialog as i, PlaywrightWorker as l, PlaywrightBrowser as n, PlaywrightFileChooser as o, PlaywrightError as p, PlaywrightBrowserContext as r, PlaywrightRequest as s, Playwright as t, PlaywrightPage as u };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "effect-playwright",
3
3
  "type": "module",
4
- "version": "0.2.0",
4
+ "version": "0.2.2",
5
5
  "description": "An Effect-based Playwright library.",
6
6
  "author": "Jobflow GmbH",
7
7
  "license": "ISC",