Ability to redirect deleted page link to a new page

When deleting a page, users can now select, using a page picker, a new target to be used for updating links that where pointing to the deleted page.

To fix eventual broken external links (e.g. bookmarks, links from emails), they can also create an automatic redirect from the old location to the new target.

In addition, to support restoring a deleted page with a redirect created (i.e. a page with the same name, but with a XWiki.RedirectClass added), a Replace action was added for the deleted pages. See Index Application Documentation.

New tags right check strategy configuration

It is now possible to configure the algorithm used when checking view rights on tags (returned by the Tags API) by editing xwiki.properties.

#-# [Since 14.4.8, 14.10.4, 15.0RC1]
#-# Configure the tag selection algorithm to use.
#-# The default algorithm is "exhaustive", which check all elements (documents and tags) for view right before returning
#-# them. This exhaustive check can lead to tag clouds and tag lists being slow to compute on instances with very large 
#-# amounts of tags or tagged documents (more than 5000 of elements).   
#-# Note that it is advised to keep using the default implementation as much as possible, and to switch to the "unsafe"
#-# option only when all performance improvements options have been exhausted 
#-# (see https://www.xwiki.org/xwiki/bin/view/Documentation/AdminGuide/Performances/)
#-# The "unsafe" algorithm does not perform any right checks. It is approximately 10 times faster than "exhaustive"
#-# but does not provide any guarantee that the current user won't be able to view a tag he/she is not allowed to. 
#-# Therefore, we cannot recommend to use it unless tags performance is critical AND tags and document references are 
#-# not considered as critical information.
# tag.rightCheckStrategy.hint=exhaustive
# tag.rightCheckStrategy.hint=unsafe

Moved the old event store to legacy

The old events store is still bundled with XWiki for now. However, it has now been moved to legacy in order to make sure it is not actively used in the product, to discourage others from directly using it (by mistake) and as a first step before actually stopping to bundle it.

Document Analysis progress page

A page is now available in the administration to monitor the progress of the document analysis queue. The page displays the number of remaining tasks, grouped by task type.

Ckeditor Macro Dialog filters by categories

The CKEditor Macros dialog now allows to filter by several categories. In addition, all the listed macros are now displaying their categories.

In addition, macros with an hidden category are not displayed to users who have Display hidden pages set to False in their preferences. Hidden macros categories are Deprecated and Internal by default, and can be configured by Admins since 14.8+.

Detect Page Ready

It's now possible to detect and execute JavaScript code after the page is fully ready, i.e. after all resources have been loaded and there are no pending HTTP requests or promises:

require(['xwiki-page-ready'], function(pageReady) {
  pageReady.afterPageReady(() => {
    console.log('Page is ready!');
  });
});

This is currently used by the client-side PDF export to know when the page is ready for print and by the automated functional tests to know when to start interacting with the page (simulating user actions). See the Page Ready module documentation for more information.

Cancel PDF Export

You can now cancel a running multi-page PDF export job, either because you triggered it by mistake (for a large subtree of pages) or because it takes too long, or any other reason. See the PDF Export Application documentation for more information.

Typed custom event properties

Stream events support custom parameters since the new store implementation, but it was only strings. The old "parameter" related APIs have been renamed to "custom" APIs to support any Object as value. The standard store implementation natively support String, all Numbers, Boolean, Date, byte[] and any Iterable or array of the other types (anything else is converted to String). See Event Stream Module for more details about stream events.

Wiki macros can have several categories

The wiki macros can have several categories. The deprecated Default category is replaced by Default categories.

Attachments backlinks indexation

An indexation of the attachments is now done on the wikis. This means that if PageA includes an attachment (or an image) from PageB, PageA will be listed in the backlinks of PageB.

Indexing the attachments requires a full reindexing of both the pages links and attachments usage of the wiki. This means that for a brief period of time, some pages backlinks might be partially incomplete, especially on large wikis.

Java macros can have several categories

The java macros can have several categories. The deprecated setDefaultCategory is replaced by setDefaultCategories. For instance:

/**
* Create and initialize the descriptor of the macro.
*/

public ExampleMacro()
{

 super("Example", DESCRIPTION, ExampleMacroParameters.class);
  setDefaultCategories(java.util.Collections.singleton("Tutorial"));
}

Temporary Attachments

