MCPcopy Index your code
hub / github.com/callstack/agent-device / assertExclusiveScrollDistanceInputs

Function assertExclusiveScrollDistanceInputs

src/core/scroll-command.ts:16–23  ·  view source on GitHub ↗
(
  options: ScrollDistanceOptions,
  message = 'scroll accepts either a relative amount or --pixels, not both',
)

Source from the content-addressed store, hash-verified

14export type ScrollCommandOptions = ScrollDistanceOptions & ScrollTimingOptions;
15
16export function assertExclusiveScrollDistanceInputs(
17 options: ScrollDistanceOptions,
18 message = 'scroll accepts either a relative amount or --pixels, not both',
19): void {
20 if (options.amount !== undefined && options.pixels !== undefined) {
21 throw new AppError('INVALID_ARGS', message);
22 }
23}
24
25export function normalizeScrollDurationMs(
26 durationMs: number | undefined,

Callers 2

scrollCommandFunction · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected