https://bugzilla.wikimedia.org/show_bug.cgi?id=17486
--- Comment #28 from Philippe Verdy <[email protected]> --- Note that the intent now is to deprecate the support for valid XHTML, but we still have a problem for HTML5 with the (more lenient) HTML5 parsing rules. We still need to find solution to have a way to ease the integration of templates possibly generating tables (or similar) within our old wiki syntax based on prefixes of single lines (this concerns our syntax for numbered lists, bulleted lists, definition lists/indented blocks, tables, as well as horizontal rulers, base on the first character of lines in "{|!-;:#*", as well as doube newlines for creating new paragraphs). I still think that we should have an alternate way to avoid the syntaxic limitations introduced by newlines and specific parsing at begining of lines, to allow more flexibility, and less problems for parsing them. Our current syntax for tables is the most problematic one, forcing us to use ugly syntaxes in templates, and nightmares when we want to integrat them (e.g. in navigation templates and infoboxes). But bulleted lists and numbered lists still suffer from the lack of support for adding attributes (e.g. in numbered lists we still annot set the initial number, we cannot specify classes or styles) We should be able to use: * item1 *|attributes...| item2 and also allow generation using an explicit list initiator: {*attributes for the list... || item1 |attributes for item2| item2 || item3 || item4 } as if it was a table containing a single row where each item is a cell, except that newlines are trateed here like other whitespaces, so it is equivalent to: {*attributes for the list... || item1 |attributes for item2| item2 || item3 || item4 } or to: {*|attribute...||item1|attributes for item2|item2||item3||item4} This last syntax shows that it allows easy syntaxes in templates. Such syntax will remain integrable into another list, or indented block or in a table cell, for example here with embedded numbered lists: {# ||item1 ||item2 {# ||item2.1 ||item2.2 } ||item3 ||item4 } In such syntax, all newlines are treated like whitespaces, and whitespaces are trimmed, allowing free form for indenting in wiki sources, and easier syntaxes for templates. The previous example could as well be compacted into a single line, with all "cells" fully trimmed: {#||item1||item2{#||item2.1||item2.2}||item3||item4} And optional attributes are specifiable everywhere if needed (between the doubled pipes in this example). The alternative is to just allow the HTML5 syntax and improve its parsing in MediaWiki so that it can be really used everywhere, when our old syntax as problems (HTML5 does not force us to close all tags, this is good for wiki editing, even if it is a bit verbose, but it should not be a problem for creating complex templates like infoboxes, designed by a few competent contributors). But MediaWiki still does not treat HTML tags like its old "simplified" syntax for equivalent tags. Example of limitation, these are not recognized as one list: <ul style="..."> * item1 * item2 </ul> Second example with similar limitation: * item1 <li> item2 * item3 <li> item4 If those limitations were solved, we would have less problems to generate contents by mixing the best of the HTML syntax, when it solves problems in templates, or the "simpler" wiki inherited syntax. We would alno no longer have to suffer the current nightmare of newlines. -- You are receiving this mail because: You are the assignee for the bug. You are on the CC list for the bug. _______________________________________________ Wikibugs-l mailing list [email protected] https://lists.wikimedia.org/mailman/listinfo/wikibugs-l
