Template talk:Documentation

页面内容不支持其他语言。
维基百科,自由的百科全书

模版部份未翻譯

模版中的

for editors to experiment.

未翻譯為中文。—Chunchun2345 (留言) 2009年6月28日 (日) 06:37 (UTC)[回复]

完成,已翻譯。—街燈電箱150號 開箱維修 抄錶 檢驗證明 2009年6月28日 (日) 06:47 (UTC)[回复]

未翻譯

{{editprotected}}

Template documentation
The above documentation is transcluded from Template:Documentation/doc. (edit | history)
Editors can experiment in this template's sandbox (create) and testcases (create) pages.
Please add categories and interwikis to the /doc subpage. Subpages of this template.
均需翻译。

--UAL55 (留言) 2010年7月14日 (三) 01:26 (UTC)[回复]

麻烦你把上面的内容翻译好后贴在这里,然后再由管理员复制到模板中。--用心阁(对话页) 2010年7月14日 (三) 04:27 (UTC)[回复]
我错误地从英文维基百科复制并覆盖了相同模板。已回退。Liangent (留言) 2010年7月14日 (三) 15:44 (UTC)[回复]

英文

{{editprotected}}同上。

reverted 不知道shizhao在干什么 Liangent (留言) 2010年7月27日 (二) 07:50 (UTC)[回复]

追加“清除緩存”按鈕

{{editprotected}} <!--** /doc 存在** -->[[{{fullurl:{{{1|{{Documentation/docname}}}}}|action=edit}} 編輯]]

加上:

<!--** /doc 存在** -->[[{{fullurl:{{{1|{{Documentation/docname}}}}}|action=purge}} 清除緩存]] [[{{fullurl:{{{1|{{Documentation/docname}}}}}|action=edit}} 編輯]]

因為有時候就算是在Firefox按ctrl/shift+F5都依然未能刷新出doc頁的新版本,必須手動進行purge。-- 同舟留言2012年3月27日 (二) 02:53 (UTC)[回复]

完成 Liangent (留言) 2012年3月27日 (二) 09:16 (UTC)[回复]
貌似应该让用户purge后看模板页较好。Liangent (留言) 2012年3月27日 (二) 09:19 (UTC)[回复]

::增加purge按鈕就是為了在模板本頁看到doc更新後的效果。還有有一點不懂的是,追加purge按鈕後其生成的地址居然額外多了版本的代碼,是mediawiki更新v1.19後修訂的?-- 同舟留言2012年3月27日 (二) 09:44 (UTC)[回复]

Documentation

English: I would like to add these updated codes please

<!--
  Automatically add {{template sandbox notice}} when on a /sandbox page.
-->{{#ifeq: {{SUBPAGENAME}} | sandbox
| <div style="clear: both;"></div>{{template sandbox notice|{{{livepage|}}}}}
}}<!--
  Automatically add {{pp-template}} to protected templates.
-->{{template other
| {{#ifeq: {{PROTECTIONLEVEL:move}} | sysop
  | {{pp-template|docusage=yes}}
  | {{#if: {{PROTECTIONLEVEL:edit}}
    | {{pp-template|docusage=yes}}
    | <!--Not protected, or only semi-move-protected-->
    }}
  }}
}}<!--
  Start of green doc box.
-->{{documentation/start box2
| preload = {{{preload|}}}   <!--Allow custom preloads-->
| heading = {{{heading|¬}}}   <!--Empty but defined means no header-->
| heading-style = {{{heading-style|}}}
| content = {{{content|}}}

<!--Some namespaces must have the /doc, /sandbox and /testcases 
    in talk space-->
| docspace = {{documentation/docspace}}

| 1 = {{{1|}}}   <!--Other docname, if fed-->

<!--The namespace is added in /start box2-->
| template page = {{documentation/template page}}

}}<!-- Start content --><!--
  Start load the /doc content:
  Note: The line breaks between this comment and the next line are necessary
  so  "=== Headings ===" at the start and end of docs are interpreted.
-->
{{#switch: {{#if:{{{content|}}}|1|0}}{{#if:{{{1|}}}|1|0}}{{#ifexist:{{{1|}}}|1|0}}{{#ifexist:{{documentation/docspace}}:{{documentation/template page}}/doc|1|0}}
| 1000 | 1001 | 1010 | 1011 | 1100 | 1101 | 1110 
| 1111 = {{{content|}}}
| 0110 | 0111 = {{ {{{1}}} }}
| 0001 | 0011 = {{ {{documentation/docspace}}:{{documentation/template page}}/doc }}
| 0000 | 0100 | 0010 | 0101 = 
}}
<!--
  End load the /doc content:
  Note: The line breaks between this comment and the previous line are necessary
  so  "=== Headings ===" at the start and end of docs are interpreted.
-->{{documentation/end box2
| preload = {{{preload|}}}   <!--Allow custom preloads-->
| content = {{{content|}}}
| link box = {{{link box|}}}   <!--So "link box=off" works-->

<!--Some namespaces must have the /doc, /sandbox and /testcases 
    in talk space-->
| docspace = {{documentation/docspace}}

| 1 = {{{1|}}}   <!--Other docname, if fed-->

<!--The namespace is added in /end box2-->
| template page = {{documentation/template page}}

}}<!--
  End of green doc box
