Difference between revisions of "Module:Submit an edit request/config/sandbox"
Jump to navigation
Jump to search
blackwiki>Mr. Stradivarius (Create sandbox version of Module:Submit an edit request/config) |
blackwiki>Mr. Stradivarius (structure the protection level data here, so that we don't have to do it in the main module) |
||
| Line 1: | Line 1: | ||
-- This module contains configuration data for [[Module:Submit an edit request]]. | -- This module contains configuration data for [[Module:Submit an edit request]]. | ||
| − | + | return { | |
-------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | ||
| − | -- | + | -- Messages |
-------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | ||
-- The default display value for edit requests. | -- The default display value for edit requests. | ||
| − | + | ['default-display-value'] = 'Submit an edit request', | |
-- The template that stores the edit request preload text | -- The template that stores the edit request preload text | ||
| − | + | ['preload-template'] = 'Template:Submit an edit request/preload', | |
-- The section heading that is generated when a user clicks on an edit request | -- The section heading that is generated when a user clicks on an edit request | ||
| Line 17: | Line 17: | ||
-- "Template-protected". $2 is the current date, in the format specified by the | -- "Template-protected". $2 is the current date, in the format specified by the | ||
-- "preload-title-date-format" message. | -- "preload-title-date-format" message. | ||
| − | + | ['preload-title-text'] = '$1 edit request on $2', | |
-- The date format for the automatically-generated section heading. The format | -- The date format for the automatically-generated section heading. The format | ||
-- must be valid input for the #time parser function. | -- must be valid input for the #time parser function. | ||
| − | + | ['preload-title-date-format'] = 'j F Y', | |
-- The names of the templates to be used as wrappers for the "link" and "button" | -- The names of the templates to be used as wrappers for the "link" and "button" | ||
-- functions. These are passed as arguments to the "wrappers" option of | -- functions. These are passed as arguments to the "wrappers" option of | ||
-- [[Module:Arguments]]. | -- [[Module:Arguments]]. | ||
| − | + | ['link-wrapper-template'] = 'Template:Submit an edit request/link', | |
| − | + | ['button-wrapper-template'] = 'Template:Submit an edit request', | |
-------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | ||
-- Protection level config | -- Protection level config | ||
-------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | ||
| + | |||
| + | protectionLevels = { | ||
--[[ | --[[ | ||
| Line 51: | Line 53: | ||
-- Semi-protection | -- Semi-protection | ||
| − | + | semi = { | |
| − | + | editIntro = 'Template:Edit semi-protected/editintro', | |
| − | + | requestTemplate = 'edit semi-protected', | |
| + | protectionLevel = 'Semi-protected', | ||
| + | }, | ||
-- Template-protection | -- Template-protection | ||
| − | + | template = { | |
| − | + | editIntro = 'Template:Edit template-protected/editintro', | |
| − | + | requestTemplate = 'edit template-protected', | |
| + | protectionLevel = 'Template-protected', | ||
| + | }, | ||
-- Full protection | -- Full protection | ||
| − | + | full = { | |
| − | + | editIntro = 'Template:Edit protected/editintro', | |
| − | + | requestTemplate = 'edit protected', | |
| + | protectionLevel = 'Protected', | ||
| + | }, | ||
| + | |||
| + | } | ||
| − | + | } | |
Revision as of 05:12, 18 March 2015
Documentation for this module may be created at Module:Submit an edit request/config/sandbox/doc
-- This module contains configuration data for [[Module:Submit an edit request]].
return {
--------------------------------------------------------------------------------
-- Messages
--------------------------------------------------------------------------------
-- The default display value for edit requests.
['default-display-value'] = 'Submit an edit request',
-- The template that stores the edit request preload text
['preload-template'] = 'Template:Submit an edit request/preload',
-- The section heading that is generated when a user clicks on an edit request
-- link. $1 is the protection level text, e.g. "Semi-protected" or
-- "Template-protected". $2 is the current date, in the format specified by the
-- "preload-title-date-format" message.
['preload-title-text'] = '$1 edit request on $2',
-- The date format for the automatically-generated section heading. The format
-- must be valid input for the #time parser function.
['preload-title-date-format'] = 'j F Y',
-- The names of the templates to be used as wrappers for the "link" and "button"
-- functions. These are passed as arguments to the "wrappers" option of
-- [[Module:Arguments]].
['link-wrapper-template'] = 'Template:Submit an edit request/link',
['button-wrapper-template'] = 'Template:Submit an edit request',
--------------------------------------------------------------------------------
-- Protection level config
--------------------------------------------------------------------------------
protectionLevels = {
--[[
-- These settings are for the different protection levels which the module can
-- output edit request links for.
--
-- editintro:
-- The template to use as the edit intro users see when they click on an edit
-- request link.
--
-- request-template:
-- The name of the edit request template for that protection level. Do not
-- include the "Template:" text.
--
-- protectionlevel:
-- The name of the protection level, used for formatting the automatically-
-- generated section headings.
--]]
-- Semi-protection
semi = {
editIntro = 'Template:Edit semi-protected/editintro',
requestTemplate = 'edit semi-protected',
protectionLevel = 'Semi-protected',
},
-- Template-protection
template = {
editIntro = 'Template:Edit template-protected/editintro',
requestTemplate = 'edit template-protected',
protectionLevel = 'Template-protected',
},
-- Full protection
full = {
editIntro = 'Template:Edit protected/editintro',
requestTemplate = 'edit protected',
protectionLevel = 'Protected',
},
}
}