https://bugzilla.wikimedia.org/show_bug.cgi?id=51154

Ad Huikeshoven <a...@wikimedia.nl> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |a...@wikimedia.nl

--- Comment #9 from Ad Huikeshoven <a...@wikimedia.nl> ---
Adding a signature with VisualEditor can be simulated using a template:

---template code:---
{{{Sign}}}
<noinclude>
This template allows to sign using Visual Editor by adding this template as you
can't enter four tildes <nowiki>~~~~</nowiki> in VE. Enter the template in VE.
Hit Add template. Enter <nowiki>~~~~</nowiki> in the field. Hit Insert
template. Hit Save page. Enter edit summary. Hit Save. Doone.</br>
<templatedata>
{
    "description": "A template to sign using Visual Editor. ",
    "params": {
        "Sign": {
            "aliases": [
                "Signature"
            ],
            "label": "Sign by entering ~~~~ in the field below",
            "description": "Field to enter signature, that is four tildes",
            "default": "Please enter four tildes here",
            "required": true
        }
    }
}
</templatedata>
</noinclude>
---end of template code---

Usage:
Enter the template in VE. Hit Add template. Enter ~~~~ in the field. Hit Insert
template. Hit Save page. Enter edit summary. Hit Save.

Example:
See https://www.mediawiki.org/wiki/Template:VESign. Application of template
tested on https://www.mediawiki.org/wiki/User:Ad_Huikeshoven/test. 

Evaluation:
There might be nicer methods to accomplish the same, maybe using JS (I have no
experiene writing JS). When there is a switch over to Parsoid rendering the
templates mid-edit rather than relying on PHP parser the above solution will
probably break, as will probably do any solution to bug 51146.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
Wikibugs-l mailing list
Wikibugs-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l

Reply via email to