EditableTitle

Components/Layout/Page

Interactive docs page: https://wix-pages.com/design-system-documentation/#/component/editabletitle

Overview

Copy

Editable title allows users to change a page title on the spot. It is used as a title inside of a <Page.Header/> component.

Do

  • Use it to let users give a title to a page, such as a product, category or event detail page.
  • Use it as a part of a <PageHeader/>.

Don't

  • Don't use it for static page titles that can't be edited, such as Inventory, Settings or Subscriptions.
  • Don't use it outside of a <PageHeader/> component.
  • Don't use it as an editable cell or title inside forms or tables. Use <Input/> with a 'bottomBorder' border type instead.

Feature examples

Max length

Define a max number of characters that users can write in the title with maxLength prop.

maxLength includes spaces and has no default value.

Copy

Auto focus

Make the component ready to type in as soon as it is rendered (on mount) with autoFocus prop.

Copy

Value

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.

Copy

Common use case examples

Giving a name for a newly created item

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).

Copy

Code

Copy

Props

NameTypeDefaultDescription
autoFocusboolean—Sets focus on the title as soon as the component is rendered (on mount)
classNamestring—Specifies a CSS class name to be appended to the component's root element.
dataHookstring—Applies a data-hook HTML attribute that can be used in the tests.
defaultValuestring''Defines text value that is shown when the title is empty. When clicked, this value becomes the default 'value'
initialValuestring—Defines a text value that is shown initially.
maxLengthnumber—Sets the max number of characters that a user can type in the title.
onChangeChangeEventHandler—Triggers function when the title is being edited.
onSubmit(value: string) => void—Triggers function when a user is done with editing the title.
valuestring—Sets the controlled value of the input.

Testkit

Import the driver matching your test environment:

Copy

Driver methods

MethodDescription
getInput—
getHeadingText—
clickHeading—
existsChecks whether the component found with the given data hook.
elementGets the component root element.
clickClicks on the component root element.
baseReturns UniDriver for the base element.

Changelog

  • 1.339.0 (2026-10-19) — maintenance release, no component-specific changes
  • 1.338.0 (2026-10-15) — maintenance release, no component-specific changes
  • 1.337.0 (2026-10-14) — maintenance release, no component-specific changes
  • 1.330.3 (2026-09-29) — maintenance release, no component-specific changes
  • 1.328.0 (2026-09-22) — maintenance release, no component-specific changes
  • 1.325.0 (2026-09-17) — maintenance release, no component-specific changes
  • 1.312.0 (2026-08-14) — maintenance release, no component-specific changes
  • 1.310.0 (2026-08-10) — maintenance release, no component-specific changes
  • 1.306.0 (2026-07-31) — maintenance release, no component-specific changes
  • 1.299.0 (2026-07-17) — maintenance release, no component-specific changes
  • 1.295.0 (2026-07-03) — maintenance release, no component-specific changes
  • 1.292.0 (2026-06-22) — maintenance release, no component-specific changes
  • 1.291.0 (2026-06-19) — maintenance release, no component-specific changes
  • 1.273.0 (2026-04-30) — maintenance release, no component-specific changes
  • 1.266.0 (2026-04-07) — maintenance release, no component-specific changes
  • 1.260.0 (2026-03-17) — maintenance release, no component-specific changes
  • 1.247.2 (2026-01-21) — maintenance release, no component-specific changes
  • 1.245.0 (2026-01-06) — fix: fix keyboard navigation tabbing (#15747)
  • 1.212.0 (2025-08-11) — maintenance release, no component-specific changes
  • 1.175.1 (2025-04-01) — maintenance release, no component-specific changes
  • 1.141.0 (2024-11-19) — fix: change type of getInput() testkit method (#14299)
  • 1.139.2 (2024-11-12) — maintenance release, no component-specific changes
  • 1.115.0 (2024-07-17) — maintenance release, no component-specific changes
  • 1.102.0 (2024-04-16) — maintenance release, no component-specific changes
  • 1.92.1 (2024-02-05) — maintenance release, no component-specific changes

Last updated: 21 October 2026

Did this help?