Skip to content

feat: handle key press#652

Closed
hitesh-ag1 wants to merge 1 commit intobrowserbase:mainfrom
hitesh-ag1:press-feature
Closed

feat: handle key press#652
hitesh-ag1 wants to merge 1 commit intobrowserbase:mainfrom
hitesh-ag1:press-feature

Conversation

@hitesh-ag1
Copy link
Copy Markdown
Contributor

why

enable actions using key press commands on screen

what changed

  • Added press key, val in SupportedPlaywrightAction enum
  • Modified instruction prompt under buildActObservePrompt
  • Added two examples - examples/google_enter.ts, examples/try_wordle.ts

test plan

  • Tested key presses in google search and wordle

@changeset-bot
Copy link
Copy Markdown

changeset-bot Bot commented Apr 9, 2025

⚠️ No Changeset found

Latest commit: 7831d36

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

Copy link
Copy Markdown
Contributor

@greptile-apps greptile-apps Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

PR Summary

The changes add robust support for handling key press actions, updating prompt instructions, enum types, and examples to validate the new feature.

  • Updated /lib/prompt.ts in buildActObservePrompt to handle key press commands with capitalized key names.
  • Added PRESS to SupportedPlaywrightAction enum in /types/act.ts.
  • Introduced practical examples in /examples/try_wordle.ts and /examples/google_enter.ts to showcase key press functionality.
  • Modified /package.json to include scripts for running the new key press examples.

💡 (1/5) You can manually trigger the bot by mentioning @greptileai in a comment!

5 file(s) reviewed, no comment(s)
Edit PR Review Bot Settings | Greptile

kamath added a commit that referenced this pull request Apr 11, 2025
* feat: detect key press

* changeset

---------

Co-authored-by: Hitesh Agarwal <hitesh001@e.ntu.edu.sg>
@kamath
Copy link
Copy Markdown
Contributor

kamath commented Apr 11, 2025

merged in #661! congrats on your first contribution!

@kamath kamath closed this Apr 11, 2025
@hitesh-ag1 hitesh-ag1 deleted the press-feature branch April 13, 2025 03:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants