Components/Layout/Page
Interactive docs page: https://wix-pages.com/design-system-documentation/#/component/editabletitle
Editable title allows users to change a page title on the spot. It is used as a title inside of a <Page.Header/> component.
<PageHeader/>.<PageHeader/> component.<Input/> with a 'bottomBorder' border type instead.Define a max number of characters that users can write in the title with maxLength prop.
maxLength includes spaces and has no default value.
Make the component ready to type in as soon as it is rendered (on mount) with autoFocus prop.
Control title text value with these props:
defaultValue - use it to display a placeholder text. It will become a title if users do not change it.initialValue - use it to suggest a fitting opening title for users. They can delete and change it themselves.value - use it to specify the current value of the title.Note that when users delete the initialValue, defaultValue is still shown.
Use Editable title in the <Page.Header/> when users create a new item with no default name (e.g., a product for the Store).
Editable title can work in sync with Form components (e.g., writing 'Green Shoes' in the 'Name' field will automatically change the page title, too).
| Name | Type | Default | Description |
|---|---|---|---|
autoFocus | boolean | — | Sets focus on the title as soon as the component is rendered (on mount) |
className | string | — | Specifies a CSS class name to be appended to the component's root element. |
dataHook | string | — | Applies a data-hook HTML attribute that can be used in the tests. |
defaultValue | string | '' | Defines text value that is shown when the title is empty. When clicked, this value becomes the default 'value' |
initialValue | string | — | Defines a text value that is shown initially. |
maxLength | number | — | Sets the max number of characters that a user can type in the title. |
onChange | ChangeEventHandler | — | Triggers function when the title is being edited. |
onSubmit | (value: string) => void | — | Triggers function when a user is done with editing the title. |
value | string | — | Sets the controlled value of the input. |
Import the driver matching your test environment:
| Method | Description |
|---|---|
getInput | — |
getHeadingText | — |
clickHeading | — |
exists | Checks whether the component found with the given data hook. |
element | Gets the component root element. |
click | Clicks on the component root element. |
base | Returns UniDriver for the base element. |
getInput() testkit method (#14299)Last updated: 21 October 2026