Module:Demo
demo_kill_categories alias nocat
Template:Moved from I've did this change, but it doesn't seem to work. Can somebody with more Lua knowledge take a look? See example here: User:Andrybak/sandbox/demonocat -- note, that page is added to Category:Wikipedians in Russia, but shouldn't be. —andrybak (talk) 11:15, 29 August 2018 (UTC)
Template-protected edit request on 22 March 2019
Template:Edit template-protected
Please remove the line <noinclude>{{pp-template|small=yes}}</noinclude> - protection templates are automatically handled by the documentation page. Thanks, --DannyS712 (talk) 06:39, 22 March 2019 (UTC)
- File:Yes check.svg Done — JJMC89 (T·C) 06:54, 22 March 2019 (UTC)
Syntax highlighting
Please incorporate a parameter to enable syntax highlighting of the preformatted text with <syntaxhighlight lang="{wikitext|html|etc.}">. I've attempted to develop this in the sandbox, without success. —swpbT • beyond • mutual 13:55, 11 May 2023 (UTC)
- I believe the syntax should be highlighted by default. Why not?
wikitextis a good default that would work with HTML as well. BTW, do we even needhtmlas a parameter? Jack who built the house (talk) 08:40, 20 July 2023 (UTC) - So, I've managed to get the code in the sandbox to work. The resulting look is a bit different from Template:Tag: you can't set
display: inlineto Template:Tag, as suggested in Template:Demo. Also, if used without Template:Tag, the templates are replaced with their code, but the code is still treated as code. Compareand[[:Template:Fail]]
{{fail}}. This result is kind of better than with Template:Tag: when there are no templates inside, Template:Tag can be omitted (but people might forget that they haven't used Template:Tag and use a template which will expand). Jack who built the house (talk) 19:52, 20 July 2023 (UTC)
- Please update Module:Demo from Module:Demo/sandbox. Test cases: Template:Demo/testcases. Ping the OP: @Swpb. Jack who built the house (talk) 15:07, 21 July 2023 (UTC)
- Template:Done Sidenote to Template:U, your signature is messed up and should be fixed. * Pppery * it has begun... 21:09, 22 July 2023 (UTC)
- Haha, thanks! Forgot to check a checkbox. I don't even see my signature due to a script, and the author username was displayed correctly :) Jack who built the house (talk) 00:18, 23 July 2023 (UTC)
- Template:Done Sidenote to Template:U, your signature is messed up and should be fixed. * Pppery * it has begun... 21:09, 22 July 2023 (UTC)
Changes announcement
I'm to make an edit to the module with several notable changes that you can see here or in the test cases:
- HTML tags in the code snippet will work (they don't now). So, the template will be able to be used to show demonstrations of any code, not necessarily of templates.
- Markup that must be at the start of the line (like
*,{|) will work. It doesn't work for the first line now. - There will be
|reverse=1parameter to show the code snippet and the result in reverse order. - There will be no Template:Tag after the code snippet by default, because it creates nonfunctional empty space. Many usages of the template try to remove that space. I haven't witnessed cases where it was justified.
|br=will be renamed to|sep=, from "separator" (|br=will still work) because the more popular usage of the parameter is to add some meaningful text between the snippet and the result, not just line breaks.
Jack who built the house (talk) 22:11, 26 July 2023 (UTC)