Skip to content

[Feature]: Screencast showActions: allow the cursor without the action-title banner聽#1993

Description

@spyse

馃殌 Feature Request

Problem

page.screencast().showActions() always draws two things together:

  1. a pointer that moves to the next action
  2. an action-title banner (the locator / call description), top-right by default

There is no way to keep the cursor and drop the banner. ShowActionsOptions only offers cursor, duration, fontSize, and position. position places the banner; it cannot hide it. fontSize: 0 does not either, because the renderer only applies a font size when the value is truthy.
That banner is useful while debugging a test. It is the wrong overlay for a product demo or a narrated recording: it prints selectors such as getByTestId("search_button") over the UI, and our own captions already explain the action.
The title lives in Playwright's closed shadow root (x-pw-title on the screencast glass pane), so a user overlay cannot hide it with CSS.

Proposal

Add a way to suppress the action title while still showing the cursor.
Preferred: a new position, "hidden" / AnnotatePosition.HIDDEN.

page.screencast().showActions(new Screencast.ShowActionsOptions()
    .setCursor(ScreencastCursor.POINTER)
    .setPosition(AnnotatePosition.HIDDEN));

Motivation

Screencast recordings are used for product demos, not only for debugging tests. showActions() is the only way to get the moving cursor, but it always paints the action title as well. That banner shows locators and call descriptions (getByTestId(...), method names) on top of the product UI.

For a narrated demo those strings are noise: the recording already explains the step in its own captions, and the selectors are an implementation detail the viewer should not see. Hiding the title with CSS is not possible, because it is rendered inside Playwright's closed shadow root.

A hidden position would keep the cursor, which makes the demo readable, and drop the banner, which makes it presentable.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions