[xwiki-devs] Fwd: [xwiki-users] Fwd: [VOTE] New Link and Image syntax for XWiki Syntax 2.2
On Tue, Apr 30, 2013 at 11:09 AM, Vincent Massol <[email protected]> wrote:
Forwarding to users list since it's interesting to know what users think about this for the new XWiki Syntax 2.2 too.
Please give your opinion.
Thanks -Vincent
Begin forwarded message:
From: Vincent Massol <[email protected]> Subject: [VOTE] New Link and Image syntax for XWiki Syntax 2.2 Date: April 30, 2013 11:02:43 AM GMT+02:00 To: XWiki Developers <[email protected]>
Hi devs,
Following this thread http://markmail.org/thread/vw3derowozijqalr it seems clear that we need to introduce a better syntax for links and images in XWiki Syntax 2.2 (in order to cope with use cases such as http://jira.xwiki.org/jira/browse/XRENDERING-290).
The need is to be able to plug new reference type handlers without breaking backward compatibility in XWiki Syntax 2.2 (since right now with XWiki Syntax 2.0 and 2.1 adding a new type reference handler would break backward compatibility).
So here are various proposals to that effect for XWiki Syntax 2.2 (I've only kept the interesting proposals from the previous thread). Please vote for the one you prefer or add new solutions if you have other better ideas.
Proposal 1 =========
Force XWiki Syntax 2.2 to *ALWAYS* use the full form when creating a link or image, i.e. all links would need to be written: [[label>>type:reference]]
Examples: * [[label>>doc:space.page]] * [[label>>doc:wiki:space.page]] * [[label>>path:/some/path]] * [[label>>url:http://xwiki.org]] * [[label>>user:evalica]] * [[image:doc:wiki:[email protected]]] * [[image:icon:someicon.png]]
CONS: * Harder to write links to documents which is the main use case
Proposal 2 =========
Same as with XWiki Syntax 2.1 but for links or images to subwikis force the user to use the "doc:" notation
Examples: * [[label>>space.page]] or [[label>>doc:space.page]] * [[label>>doc:wiki:space.page]] * [[label>>>path:/some/path]] * [[label>>http://xwiki.org]] or [[label>>>url:http://xwiki.org]] * [[label>>user:evalica]] * [[image:doc:wiki:[email protected]]] * [[image:icon:someicon.png]]
PRO: * Still easy to reference docs and images in the current wiki * Close to current XWiki Syntax 2.1
CONS: * Harder to write links to documents in subwikis (for workspaces users for example, see example of xwiki.org)
Proposal 3 =========
Always define the type as a link or image parameter, i.e. separate subwiki notation from type.
Examples: * [[label>>space.page]] or [[label>>space.page||type="doc"]] * [[label>>wiki:space.page]] or [[label>>wiki:space.page||type="doc"]] * [[label>>>/some/path||type="path"]] * [[label>>http://xwiki.org]] or [[label>>>http://xwiki.org||type="url"]] * [[label>>evalica||type="user"]] * [[image:wiki:[email protected]]] or [[image:wiki:[email protected]||type="doc"]] * [[image:someicon.png||type="icon"]]
PRO: * Still easy to reference docs * Clear separation between subwiki and types
Funny thing is that this proposal is compatible with xwiki/2.0 syntax.
CONS: * Harder to write typed links * Harder to write references in non xwiki/2.x syntax that would not support link parameters
Thanks -Vincent
_______________________________________________ users mailing list [email protected] http://lists.xwiki.org/mailman/listinfo/users
I'm more for proposals 1 and 3 for their clarity but I'm pretty sure most people will hate have to put doc: everywhere so here is my +1 for 3 for now. But don't rush I would like to take some more time to think about it. -- Thomas Mortagne
participants (1)
-
Thomas Mortagne