effect-playwright 0.2.1 → 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 { S as PlaywrightError, d as PlaywrightPageService, o as PlaywrightBrowser, s as PlaywrightBrowserService, y as PlaywrightFrameService } from "../index-ChKUVZYe.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).
@@ -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
  /**
package/dist/index.d.mts CHANGED
@@ -1,2 +1,2 @@
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-ChKUVZYe.mjs";
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
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/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "effect-playwright",
3
3
  "type": "module",
4
- "version": "0.2.1",
4
+ "version": "0.2.2",
5
5
  "description": "An Effect-based Playwright library.",
6
6
  "author": "Jobflow GmbH",
7
7
  "license": "ISC",