Starting with this release the files uploaded through the WYSIWYG editor (e.g. when inserting an image or when dropping a file on the editing area) are not saved right away as page attachments. Instead, they become temporary attachments that are saved (linked to the edited page) only when the content of the WYSIWYG editor is saved by the user. This means for instance that when creating a new page, uploading a file doesn't create the page anymore. The user needs to click on the Save button to create the page. Of course, the Cancel button is now behaving as expected: any file uploaded since the last save is discarded along with all the unsaved content changes.

Force client-side PDF generation

The PDF Export application has a new global setting to control whether the PDF is generated server-side (e.g. using a headless Chrome web browser running inside a Docker container) or client-side, using the user's web browser:

# [Since 14.6RC1]
# Whether the PDF export should be performed server-side, e.g. using a headless Chrome web browser running inside a
# Docker container, or client-side, using the user's web browser instead; defaults to server-side PDF generation
export.pdf.serverSide=true

Note that client-side generation has the downside that different users may get a different PDF result for the same wiki page (same content).

CKeditor Image Gallery Picker

The new Attachment Gallery Picker Macro is integrated in the new CKEditor Image Dialog. That way, images can be searched by keyword and can be previewed before selection.

New Options for Allowed HTML Elements and Attributes

New options for HTML cleaning were added that allow precise control which attributes and elements are allowed in XWiki syntax but also in the HTML macro in restricted contexts. The default settings should be fine but in case you notice any breakage due to attributes no longer working or want to restrict certain features like inline-styling, consult the documentation on these options. Do not hesitate to contact us on the forum or the chat in case you notice unexpected breakages or other issues with this change.

The RSA Crypto script service issues SHA256 certificates by default

The RSA Crypto script service (accessible from services.crypto.rsa) now issues certificates signed with SHA256+RSA instead of SHA1+RSA. See XWIKI-19676 to learn more.

Add pagination for Attachments

The attachments tab is now displayed using a Livetable, with only 5 rows displayed at a time to avoid a crowded section. This way, on pages with multiple attached files users can use the navigation and filtering options to search for specific attachments.

Ability to redirect deleted page link to a new page

When deleting a page, users can now select, using a page picker, a new target to be used for updating links that where pointing to the deleted page.

To fix eventual broken external links (e.g. bookmarks, links from emails), they can also create an automatic redirect from the old location to the new target.

In addition, to support restoring a deleted page with an automatic redirect created (i.e. a page with the same name, but with a XWiki.RedirectClass added), a Replace action was added for the deleted pages. See Index Application Documentation.

Escaping of XWiki macro syntax in XML

