Page tree
Skip to end of metadata
Go to start of metadata

Abstract

Rich text editor should be able to link to any Magnolia or external resource. CKEditor provides methods to create generic http links and Magnolia already has an implementation for linking to other pages by using Pages app chooser dialog. What is missing however is ability to link to contacts and in general any app content should be linkable. This concept supersedes previous linking and image embedding concepts.

Implementation

Rich text editor has link and image buttons, that will initiate a dialog, which will upon return insert a hyperlink or image to the current position of the text. This is unchanged from the current way of handling links. What is changed is that there is not going to be a separate toolbar buttons for internal and external links and images. There will be instead an unified pop-up dialog that handles internal and external resources. The implementation would extend CKEditor link and image dialogs to have controls for internal resource handling. App selection dialogs already exists and they require no modifications. 

Use case: linking

Process begins by clicking link button at toolbar.

Link dialog pops up with two tabs separating internal and external links.

With an external link the URL is inputted textually. In the case of internal link the app that provides the link must be chosen first and then app selection dialog is used to create the actual link. Link is added to rich text editor when link dialog closes.

Use case: image embedding

Image embedding process follows the same principle as linking. The process begins by clicking image button at toolbar.

External image URL is to be inputted textually to the URL field. With internal images the ref can be created and edited either textually or by using app selection dialog.

When using the app selection dialog the Asset app will open a selection dialog. If there is multiple apps that supports embeddable image like media, then the internal image tab would also have a radio button group like with linking.

Alternative implementation

Like in the first implementation concept the process begins by clicking the image or link button in the rich text area toolbar. Difference is that the opened dialog will contain unified tree structure that combines every linkable app resources into one structure. In the first approach there was multiple levels of dialog call hierarchy but in this case there is going to be only one. This approach combines data from range of apps and requires more work than first approach as no such tool currently exists.

User would browse the tree view to find the desired resource and then click OK to select and insert it into the rich text editor. Content area varies depending of the selection. With Apps there is going to be list, tree and thumbnail view similar to content workbench apps.

External resources are special as they are not browseable in any meaningful way. Therefore content area would contain input fields.

Depending on whether to create a link or image there may required to use filtering to rule out Apps that are not suitable for required data type. For example only Asset app should provide images. Filtering removes incompatible apps from the tree view.

  • No labels