แม่แบบ:Infobox Wikipedia user script

Documentation icon คู่มือการใช้งานแม่แบบ[ดู] [แก้] [ประวัติ] [ล้างแคช]

Usage แก้

This infobox is intended to be used on user script description/documentation pages.

{{{name}}}
[[File:{{{logo}}}|{{{logosize}}}|alt={{{logoalt}}}|upright={{{logoupright}}}|{{{logoalt}}}]]
[[File:{{{screenshot}}}|{{{screenshotsize}}}|alt={{{screenshotalt}}}|upright={{{screenshotupright}}}|{{{screenshotalt}}}]]
{{{screenshot-caption}}}
คำอธิบาย{{{desc}}}
ผู้สร้าง{{{author}}}
Maintainer(s){{{maintainer}}}
สถานะ{{{status}}}
เผยแพร่ครั้งแรก{{{released}}}
รุ่น{{{version}}}
อัปเดต{{{updated}}}
เบราว์เซอร์ที่รองรับ{{{browsers}}}
แบบหน้าตาที่รองรับ{{{skins}}}
ซอร์สโค้ด{{{source}}}
GitHub repository{{{github}}} on GitHub

Full syntax แก้

{{infobox Wikipedia user script
|styled             = 
|bodystyle          = 
|install-target     = 
|name               = 
|logo               = 
|logosize           = 
|logoupright        = 
|logoalt            = 
|logo-caption       = 
|screenshot         = 
|screenshotsize     = 
|screenshotupright  = 
|screenshotalt      = 
|screenshot-caption = 
|desc               = 
|author             = 
|maintainer         = 
|status             = 
|released           = 
|version            = 
|updated            = 
|browsers           = 
|skins              = 
|source             = <!-- or " |mainsource = " or " |beta = " -->
|gitHub             = <!-- or " |Github = " -->
|gitlab             = <!-- or " |GitLab = " -->
|categorize         = <!-- or " |cat = " -->
}}

Example แก้

MyScript
MyScript in action
คำอธิบายDoes something useful
ผู้สร้างUsername
สถานะStable
เผยแพร่ครั้งแรก7 กรกฎาคม 2008; 15 ปีก่อน (2008-07-07)
รุ่น2.1.0
อัปเดต3 มีนาคม 2013; 11 ปีก่อน (2013-03-03)
เบราว์เซอร์ที่รองรับFirefox, Chrome
แบบหน้าตาที่รองรับVector
ซอร์สโค้ดUser:Username/Example.js
{{infobox user script
 | name = MyScript
 | desc = Does something useful
 | author = [[User:Username|Username]]
 | updated = {{start date and age|2013|03|03}}
 | status = Stable
 | released = {{start date and age|2008|07|07}}
 | version = 2.1.0
 | source = [[User:Username/Example.js]]
 | skins = Vector
 | browsers = [[Firefox]], [[Google Chrome|Chrome]]
 | logo = [[File:Wikimedia-logo.svg|50px]]
 | screenshot = [[File:Floater script screenshot.png|300px]]
 | screenshot-caption = MyScript in action
}}
  • Add |styled = yes for an alternate colored version (see second example):
User script
MyScript
คำอธิบายDoes something useful
ผู้สร้างUsername
สถานะStable
เผยแพร่ครั้งแรก7 กรกฎาคม 2008; 15 ปีก่อน (2008-07-07)
รุ่น2.1.0
อัปเดต3 มีนาคม 2013; 11 ปีก่อน (2013-03-03)
เบราว์เซอร์ที่รองรับFirefox, Chrome
แบบหน้าตาที่รองรับVector
ซอร์สโค้ดUser:Username/Example.js
{{infobox user script
 | name = MyScript
 | desc = Does something useful
 | author = [[User:Username|Username]]
 | updated = {{start date and age|2013|03|03}}
 | released = {{start date and age|2008|07|07}}
 | status = Stable
 | version = 2.1.0
 | source = [[User:Username/Example.js]]
 | skins = Vector
 | browsers = [[Firefox]], [[Google Chrome|Chrome]]
 | styled = yes
}}

