mirror of
https://github.com/vitest-dev/vitest.git
synced 2025-12-08 18:26:03 +00:00
11 lines
298 B
TypeScript
11 lines
298 B
TypeScript
import type { UserEvent } from 'vitest/browser'
|
|
import type { UserEventCommand } from './utils'
|
|
|
|
export const tab: UserEventCommand<UserEvent['tab']> = async (
|
|
context,
|
|
options = {},
|
|
) => {
|
|
const page = context.page
|
|
await page.keyboard.press(options.shift === true ? 'Shift+Tab' : 'Tab')
|
|
}
|