From b11cab0cb59de96244d48f3e697a5785164a2e97 Mon Sep 17 00:00:00 2001 From: Karl Kemister-Sheppard Date: Mon, 17 Feb 2025 10:42:19 +1000 Subject: [PATCH 1/9] DOC-3132: New revisionhistory_allow_restore option to control restoration of old revisions. --- modules/ROOT/pages/7.7.0-release-notes.adoc | 19 ++++++++++++++++++ modules/ROOT/pages/revisionhistory.adoc | 2 ++ .../revisionhistory_allow_restore.adoc | 20 +++++++++++++++++++ 3 files changed, 41 insertions(+) create mode 100644 modules/ROOT/partials/configuration/revisionhistory_allow_restore.adoc diff --git a/modules/ROOT/pages/7.7.0-release-notes.adoc b/modules/ROOT/pages/7.7.0-release-notes.adoc index eae2603d9e..f02dfb8849 100644 --- a/modules/ROOT/pages/7.7.0-release-notes.adoc +++ b/modules/ROOT/pages/7.7.0-release-notes.adoc @@ -109,6 +109,25 @@ This caused confusion in identifying the problem during setup. For information on the **Image Optimizer** plugin, see: xref:uploadcare.adoc[Image Optimizer]. +=== Revision History + +The {productname} {release-version} release includes an accompanying release of the **Revision History** premium plugin. + +**Revision History** includes the following addition. + +==== New `revisionhistory_allow_restore` option to control restoration of old revisions +// #TINY-11746 + +Previously, integrators had no way to control whether users could restore old revisions in the **Revision History** plugin. + +{prductname} {release-version} introduces a new `revisionhistory_allow_restore` option, which provides integrators with a way to manage this behavior. By default, it is set to `+true+`, setting it to `+false+` prevents users from restoring previous versions. + +This improvement enhances access control within the **Revision History** plugin, providing greater flexibility for managing revision restoration. + +For more information, see: xref:revisionhistory.adoc[Revision History]. + +==== New `revisionhistory_allow_restore` option to control if users can restore old versions. + [[improvements]] == Improvements diff --git a/modules/ROOT/pages/revisionhistory.adoc b/modules/ROOT/pages/revisionhistory.adoc index 06fc18b2b1..6e15b81933 100644 --- a/modules/ROOT/pages/revisionhistory.adoc +++ b/modules/ROOT/pages/revisionhistory.adoc @@ -109,6 +109,8 @@ include::partial$configuration/revisionhistory_fetch.adoc[leveloffset=+1] include::partial$configuration/revisionhistory_fetch_revision.adoc[leveloffset=+1] +include::partial$configuration/revisionhistory_allow_restore.adoc[leveloffset=+1] + include::partial$configuration/revisionhistory_author.adoc[leveloffset=+1] include::partial$configuration/revisionhistory_display_author.adoc[leveloffset=+1] diff --git a/modules/ROOT/partials/configuration/revisionhistory_allow_restore.adoc b/modules/ROOT/partials/configuration/revisionhistory_allow_restore.adoc new file mode 100644 index 0000000000..05850c2d35 --- /dev/null +++ b/modules/ROOT/partials/configuration/revisionhistory_allow_restore.adoc @@ -0,0 +1,20 @@ +[[revisionhistory_allow_restore]] +== `revisionhistory_allow_restore` + +The `revisionhistory_allow_restore` option enables or disables the ability to restore a revision from the Revision History view. + +*Type:* `+Boolean+` + +*Default vale:* `+true+` + +=== Example: Using `revisionhistory_allow_restore` + +[source,js] +---- +tinymce.init({ + selector: 'textarea', // change this value according to your HTML + plugins: 'revisionhistory', + toolbar: 'revisionhistory', + revisionhistory_fetch: () => Promise.resolve([]), // Required option for the plugin - replace with actual API request + revisionhistory_allow_restore: false +---- From 48f20753dbd87e0220c831940821be9a17751294 Mon Sep 17 00:00:00 2001 From: Karl Kemister-Sheppard Date: Mon, 17 Feb 2025 10:46:12 +1000 Subject: [PATCH 2/9] Update modules/ROOT/pages/7.7.0-release-notes.adoc --- modules/ROOT/pages/7.7.0-release-notes.adoc | 1 - 1 file changed, 1 deletion(-) diff --git a/modules/ROOT/pages/7.7.0-release-notes.adoc b/modules/ROOT/pages/7.7.0-release-notes.adoc index f02dfb8849..22e92310d8 100644 --- a/modules/ROOT/pages/7.7.0-release-notes.adoc +++ b/modules/ROOT/pages/7.7.0-release-notes.adoc @@ -126,7 +126,6 @@ This improvement enhances access control within the **Revision History** plugin, For more information, see: xref:revisionhistory.adoc[Revision History]. -==== New `revisionhistory_allow_restore` option to control if users can restore old versions. [[improvements]] == Improvements From bea75b09f3360e0b0cccb8e6e63fa1660fa046ef Mon Sep 17 00:00:00 2001 From: "CODE:AG" <57781325+abhinavgandham@users.noreply.github.com> Date: Mon, 17 Feb 2025 14:39:59 +1000 Subject: [PATCH 3/9] Update modules/ROOT/pages/7.7.0-release-notes.adoc --- modules/ROOT/pages/7.7.0-release-notes.adoc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/ROOT/pages/7.7.0-release-notes.adoc b/modules/ROOT/pages/7.7.0-release-notes.adoc index 22e92310d8..197e50b764 100644 --- a/modules/ROOT/pages/7.7.0-release-notes.adoc +++ b/modules/ROOT/pages/7.7.0-release-notes.adoc @@ -120,7 +120,7 @@ The {productname} {release-version} release includes an accompanying release of Previously, integrators had no way to control whether users could restore old revisions in the **Revision History** plugin. -{prductname} {release-version} introduces a new `revisionhistory_allow_restore` option, which provides integrators with a way to manage this behavior. By default, it is set to `+true+`, setting it to `+false+` prevents users from restoring previous versions. +{productname} {release-version} introduces a new `revisionhistory_allow_restore` option, which provides integrators with a way to manage this behavior. By default, it is set to `+true+`, setting it to `+false+` prevents users from restoring previous versions. This improvement enhances access control within the **Revision History** plugin, providing greater flexibility for managing revision restoration. From 63d6b109bef21e69b29ec0d59e86ebfa0aa98d5a Mon Sep 17 00:00:00 2001 From: Karl Kemister-Sheppard Date: Wed, 19 Feb 2025 12:27:08 +1000 Subject: [PATCH 4/9] Update modules/ROOT/pages/7.7.0-release-notes.adoc Co-authored-by: CODE:AG <57781325+abhinavgandham@users.noreply.github.com> --- modules/ROOT/pages/7.7.0-release-notes.adoc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/ROOT/pages/7.7.0-release-notes.adoc b/modules/ROOT/pages/7.7.0-release-notes.adoc index 197e50b764..ee34be3376 100644 --- a/modules/ROOT/pages/7.7.0-release-notes.adoc +++ b/modules/ROOT/pages/7.7.0-release-notes.adoc @@ -124,7 +124,7 @@ Previously, integrators had no way to control whether users could restore old re This improvement enhances access control within the **Revision History** plugin, providing greater flexibility for managing revision restoration. -For more information, see: xref:revisionhistory.adoc[Revision History]. +For more information on the **Revision History** plugin, see: xref:revisionhistory.adoc[Revision History]. [[improvements]] From 7fe1b26128af2852ae390499508f4d5777bcd892 Mon Sep 17 00:00:00 2001 From: Karl Kemister-Sheppard Date: Wed, 19 Feb 2025 12:27:25 +1000 Subject: [PATCH 5/9] Update modules/ROOT/partials/configuration/revisionhistory_allow_restore.adoc Co-authored-by: CODE:AG <57781325+abhinavgandham@users.noreply.github.com> --- .../partials/configuration/revisionhistory_allow_restore.adoc | 1 + 1 file changed, 1 insertion(+) diff --git a/modules/ROOT/partials/configuration/revisionhistory_allow_restore.adoc b/modules/ROOT/partials/configuration/revisionhistory_allow_restore.adoc index 05850c2d35..b269da0ed1 100644 --- a/modules/ROOT/partials/configuration/revisionhistory_allow_restore.adoc +++ b/modules/ROOT/partials/configuration/revisionhistory_allow_restore.adoc @@ -17,4 +17,5 @@ tinymce.init({ toolbar: 'revisionhistory', revisionhistory_fetch: () => Promise.resolve([]), // Required option for the plugin - replace with actual API request revisionhistory_allow_restore: false + }); ---- From 7147f9ddb7a9bf6b80d0bc2b25cb5cab94ba451a Mon Sep 17 00:00:00 2001 From: Karl Kemister-Sheppard Date: Wed, 19 Feb 2025 12:27:46 +1000 Subject: [PATCH 6/9] Update modules/ROOT/partials/configuration/revisionhistory_allow_restore.adoc Co-authored-by: tiny-ben-tran --- .../partials/configuration/revisionhistory_allow_restore.adoc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/ROOT/partials/configuration/revisionhistory_allow_restore.adoc b/modules/ROOT/partials/configuration/revisionhistory_allow_restore.adoc index b269da0ed1..c4d80ab1a6 100644 --- a/modules/ROOT/partials/configuration/revisionhistory_allow_restore.adoc +++ b/modules/ROOT/partials/configuration/revisionhistory_allow_restore.adoc @@ -1,7 +1,7 @@ [[revisionhistory_allow_restore]] == `revisionhistory_allow_restore` -The `revisionhistory_allow_restore` option enables or disables the ability to restore a revision from the Revision History view. +The `revisionhistory_allow_restore` option enables or disables the ability to restore a revision. *Type:* `+Boolean+` From ab2894f4b33a030f9550c5ed9993689eb1480fcb Mon Sep 17 00:00:00 2001 From: "CODE:AG" <57781325+abhinavgandham@users.noreply.github.com> Date: Wed, 19 Feb 2025 13:04:00 +1000 Subject: [PATCH 7/9] Update modules/ROOT/pages/7.7.0-release-notes.adoc Co-authored-by: tiny-ben-tran --- modules/ROOT/pages/7.7.0-release-notes.adoc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/ROOT/pages/7.7.0-release-notes.adoc b/modules/ROOT/pages/7.7.0-release-notes.adoc index ee34be3376..91dd05caef 100644 --- a/modules/ROOT/pages/7.7.0-release-notes.adoc +++ b/modules/ROOT/pages/7.7.0-release-notes.adoc @@ -120,7 +120,7 @@ The {productname} {release-version} release includes an accompanying release of Previously, integrators had no way to control whether users could restore old revisions in the **Revision History** plugin. -{productname} {release-version} introduces a new `revisionhistory_allow_restore` option, which provides integrators with a way to manage this behavior. By default, it is set to `+true+`, setting it to `+false+` prevents users from restoring previous versions. +{productname} {release-version} introduces a new `revisionhistory_allow_restore` option, which provides a way to control if a user can restore revisions. By default, it is set to `+true+`, setting it to `+false+` prevents users from restoring previous versions. This improvement enhances access control within the **Revision History** plugin, providing greater flexibility for managing revision restoration. From 5b2ff43c683a83998aeaf35db8b06ae4fd0d6fe8 Mon Sep 17 00:00:00 2001 From: Karl Kemister-Sheppard Date: Wed, 19 Feb 2025 14:04:37 +1000 Subject: [PATCH 8/9] Update modules/ROOT/pages/7.7.0-release-notes.adoc Co-authored-by: tiny-ben-tran --- modules/ROOT/pages/7.7.0-release-notes.adoc | 1 - 1 file changed, 1 deletion(-) diff --git a/modules/ROOT/pages/7.7.0-release-notes.adoc b/modules/ROOT/pages/7.7.0-release-notes.adoc index 91dd05caef..5cdd39cbd5 100644 --- a/modules/ROOT/pages/7.7.0-release-notes.adoc +++ b/modules/ROOT/pages/7.7.0-release-notes.adoc @@ -118,7 +118,6 @@ The {productname} {release-version} release includes an accompanying release of ==== New `revisionhistory_allow_restore` option to control restoration of old revisions // #TINY-11746 -Previously, integrators had no way to control whether users could restore old revisions in the **Revision History** plugin. {productname} {release-version} introduces a new `revisionhistory_allow_restore` option, which provides a way to control if a user can restore revisions. By default, it is set to `+true+`, setting it to `+false+` prevents users from restoring previous versions. From 766589d1d567aa247a62c0155afc7f0cd648f3cd Mon Sep 17 00:00:00 2001 From: Karl Kemister-Sheppard Date: Wed, 19 Feb 2025 14:04:51 +1000 Subject: [PATCH 9/9] Update modules/ROOT/pages/7.7.0-release-notes.adoc --- modules/ROOT/pages/7.7.0-release-notes.adoc | 1 - 1 file changed, 1 deletion(-) diff --git a/modules/ROOT/pages/7.7.0-release-notes.adoc b/modules/ROOT/pages/7.7.0-release-notes.adoc index 5cdd39cbd5..8d69a2fd19 100644 --- a/modules/ROOT/pages/7.7.0-release-notes.adoc +++ b/modules/ROOT/pages/7.7.0-release-notes.adoc @@ -118,7 +118,6 @@ The {productname} {release-version} release includes an accompanying release of ==== New `revisionhistory_allow_restore` option to control restoration of old revisions // #TINY-11746 - {productname} {release-version} introduces a new `revisionhistory_allow_restore` option, which provides a way to control if a user can restore revisions. By default, it is set to `+true+`, setting it to `+false+` prevents users from restoring previous versions. This improvement enhances access control within the **Revision History** plugin, providing greater flexibility for managing revision restoration.