@intuned/runner-types
Advanced tools
Comparing version 1.0.0-beta.26 to 1.0.0-beta.22-fadi-1
declare module '@intuned/runner' { | ||
// Generated by dts-bundle-generator v8.0.1 | ||
import { BrowserContext, Locator, Page } from '@intuned/playwright-core'; | ||
import { PutObjectCommandInput, S3Client } from '@aws-sdk/client-s3'; | ||
import { getSignedUrl } from '@aws-sdk/s3-request-presigner'; | ||
import { BrowserContext, Download as PlaywrightDownload, Locator, Page } from '@intuned/playwright-core'; | ||
import * as z from 'zod'; | ||
@@ -385,4 +387,51 @@ | ||
} | ||
export type Download = Pick<PlaywrightDownload, "delete" | "path" | "suggestedFilename">; | ||
export type PersistFileConfigs = { | ||
type: "DownloadByOpeningNewTab"; | ||
trigger: ((page: EnhancedPlaywrightPage) => Promise<void>) | Locator; | ||
} | { | ||
type: "DownloadByDirectLink"; | ||
trigger: ((page: EnhancedPlaywrightPage) => Promise<void>) | Locator; | ||
} | { | ||
type: "ThirdPartyFileViewer"; | ||
link: string; | ||
downloadAction: (page: EnhancedPlaywrightPage) => Promise<void>; | ||
} | { | ||
type: "DirectLink"; | ||
link: string; | ||
} | { | ||
type: "PrintPdf"; | ||
options?: Parameters<EnhancedPlaywrightPage["pdf"]>[0]; | ||
}; | ||
class File { | ||
private folderName; | ||
private fileName; | ||
private s3Configs; | ||
private s3Client; | ||
private originalFileName?; | ||
constructor(folderName: string, fileName: string, s3Configs: S3Configs, s3Client: S3Client, originalFileName?: string); | ||
getOriginalFileName(): string | undefined; | ||
urlDescriptor(): string; | ||
generateSignedUrl(options?: Parameters<typeof getSignedUrl>[2]): Promise<string>; | ||
} | ||
export interface S3Configs { | ||
bucket: string; | ||
region: string; | ||
accessKeyId: string; | ||
secretAccessKey: string; | ||
} | ||
export class S3FileUploadHelpers { | ||
private s3Client; | ||
private context; | ||
private page; | ||
private configs; | ||
constructor(page: EnhancedPlaywrightPage, context: EnhancedPlaywrightBrowserContext, config?: S3Configs); | ||
uploadFile(fileName: string, file: PutObjectCommandInput["Body"], originalFileName?: string): Promise<File>; | ||
uploadDownloadedFile(fileName: string, download: Download): Promise<File>; | ||
waitForPdfPreviewAndDownloadNewPage(): Promise<Download>; | ||
waitForPdfPreviewAndDownload(newPage: Page): Promise<Download>; | ||
persistFile(fileName: string, configs: PersistFileConfigs): Promise<File | undefined>; | ||
} | ||
export {}; | ||
} |
{ | ||
"name": "@intuned/runner-types", | ||
"version": "1.0.0-beta.26", | ||
"version": "1.0.0-beta.22-fadi-1", | ||
"description": "intuned runner types", | ||
@@ -5,0 +5,0 @@ "author": "Intuned Team", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
21744
682