Skip to content

Commit 6e1f9b8

Browse files
committed
chore: restructure interface
1 parent 36b63e4 commit 6e1f9b8

2 files changed

Lines changed: 11 additions & 11 deletions

File tree

packages/image-comparison-core/src/methods/elementScreenshots.ts

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -3,17 +3,7 @@ import { makeCroppedBase64Image } from './images.js'
33
import scrollElementIntoView from '../clientSideScripts/scrollElementIntoView.js'
44
import scrollToPosition from '../clientSideScripts/scrollToPosition.js'
55
import { getBase64ScreenshotSize, waitFor } from '../helpers/utils.js'
6-
import type { ElementScreenshotDataOptions } from './screenshots.interfaces.js'
7-
8-
/**
9-
* Interface representing data for element screenshot result.
10-
*/
11-
export interface ElementScreenshotData {
12-
/** The base64 encoded image. */
13-
base64Image: string;
14-
/** Whether this is a web driver element screenshot. */
15-
isWebDriverElementScreenshot?: boolean;
16-
}
6+
import type { ElementScreenshotDataOptions, ElementScreenshotData } from './screenshots.interfaces.js'
177

188
export async function takeElementScreenshot(
199
browserInstance: WebdriverIO.Browser,

packages/image-comparison-core/src/methods/screenshots.interfaces.ts

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -149,6 +149,16 @@ export interface TakeWebElementScreenshotData {
149149
rectangles: RectanglesOutput;
150150
}
151151

152+
/**
153+
* Interface representing data for element screenshot result.
154+
*/
155+
export interface ElementScreenshotData {
156+
/** The base64 encoded image. */
157+
base64Image: string;
158+
/** Whether this is a web driver element screenshot. */
159+
isWebDriverElementScreenshot?: boolean;
160+
}
161+
152162
/**
153163
* Interface representing options for element screenshot data.
154164
*/

0 commit comments

Comments
 (0)