Perform a right-click action to open context menus
npx skills add https://github.com/testdriverai/testdriverai --skill testdriver:right-click
<!-- Generated from right-click.mdx. DO NOT EDIT. -->
The rightClick() method performs a right-click action on an element, typically used to open context menus. You can either call it on an Element instance or use it directly with a selector.
// Right-click on an element
await element.rightClick();
// Right-click using a selector
await ai.rightClick('selector');
When called on an Element, no parameters are required.
When called directly on the AI client:
| Parameter | Type | Description |
|-----------|------|-------------|
| selector | string | The selector describing the element to right-click |
Returns a Promise<void> that resolves when the right-click action completes.
const fileItem = await ai.find('README.md file');
await fileItem.rightClick();
// Select menu option
await ai.click('Delete from context menu');
await ai.rightClick('image in the gallery');
await ai.click('Save image as');
import { test } from 'vitest';
import { vscode } from '@testdriver/sdk';
test('renames a file via context menu', async () => {
const { ai } = await vscode();
// Right-click on a file
await ai.rightClick('test.js in the file explorer');
// Click rename option
await ai.click('Rename');
// Type new name
await ai.type('test.spec.js');
await ai.pressKeys('Enter');
// Verify rename
const renamedFile = await ai.find('test.spec.js in the file explorer');
expect(renamedFile).toBeTruthy();
});
import { test } from 'vitest';
import { chrome } from '@testdriver/sdk';
test('opens link in new tab', async () => {
const { ai } = await chrome('https://example.com');
// Right-click on a link
await ai.rightClick('Documentation link');
// Select "Open in new tab"
await ai.click('Open link in new tab');
});
test('uses custom context menu', async () => {
const { ai } = await chrome('https://app.example.com');
// Right-click on custom element
await ai.rightClick('project item in the list');
// Wait for custom menu to appear
await ai.find('custom context menu');
// Click menu option
await ai.click('Duplicate project');
// Verify duplication
const duplicatedProject = await ai.find('project item (copy)');
expect(duplicatedProject).toBeTruthy();
});
click() - Single click on an elementdoubleClick() - Double-click on an elementmouseDown() - Press mouse button without releasingmouseUp() - Release mouse buttonhover() - Move mouse over element without clickingToolkit for interacting with and testing local web applications using Playwright. Supports verifying frontend functionality, debugging UI behavior, capturing browser screenshots, and viewing browser logs.
Use this skill to query your Google NotebookLM notebooks directly from Claude Code for source-grounded, citation-backed answers from Gemini. Browser automation, library management, persistent auth. Drastically reduced hallucinations through document-only responses.
Complete browser automation with Playwright. Auto-detects dev servers, writes clean test scripts to /tmp. Test pages, fill forms, take screenshots, check responsive design, validate UX, test login flows, check links, automate any browser task. Use when user wants to test websites, automate browser interactions, validate web functionality, or perform any browser-based testing.
Automate Electron desktop apps (VS Code, Slack, Discord, Figma, Notion, Spotify, etc.) using agent-browser via Chrome DevTools Protocol. Use when the user needs to interact with an Electron app, automate a desktop app, connect to a running app, control a native app, or test an Electron application. Triggers include "automate Slack app", "control VS Code", "interact with Discord app", "test this Electron app", "connect to desktop app", or any task requiring automation of a native Electron application.
Automate Anchor Browser tasks via Rube MCP (Composio). Always search tools first for current schemas.
Automate Browser Tool tasks via Rube MCP (Composio). Always search tools first for current schemas.
Get Image [from] Internet Link - Zero-setup CLI for downloading full-resolution images from iCloud, Dropbox, Google Photos, and Google Drive share links. Four-tier capture strategy, browser automation, HEIC conversion, album support. Node.js/Playwright.
Expert in building browser extensions that solve real problems - Chrome, Firefox, and cross-browser extensions. Covers extension architecture, manifest v3, content scripts, popup UIs, monetization strategies, and Chrome Web Store publishing. Use when: browser extension, chrome extension, firefox addon, extension, manifest v3.
Take testdriverai/testdriver:right-click from the repository into ~/.claude/skills for personal
use, or into .claude/skills inside a project.
The agent identifies a skill by the name field in its header. Two skills with the
same name cannot sit side by side — one of them will be ignored.