--><noinclude>

<!-- Add categories and interwikis to the /doc subpage, not here! -->
</noinclude>

90.222.250.124留言2013年1月12日 (六) 00:05 (UTC)[回复]

[刷新]

「[刷新]」這個字符位於何處?請求加上字詞轉換。

「[-{zh-hans:刷新; zh-hant:重新整理;}-]」或者「[-{zh-hans:刷新缓存; zh-hant:清除快取;}-]」。-- By LNDDYL.(留言2014年6月14日 (六) 03:01 (UTC)[回复]

希望能把模板/模块文档也Lua化

{{editprotected}} 也就是希望导入en:Module:Documentation吴语版刚刚导入了这一模块。--Liuxinyu970226留言2014年11月4日 (二) 08:00 (UTC)[回复]

已导入,按照英文维百,应该用这种方式调用:
{{#invoke:documentation|main|_content={{ {{#invoke:documentation|contentTitle}}}}}}<noinclude>
<!-- Categories go on the /doc subpage, and interwikis go on Wikidata. -->
</noinclude>
-- 2014年11月24日 (一) 05:15 (UTC)[回复]
这里有一个示范。-- 2014年11月26日 (三) 10:59 (UTC)[回复]
意义是?--Jimmy Xu 2014年11月26日 (三) 14:10 (UTC)[回复]
刚才发现这个模板已经搞定了,感谢导入这个模块的管理员。-- 2017年1月4日 (三) 17:11 (UTC)[回复]

模板文档的绿色背景能改回来吗


近几天书生把模板文档页的底色改成了蓝色,说是为了配合mw的新版配色方案。但绝大多数语种的wiki模板文档页还是绿色背景,突然改成蓝色未免有些奇怪,不知可不可以改回来。--Dabao qian留言2017年2月5日 (日) 13:38 (UTC)[回复]

 已修复,应该是改的时候不留神改多了--百無一用是書生 () 2017年2月6日 (一) 13:08 (UTC)[回复]

编辑请求

请求已处理

我希望把“模板文档”中的“清除”换成“清除缓存”,因为“清除”容易被误解为清除文档本身。 --CRSKY留言2017年6月8日 (四) 10:45 (UTC)[回复]

这个没什么问题,放几天看没意见我就改了。(其实模块:Documentation/config没有被保护,楼主可以自己改……) --砜中嘌呤的白磷萃取 打谱 2017年6月8日 (四) 11:17 (UTC)[回复]
完成。 --砜中嘌呤的白磷萃取 打谱 2017年6月9日 (五) 04:36 (UTC)[回复]
现在模块:Documentation/config被保护了。--SolidBlock留言 2017年8月5日 (六) 10:39 (UTC)[回复]

对模块中一些内容的细节的问题

比如,模块中定义了makeToolbar函数,为什么还有复制到p.makeToolbar?是不是如果函数不输出到p中则无法使用(我没有遇到过这样的情况)?或者是为了在调试控制台中使用?还是为了让其他的模块中使用(没有发现任何模块中出现了require("Module:Documentation")这样的词)。此外,为什么要将内容文字单独保存到/config页面?直接调用字符串也很方便啊。此外,里面一些参数转来转去,例如p.renderStartBoxLinks函数中,直接将data.docTitle和data.title代入到makeWikiLink货makeUrlLink函数中即可,为什么要先复制到局部变量docTitle和title再去代入函数?(我猜测是为了代码略微简略一些。)--SolidBlock留言 2017年8月5日 (六) 10:38 (UTC)[回复]

应该是考虑兼容性和移植性。--SolidBlock留言 2019年10月25日 (五) 15:47 (UTC)[回复]

編輯請求 2021-04-24

请求已处理--Xiplus#Talk 2021年5月1日 (六) 13:34 (UTC)[回复]

742行:

text = text .. ' ' .. (p.makeSubpagesBlurb(args, env) or '') --"Subpages of this template"

请修改为:

text = text .. (p.makeSubpagesBlurb(args, env) or '') --"Subpages of this template"

理由:中文标点符号之后不需要有空格。目前“请在/doc子页面中添加分类。”和“本模板的子页面。”中间有一个空格,显然是因为该代码从英文维基百科复制时没有注意到这一点。--Tranve () 2021年4月24日 (六) 07:29 (UTC)[回复]

此两小句之间无关联,不加空格可能会让人引起此两句之间有关联的误会,造成理解上的障碍。--LaMagiaaa 2021年4月26日 (一) 05:29 (UTC)[回复]
我认为不会。一般人不仔细看的话甚至根本不会注意到这里还有一个空格。另外,中文标点符号后不加空格应该是规范。英文维基百科的本模板也只是加了一个空格(因为英文标点符号后应该加一个空格),并没有多余的空隙,说明没有引起理解上的障碍。--Tranve () 2021年5月1日 (六) 01:08 (UTC)[回复]