Parameters แก้

  • name: The name of the script. Defaults to page name.
  • desc: A short description of what the script does.
  • author: The script author's user name.
  • released: When the script was first released.
  • updated: The date of last update. Use {{start date and age}} to automatically display time since the last update.
  • status: Script's development status. You may describe this any way you like, such as alpha/beta/release, or stable/experimental/inactive.
  • source: The source code page.
  • skins: Supported skins.
  • browsers: Supported web browser(s).
  • github: The script's repository on GitHub.
  • gitlab: The script's repository on GitLab.
  • logo: Image file address for logo
  • logoupright: See Module:InfoboxImage: upright=yes displays image at 75% of default size, upright=value with values under 1 scaling the image down (0.9 = 90%) and values greater than 1 scaling the image up (1.15 = 115%).
  • logosize: Logo size in pixels. Use of logoupright is recommended as pixels can vary in size depending on display used.
  • screenshot: Image file address for screenshot
  • screenshotupright: See logoupright.
  • screenshotsize: See logosize.
  • screenshot-caption: Text caption for screenshot
  • styled: Set to yes for an alternate colored version (see example above)
  • categorize: Set to no to prevent categorizing the page into Category:Wikipedia scripts

The following parameters can aid in automatic installation:

  • mainsource: The main source file, which is to be loaded from the user's custom script.
  • install-target: The preferred page on which the script should be included. The default is common.js.

Templatedata แก้

ไม่มีคำอธิบาย

พารามิเตอร์แม่แบบ[แก้ไขข้อมูลแม่แบบ]

This template prefers block formatting of parameters.

พารามิเตอร์คำอธิบายชนิดสถานะ
styledstyled

ไม่มีคำอธิบาย

ไม่ทราบชนิดเลือกได้
bodystylebodystyle

ไม่มีคำอธิบาย

ไม่ทราบชนิดเลือกได้
mainsourcemainsource

ไม่มีคำอธิบาย

ไม่ทราบชนิดเลือกได้
install-targetinstall-target

ไม่มีคำอธิบาย

ไม่ทราบชนิดเลือกได้
namename

ไม่มีคำอธิบาย

ไม่ทราบชนิดเลือกได้
logologo

ไม่มีคำอธิบาย

ไม่ทราบชนิดเลือกได้
logosizelogosize

ไม่มีคำอธิบาย

ไม่ทราบชนิดเลือกได้
logoaltlogoalt

ไม่มีคำอธิบาย

ไม่ทราบชนิดเลือกได้
logo-captionlogo-caption

ไม่มีคำอธิบาย

ไม่ทราบชนิดเลือกได้
screenshotscreenshot

ไม่มีคำอธิบาย

ไม่ทราบชนิดเลือกได้
screenshotsizescreenshotsize

ไม่มีคำอธิบาย

ไม่ทราบชนิดเลือกได้
screenshotaltscreenshotalt

ไม่มีคำอธิบาย

ไม่ทราบชนิดเลือกได้
screenshot-captionscreenshot-caption

ไม่มีคำอธิบาย

ไม่ทราบชนิดเลือกได้
descdesc

ไม่มีคำอธิบาย

ไม่ทราบชนิดเลือกได้
authorauthor

ไม่มีคำอธิบาย

ไม่ทราบชนิดเลือกได้
maintainermaintainer

ไม่มีคำอธิบาย

ไม่ทราบชนิดเลือกได้
statusstatus

ไม่มีคำอธิบาย

ไม่ทราบชนิดเลือกได้
releasedreleased

ไม่มีคำอธิบาย

ไม่ทราบชนิดเลือกได้
versionversion

ไม่มีคำอธิบาย

ไม่ทราบชนิดเลือกได้
updatedupdated

ไม่มีคำอธิบาย

ไม่ทราบชนิดเลือกได้
browsersbrowsers

ไม่มีคำอธิบาย

ไม่ทราบชนิดเลือกได้
skinsskins

ไม่มีคำอธิบาย

ไม่ทราบชนิดเลือกได้
betabeta

ไม่มีคำอธิบาย

ไม่ทราบชนิดเลือกได้
sourcesource

ไม่มีคำอธิบาย

ไม่ทราบชนิดเลือกได้
githubgithub

ไม่มีคำอธิบาย

ไม่ทราบชนิดเลือกได้
gitlabgitlab

ไม่มีคำอธิบาย

ไม่ทราบชนิดเลือกได้