Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migration of unmigrated content due to installation of a new plugin
Uxstatus
ready
ready


Table of Contents

Story

I can use the clipboard to copy and paste items around. I can paste copied items multiple times and a previously copied item is replaced, if I copy a different item to the clipboard.

If I'm unsure where I could paste the current content of the clipboard, I can use a clipboard function to show me all supported locations in the currently showing view. I typically use the clipboard only within a view, rarely across views, but the more acquainted I get with different parts of Magnolia, the more I attempt to use the clipboard to transfer items between its workspaces.

Description of desired behavior

The basic clipboard function does not have to be explained in all detail - it is well known from applications such as Word or text editors. Content Any type of content can be copied to the clipboard and pasted in another location, but it can also be cut - copied and removed - and pasted later. The challenge is to do this right across multiple contexts with different types of items. The

...

In Magnolia, the clipboard is a global function. As such, it works across workspaces and the item sets they show. The clipboard also works across all item subsets and between all views of a workspace. Every workspace has its own toolbar with its own clipboard controls, but they all use the same, global clipboard to interact with.

...

basic rule to understand

...

the Magnolia clipboard is this: if the clipboard is there, you can

...

copy items to it,

...

replacing any item already in there. And you can paste

...

the item or items in the clipboard, if its type is accepted by your currently selected item.

...

The This also means that the clipboard may be actually missing in a workspace. It should actually only be shown (i.e. not shown with all buttons disabled), if a workspace can make use of it.for a specific view if it isn't properly supported.

However, content cannot be cut (copied and removed at the same time) and pasted later - this would lead to a number of confusing situations when copying across views, in particular if one attempted to cancel the operationBecause the clipboard is a global function, it does not offer a cut operation. It would be unclear how to cancel it, if you switch the context. Instead, the clipboard concentrates on offering powerful copy&paste support only.

Also, when copying an item containing sub items, all the sub items are copied as well. This provides a powerful means to work with item hierarchies. A workspace may Magnolia does not offer a way to only copy an item itself, ignoring all items it may contain. This is mainly to simplify and unify the way the clipboard works, but also describes how the "copy page" function currently works in Magnolia.

The challenge of implementing a clipboard in Magnolia is doing it right across multiple contexts with different types of items. In order to solve this, the clipboard has two main properties:

  • the clipboard is global and
  • it uses converters.

The clipboard is global

In Magnolia, the clipboard is truly global in that it works across all layers and views. If you thus e.g. copy a paragraph in the visual page editing layer, you can then paste that paragraph in structure editing in AdminCentral. While every interface might have their own clipboard controls, they all interact with the same, global clipboard.

A global clipboard is the only implementation not leading to confusing behavior. A per view or per layer implementation would either have to be flushed every time you change between views and layers or would have to remember the item copied last, both of which would result in behavior difficult for the user to understand and anticipate.

The clipboard offers converters

While the clipboard will might typically be used to copy items within the same workspace or even the same view (e.g. to copy pages within the same site structure), Magnolia's global clipboard is more powerful , since as it offers built-in converters. Converters allow the clipboard to convert an item to a different, usually lower-level item type. If you e.g. copy a page in the website workspace, then open a dialog containing a field requiring a URL, pasting the copied page pastes its URL. The global clipboard becomes an even more powerful tool to copy content from here to there.

Magnolia's global clipboard has the following characteristics:

  • any item may be copied
  • the clipboard may offer its item or items in a number of different item types by using converters
  • the selected item acting as the target of a paste operation usually only accepts one item type (e.g. a page)
  • the clipboard tries to satisfy the expected item type by leveraging its built-in converters

a paste action there could actually paste the URL of the copied page.

Similarity with drag'n'drop

Note that this somewhat similar to how while converters may sound difficult to implement, drag and drop support is typically implemented:

...

in common application frameworks already offers a similar type of behavior for quite some time. If you attempt to drop a dragged item, the following happens:

  • the drag source knows the data formats it can offer the dragged items item in
  • the drop target consults the drag source and matches the data formats offered with those it supports
  • the drop target chooses the data format, where most of the data and its structure is are preserved

It might be worth while worthwhile verifying if the two functions could leverage the same internal framework.

Using the clipboard

Please consult the usage summary for a full definition of mouse, touch and keyboard usage.

Preview of

...

Paste operation

If a user right clicks /taps or tap-and-holds the paste function, a tooltip will show the number and type of items currently in the clipboard (e.g. 5 videos or 3 items) and will highlight - this behavior is actually required. Optionally, all items in the current view accepting a paste of the content in the clipboard ^1will be briefly highlighted in addition to this. This effect disappears again if the mouse button is released or the tap ends. Note that releasing the mouse button or ending the tap does not cause a paste operation in this case - you have to click/tap the paste button again to get this behavior.

Please consult the usage summary for a full definition of mouse, touch and keyboard usage definitions.

Mockups

...

As this operation uses less common gestures, it is considered less easy to discover and thus a power user function.

Storyboard

Mockup
Clipboard
Clipboard
Version7
NameClipboard