The character { is now escaped in org.xwiki.xml.XMLUtils#escapeElementText and Document#display APIs.

New CKEditor Image Dialog Improvements

The new CKEditor Image Dialog comes with two new tabs to select images. Users can now use the id of an icon, or use external URLs.
In addition, the image dimensions are now locked by default, and the ratio between the width and height of an images is preserved when one of them is changed.

Async Form Validation

A new JavaScript API is available to help implement asynchronous form validation. It can be used like this:

require(['jquery', 'xwiki-form-validation-async'], function($) {
 const titleInput = $('input[name=title]');

 const validateTitle = () => {
   if (!titleInput.val()) {
     return Promise.reject();
    } else {
     return new Promise((resolve, reject) => {
        ...
      });
    }
  };

  titleInput.on('input', () => {
   // Schedule the asynchronous validation after 500ms. The namespace is used to prevent replacing validations added by
   // other modules.
   titleInput.validateAsync(validateTitle, /* delay: */ 500, /* namespace: */ 'myModule');
  });
});

New tags right check strategy configuration

It is now possible to configure the algorithm used when checking view rights on tags (returned by the Tags API) by editing xwiki.properties.

#-# [Since 14.4.8, 14.10.4, 15.0RC1]
#-# Configure the tag selection algorithm to use.
#-# The default algorithm is "exhaustive", which check all elements (documents and tags) for view right before returning
#-# them. This exhaustive check can lead to tag clouds and tag lists being slow to compute on instances with very large 
#-# amounts of tags or tagged documents (more than 5000 of elements).   
#-# Note that it is advised to keep using the default implementation as much as possible, and to switch to the "unsafe"
#-# option only when all performance improvements options have been exhausted 
#-# (see https://www.xwiki.org/xwiki/bin/view/Documentation/AdminGuide/Performances/)
#-# The "unsafe" algorithm does not perform any right checks. It is approximately 10 times faster than "exhaustive"
#-# but does not provide any guarantee that the current user won't be able to view a tag he/she is not allowed to. 
#-# Therefore, we cannot recommend to use it unless tags performance is critical AND tags and document references are 
#-# not considered as critical information.
# tag.rightCheckStrategy.hint=exhaustive
# tag.rightCheckStrategy.hint=unsafe

Cross wiki refactoring of links by default

Cross wiki refactoring of links is now much faster (being in a different wiki does not anymore have any specific performance impact when refactoring links) and enabled by default.

PDF Export Administration

The administration section provided by the PDF Export Application has been extended to support:

  • selecting and configuring the tool used to generated the PDF
  • showing the state of the PDF generator
  • setting the page ready timeout, that is the number of seconds to wait for the web page to be ready for print before aborting the PDF export

Checkout the documentation for more information.

Improved PDF Template

The default PDF template provided by the PDF Export Application has now better support for multi-page export:

  • the title of each exported wiki page is now included both in the content and in the table of contents, styled differently in order to distinguish it from normal content headings
  • the PDF header shows the title of the "current" wiki page, i.e. the wiki page that provided the content for the current PDF page
  • each exported wiki page starts on a new PDF page

Checkout the documentation for more information.

Improved PDF Template

The default PDF template provided by the PDF Export Application has now better support for multi-page export:

  • the title of each exported wiki page is now included both in the content and in the table of contents
  • the PDF header shows the title of the "current" wiki page, i.e. the wiki page that provided the content for the current PDF page
  • each exported wiki page starts on a new PDF page

Checkout the documentation for more information.

Figure macro type configuration

Is is now possible to manually set the type of a figure macro, instead of relying on the automatic type detection feature.

Attachment Move

A new button is now available in the attachments pane, allowing to move or rename an attachment. It is possible to change the name or the location of the attachments. Optionally, a redirection action is proposed, allowing to automatically redirect requests to the old location of an attachment to the new one.

Suggestions for missing macros

When a macro does not exist, you get an error in the page where it's used. If that macro exists in an available extension and you're an Admin user, you will get a link to this extension to install it using the Extension Manager, right in the error message description.

Attachment selector can use the temporary attachment store

When uploading an attachment using the attachment selector, and the attachment has savemode sets to form, new attachments are not saved directly on the document anymore.
Instead, the attachment is kept in a temporary attachment store and only persisted when the form containing the attachment selector is saved.
Temporary attachments are presented with a clock icon (clock) when presented in the attachments selection modal.

Rendering error reporting improvements

All rendering error (missing macro, etc.) used to be hardcoded. It's now translatable and customization thanks to various extension points. See Rendering Error Reporting for more details about this new system.

PDF Export Administration

The administration section provided by the PDF Export Application has been extended to support:

  • selecting and configuring the tool used to generated the PDF
  • showing the state of the PDF generator

Checkout the documentation for more information.

UI Extension improvements

  • New uiextension and uiextensions macros have been introduced to ease the creation of extension points and display of insertion UI extensions in general in a wiki content.
  • UI extensions now support inline execution. UI extension API used to only allow standalone content, but it's now possible to tell them that they should produce content to insert inline.
  • The default UIExtensionManager component now also check if a specific UIExtensionManager exist for the given extension point identifier.

See UIExtension Module for more about UI extensions.

Extension points for document information

New extension points in the document information panel and the information docextra allow to add extra settings or information that is directly related to a document's content and should thus be easily accessible together with the document in view or edit mode.

Asynchronous document static analysis

A new asynchronous document static analysis API is now available in the Index Application. This API allows to queue and consume persistent document analysis tasks. This API is used in this release as an underlying implementation of the mentions analysis, and will be used soon to perform the analysis of the backlinks of the pages.

Image Captions

The XWiki 2.0 and 2.1 syntax now supports captioned images. The syntax:

[[Caption content>>image:some_image.png]]

is rendered as an image with "Caption content" as caption when the image is alone in a paragraph (e.g. the image syntax is surrounded by blank lines). The caption content supports full XWiki syntax. If you want to use nested links you need to escape the link syntax with a single escape character. For instance, the following syntax:

[[~[~[xwiki.org~>~>https://www.xwiki.org~]~]>>image:some_image.png]]

generates an image with a link to xwiki.org in the caption.

Image captions are also supported in the WYSIWYG editor. In the image dialog the checkbox "Captioned image" can be used to add/remove the caption of an image. The caption can be edited directly below the image.

Export Formats Extension Point

A new UI extension point org.xwiki.platform.template.exportFormats is available to add export formats to the Export Modal. If you were using the old org.xwiki.plaftorm.menu.export.buttons extension point then we highly recommend updating your code to use this new extension point instead. Checkout the documentation for more information.

The new CKEditor Image Dialog is now the default

The new CKEditor Image Dialog is now activated by default. On new instances, or when CKEditor.Config does not exists the change is automatic. Otherwise, activating the new image dialog must be done by removing xwiki-image from the disabled plugins list in the WYSIWYG Editor section of the Administration.

Restricted TextArea

It's now possible to indicate in the configuration of a TextArea property if you want the content to be executed in a restricted context. See TextArea for more details.

This new property is now used in comments objects, which means you can display a comment content as any other textarea property without the need to make the context restricted.

Email notification default frequency

It is now possible to configure globally the default frequency used for email notifications, in the administration section of the Notification Application.

Attachment can be restricted based on their mimetypes

It is now possible to limit the attachments uploaded on a space based on their mimetypes. This attachment validation is now applied on attachment upload using the attachment pane, the REST API, and CKEditor image dialog.

The configuration can be done at farm level with xwiki.properties (see below), at wiki level in the administration, in the Attachments Restriction section, or at space level using the page administration.

#-# [Since 14.10RC1]
#-# Define the list of allowed attachment mimetypes. By default, this list is empty, but you can specify a 
#-# comma-separated list of allowed mimetypes. Note that a joker (*) can be used to accept any media type. Once this
#-# list is not empty, any attachment with an unlisted mimetype will be rejected.
#-# For instance, if you want to only accept plain text and any kind of images, you can set the list to:
#-# text/plain,image/*
# attachment.upload.allowList=

#-# [Since 14.10RC1]
#-# Define the list of blocked attachment mimetypes. By default, this list is empty, but you can specify a 
#-# comma-separated list of blocked mimetypes. Note that a joker (*) can be used to accept any media type. Once this 
#-# list is not empty, any attachment matching one of the listed mimetype will be rejected.
#-# For instance, if you want to reject plain text and any kind of images, you can set the list to:
#-# text/plain,image/*
#-#
# attachment.upload.blockList=

 

Template requirements

It's now possible to express, through template properties, requirements that must be met before the template is executed. By default, the possibility to express a requirement on the context action is supported but any extension can provide its own requirements types. See Template Module for more details.

Attachment gallery picker scope selection toggle

The attachment gallery picker allows to define a search scope, either the current page only, or all viewable pages. In addition, a warning is displayed to the user when the selected attachment is not from the current page.

Include Macro Author

It's now possible to control which author should be used to execute the target of include macro. See Include Macro for more details.

Split Office Content into Nested Pages

The Office Importer Application has been improved to generate (by default) non-terminal (nested) pages when the "Split document" option is selected, if the target wiki page is also non-terminal. The following strategy was implemented:

  • if the target wiki page is terminal then the "child" pages created by the split operation are also terminal
  • if the target wiki page is nested (non-terminal) then:
    • the "child" pages are also nested, if the current user is simple
    • advanced users have a checkbox to control whether the "child" pages are terminal or not, but by default they are not

Besides this, we also did a couple of small improvements to the office import form to:

  • filter office files based on media type (when browsing the local file system)
  • improve existing field labels and hints, adding missing hints
  • hide UI elements that are not relevant for the office import operation
  • perform the office import asynchronously and redirect the user directly to the imported page after a successful import operation

Code Macro Source

The code macro now have an alternative way to indicate the content to highlight, which allows highlighting a script value or the content of an entity stored in the XWiki database. See Code Macro for more details.

New CKEditor Image Dialog Improvements

The new CKEditor Image Dialog comes with two new tabs to select images. Users can now use the id of an icon, or use external URLs.
In addition, the image dimensions are now locked by default, and the ratio between the width and height of an images is preserved when one of them is changed.

Tags:
   

Get Connected