Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 29 additions & 0 deletions modules/ROOT/pages/8.0-release-notes.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -237,6 +237,35 @@ In previous versions of {productname}, the editor's resize handle lacked a `role

In {productname} {release-version}, the resize handle now includes a `role` seperator and an `aria-valuetext` attribute that dynamically reflects the current dimensions of the editor. These improvements enhance accessibility and ensure more accurate announcements by screen readers.

=== New `list_max_depth` option to limit list indentation
// #TINY-11937

{productname} {release-version} introduced a new `list_max_depth` option that allows configuration of the maximum indent depth for list items. This setting accepts a non-negative integer value, where `0` permits list creation without any indentation, and higher values set the maximum allowable indent depth. Negative values are invalid and will trigger an error. When the option is not set, list behavior remains unchanged.

The setting applies only to list indentation and does not affect paragraph indentation. Existing content is not altered, and pasted lists that exceed the maximum indent depth will retain their structure but cannot be further indented. When multiple list items are selected, only items eligible for indentation will be indented individually—validation is applied per item, not across the full selection.

Outdent functionality remains unaffected and always available. The state of indent and outdent controls reflects the current indentation capabilities based on this setting.

==== Example configuration

The following example shows a basic configuration for the `list_max_depth` option, which limits list indentation to a maximum of 2 levels:

[source,js]
----
tinymce.init({
selector: "textarea",
plugins: [
"advlist", "anchor", "autolink", "charmap", "code", "fullscreen",
"help", "image", "insertdatetime", "link", "lists", "media",
"preview", "searchreplace", "table", "visualblocks",
],
list_max_depth: 2,
toolbar: "undo redo | styles | bold italic underline strikethrough | alignleft aligncenter alignright alignjustify | bullist numlist outdent indent | link image",
});
----

For more information, see: xref:user-formatting-options.adoc#list_max_depth[User formatting - List max depth].

=== The translate API now automatically replaces three dots in a row with an ellipsis character.
// #TINY-12155

Expand Down
2 changes: 2 additions & 0 deletions modules/ROOT/pages/user-formatting-options.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -25,3 +25,5 @@ include::partial$configuration/style_formats_autohide.adoc[]
include::partial$configuration/style_formats_merge.adoc[]

include::partial$configuration/text_color.adoc[]

include::partial$configuration/list_max_depth.adoc[]
24 changes: 24 additions & 0 deletions modules/ROOT/partials/configuration/list_max_depth.adoc
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
[[list_max_depth]]
== `list_max_depth`

The `list_max_depth` option sets the maximum nesting depth for lists (ordered and unordered).

*Type:* `Number`

*Default value:* No limit

=== Required plugins

This option requires the `lists` plugin to be enabled.

=== Example
Comment thread
kemister85 marked this conversation as resolved.

[source,js]
----
tinymce.init({
selector: 'textarea',
plugins: 'lists',
toolbar: 'bullist numlist',
list_max_depth: 2 // limits list nesting to maximum of 2 levels
});
----