testdriverscrolllisted
Install: claude install-skill testdriverai/testdriverai
<!-- Generated from scroll.mdx. DO NOT EDIT. -->
## Overview
Scroll the page or active element in any direction using mouse wheel or keyboard.
<Warning>
**Focus Requirements**
Scrolling requires the page or a frame to be focused. If an input field or other interactive element has focus, scroll commands may not work as expected. Before scrolling, ensure focus is on the page by:
- Clicking on a non-interactive area (e.g., page background)
- Pressing the Escape key to unfocus interactive elements
- Clicking outside of input fields or text areas
**If scroll is still not working**, try using Page Down/Page Up keys directly:
```javascript
await testdriver.pressKeys(['pagedown']); // Scroll down
await testdriver.pressKeys(['pageup']); // Scroll up
```
</Warning>
## Syntax
```javascript
await testdriver.scroll(direction, options)
```
## Parameters
<ParamField path="direction" type="string" default="down">
Direction to scroll: `'up'`, `'down'`
</ParamField>
<ParamField path="options" type="object">
<Expandable title="properties">
<ParamField path="amount" type="number" default="300">
Amount to scroll in pixels
</ParamField>
</Expandable>
</ParamField>
## Returns
`Promise<void>`
## Examples
### Basic Scrolling
```javascript
// Scroll down (default)
await testdriver.scroll();
// Scroll down 5 clicks
await testdriver.scroll('down', { amount: 5 });
// Scroll up
await testdriver.scroll('up');
// Scroll up 2 clicks
await testdr