Need to perform right click of a button in a website in C# using puppeteersharp. Tried the below code but it is not working:
await page.ClickAsync({ button: 'right'}"[class*='_16aPYHYIOVxzNYTA4BGnwS NJVykX0WljoRws2qTYI5G _3FwRpWCSns-2PgbiDhEErG']");
You can use the ClickOptions
argument:
await page.ClickAsync(
"[class*='_16aPYHYIOVxzNYTA4BGnwS NJVykX0WljoRws2qTYI5G _3FwRpWCSns-2PgbiDhEErG']",
new ClickOptions() { Button = MouseButton.Right } );