Content deleted Content added
m Archiving 1 discussion(s) from Template talk:Documentation) (bot |
m Archiving 2 discussion(s) from Template talk:Documentation) (bot |
||
Line 346:
:Also, would it be better to put the templatedata in-between the documentation and the bottom box rather than at the end? -- [[User:WOSlinker|WOSlinker]] ([[User talk:WOSlinker|talk]]) 23:11, 14 January 2014 (UTC)
::Technically, it is not part of the documentation. I would say no. <span style="font-family:'Trebuchet MS'"> — [[User:Edokter|<span style="color:#008"><i>E</i>dokter</span>]] ([[User talk:Edokter|<span style="color:#080">talk</span>]]) — </span> 23:17, 14 January 2014 (UTC)
== Module:Documentation ready to deploy ==
I've been working on [[Module:Documentation]] for a while now, and it is just about ready for deployment. It is intended to be a workalike of the current {{tl|documentation}} template, so it should have all the familiar features. It is also intended to be portable, and it has a configuration module at [[Module:Documentation/config]] that can be edited for use with different languages and wiki setups. It also has one new parameter, the {{para|page}} parameter, where you can set the "current" page for testing purposes. You can use {{tl|documentation/sandbox}} to test it on wiki pages. Test cases are at [[Module:Documentation/testcases]] ([[Module talk:Documentation/testcases|run tests]]), and there are also some old test cases at [[Template:Documentation/testcases]]. Having {{tl|documentation}} in Lua means that we have a lot more flexibility, so if there are new features that people have been wanting to put in then now would be a good time to ask. And please have a play around with it, see if you can find any bugs, and generally see what you think. <small>Pings for recent participants on this talk page: {{ping|Edokter|Redrose64|Patrick87|PartTimeGnome|Cenarium|Debresser|WOSlinker}} {{ping|Gadget850|TheDJ|VanIsaac|Helder.wiki}}</small> — '''''[[User:Mr. Stradivarius|<span style="color: #194D00; font-family: Palatino, Times, serif">Mr. Stradivarius</span>]]''''' <sup>[[User talk:Mr. Stradivarius|♪ talk ♪]]</sup> 07:26, 28 January 2014 (UTC)
:Excellent work! Would it be possible to have a show/hide button at the top right? Would be very useful when previewing/editing a template with a large doc page. Thanks. --[[User:NSH002|NSH002]] ([[User talk:NSH002|talk]]) 12:55, 29 January 2014 (UTC)
::That's an interesting idea. I've created a mock-up of how this would look in [https://en.wikipedia.org/w/index.php?title=User:Mr._Stradivarius/Sandbox&oldid=593070827 my sandbox]. I think it may be more useful for Lua modules than templates, as the template output almost always comes above the documentation, whereas for Lua modules it is the other way round. Are you thinking that it would save scrolling back to the edit window ''after'' you have previewed the template output? Also, this would be quite a big change internally for the template, as we have to switch everything from {{tag|div}} tags to {{tag|table}} tags or the collapsing doesn't work. For that reason, I'd want to make sure that there's a consensus for this change before deciding to implement it. (Perhaps this could be discussed after the initial switch to the module.) — '''''[[User:Mr. Stradivarius|<span style="color: #194D00; font-family: Palatino, Times, serif">Mr. Stradivarius</span>]]''''' <sup>[[User talk:Mr. Stradivarius|♪ talk ♪]]</sup> 05:29, 30 January 2014 (UTC)
:::To clarify, the idea is to reduce the amount of scrolling up/down between the edit box at the bottom and the template output at the top. I like to do my edits in one big go, so I do a lot of tweak/preview cycles. Would be even better if it maintained its state between change/preview cycles, but I don't suppose that would be easy! I trust your judgement on the best way to proceed. --[[User:NSH002|NSH002]] ([[User talk:NSH002|talk]]) 11:00, 31 January 2014 (UTC)
::::That's fair enough. I don't think it's possible for it to save its state, though, at least not just with template/module code. I think we should wait to see what others say about this, and then implement it on the module's next iteration if it seems to have support. In fact, I think I will go and make the switchover now. Please keep an eye out for documentation templates that behave strangely! — '''''[[User:Mr. Stradivarius|<span style="color: #194D00; font-family: Palatino, Times, serif">Mr. Stradivarius</span>]]''''' <sup>[[User talk:Mr. Stradivarius|♪ talk ♪]]</sup> 11:12, 31 January 2014 (UTC)
:A feature suggestion: It would be nice if there were some way to automatically change the content in the template sandbox to match that in the main version, or the other way around (e.g. by clicking a link that says "Update sandbox" or something like that). This would be useful since many edits of that kind are done when work on a sandbox version is finished and it's being migrated to the main template. There already is functionality of this kind (the "clone" link), but it only works when the sandbox version does not exist. [[User:APerson|APerson]] ([[User talk:APerson|talk!]]) 17:38, 31 January 2014 (UTC)
::Unfortunately, the cloning isn't perfect, as the MediaWiki feature it is based on wasn't originally designed for this kind of use. Anything that is contained in {{tag|noinclude}} tags would not copied across, which would mean we would lose the documentation. Copying and pasting is probably the way to go until we can work out a way to transfer everything over without being altered. I will note that it works very well for Lua modules, however, as they generally don't (can't?) use tags like {{tag|noinclude}}. — '''''[[User:Mr. Stradivarius|<span style="color: #194D00; font-family: Palatino, Times, serif">Mr. Stradivarius</span>]]''''' <sup>[[User talk:Mr. Stradivarius|♪ talk ♪]]</sup> 18:07, 31 January 2014 (UTC)
:::I wasn't talking about the documentation being copied, just the template code. This would be useful when working with large and complex templates. [[User:APerson|APerson]] ([[User talk:APerson|talk!]]) 18:48, 31 January 2014 (UTC)
::::I did mean the template code. Specifically, the part that looks like this:
<pre>
<noinclude>
{{documentation}}
</noinclude>
</pre>
::::You generally want to include this when copying code to and from the sandbox, but this isn't currently possible as the {{tag|noinclude}} tags and all the code contained within them are stripped. We would need to change the MediaWiki software in order to copy code with no changes at all. — '''''[[User:Mr. Stradivarius|<span style="color: #194D00; font-family: Palatino, Times, serif">Mr. Stradivarius</span>]]''''' <sup>[[User talk:Mr. Stradivarius|♪ talk ♪]]</sup> 03:05, 1 February 2014 (UTC)
== VisualEditor makes [view] become [edit source] ==
When I enable VisualEditor, "[view]" from the row besides "Template/Module documentation" ([view] [edit] [history] [purge]) becomes [edit source]. Can you fix it? Thank you. --[[User:Nullzero|Nullzero]] ([[User talk:Nullzero|talk]]) 13:59, 31 January 2014 (UTC)
:The {{tl|documentation}} template has been behaving this way for a while now, and I agree that it is a bit annoying. We could fix it with inline styling, once we figure out what the correct styling is, but I have a feeling that it might be better to fix it at the source. The first step would be to find out where the mw-editsection class lives, as that's the one that is being altered by VisualEditor. I'm not sure where it is off the top of my head though. — '''''[[User:Mr. Stradivarius|<span style="color: #194D00; font-family: Palatino, Times, serif">Mr. Stradivarius</span>]]''''' <sup>[[User talk:Mr. Stradivarius|♪ talk ♪]]</sup> 14:57, 31 January 2014 (UTC)
::Use <code>mw-editsection-like</code> instead of <code>mw-editsection</code> see discussion at - [[Wikipedia:Village_pump_(technical)/Archive_117#Template_documentation_header_problem]] --[[User:Lam-ang|Lam-ang]] ([[User talk:Lam-ang|talk]]) 15:35, 31 January 2014 (UTC)
:::Nice find, thank you. :) It should be fixed now. — '''''[[User:Mr. Stradivarius|<span style="color: #194D00; font-family: Palatino, Times, serif">Mr. Stradivarius</span>]]''''' <sup>[[User talk:Mr. Stradivarius|♪ talk ♪]]</sup> 17:55, 31 January 2014 (UTC)
::::Ah, one problem with this: [[MediaWiki:Gadget-righteditlinks.css]] ("{{int:gadget-righteditlinks}}") no longer works on these links now the class has been changed. The simplest fix would be to update the gadget to function on both <code>.mw-editsection</code> and <code>.mw-editsection-like</code>. – '''[[User:PartTimeGnome|PartTimeGnome]]''' <span style="font-size:79%">([[User talk:PartTimeGnome|talk]] | [[Special:Contributions/PartTimeGnome|contribs]])</span> 21:36, 31 January 2014 (UTC)
:::::Ok, I've applied a fix to [[MediaWiki:Gadget-righteditlinks.css]]. It appears to be working in my tests, but let me know if you notice anything strange. — '''''[[User:Mr. Stradivarius|<span style="color: #194D00; font-family: Palatino, Times, serif">Mr. Stradivarius</span>]]''''' <sup>[[User talk:Mr. Stradivarius|♪ talk ♪]]</sup> 03:41, 1 February 2014 (UTC)
:{{od|::::}}Thank you! That looks fine. – '''[[User:PartTimeGnome|PartTimeGnome]]''' <span style="font-size:79%">([[User talk:PartTimeGnome|talk]] | [[Special:Contributions/PartTimeGnome|contribs]])</span> 16:21, 1 February 2014 (UTC)
|