Module:Protection banner/config: Difference between revisions

use the old banner config style, but with the new parameter name scheme, and make more messages based on sentences rather than on snippets
(further conversion to new bannerData scheme)
(use the old banner config style, but with the new parameter name scheme, and make more messages based on sentences rather than on snippets)
Line 90: Line 90:
-- enclosed in curly braces). Available parameters:
-- enclosed in curly braces). Available parameters:
--
--
-- ${PAGETYPE} - the type of the page, e.g. "article" or "template".
-- ${CURRENTVERSION} - a link to the page history or the move log, with the
-- Defined in the cfg.pagetypes table.
-- display message "current-version-edit-display" or
-- "current-version-move-display".
--
-- ${DELETIONDISCUSSION} - a link to the deletion discussion, if a link
-- to it was specified.
--
-- ${DISPUTEBLURB} - a blurb about editing disputes, using the INTROBLURB
-- parameter and the DISPUTESECTION parameter. E.g. "This page is protected
-- from editing until disputes have been resolved."
--
-- ${DISPUTESECTION} - if a section link is passed to the module, this is
-- a link to that section with the display message
-- "dispute-section-link-display". Otherwise it is just the display
-- message with no link.
--
--
-- ${PROTECTIONLEVEL} - the protection level, e.g. "fully protected" or
-- ${EDITREQUEST} - a link to create an edit request for the current page.
-- "semi-protected".
--
--
-- ${EXPIRY} - the protection expiry date in the format DD Month YYYY. If
-- ${EXPIRY} - the protection expiry date in the format DD Month YYYY. If
-- protection is indefinite or is not set, this is the blank string.
-- protection is indefinite or is not set, this is the blank string.
--
--
-- ${EDITREQUEST} - a link to create an edit request for the current page.
-- ${EXPLANATIONBLURB} - an explanation blurb, e.g. "Please discuss any changes
-- on the talk page; you may submit a request to ask an administrator to make
-- an edit if it is minor or supported by consensus."
--
-- ${INTROBLURB} - the PROTECTIONBLURB parameter, plus the expiry if an expiry
-- is set. E.g. "Editing of this page by new or unregistered users is currently
-- disabled until dd Month YYYY"
--
-- ${PAGETYPE} - the type of the page, e.g. "article" or "template".
-- Defined in the cfg.pagetypes table.
--
-- ${PROTECTIONBLURB} - a blurb explaining the protection level of the page, e.g.
-- "Editing of this page by new or unregistered users is currently disabled"
--
--
-- ${TALKPAGELINK} - a link to the talk page. If a section is specified, links
-- ${PROTECTIONDATEBLURB} - a blurb explaining when the page was protected, e.g.
-- straight to that talk page section.
-- "It was protected
--
--
-- ${DELETIONREASONSBLURB} - a blurb about why the page was deleted. For
-- ${PROTECTIONLEVEL} - the protection level, e.g. "fully protected" or
-- example, "Please see the deletion discussion or the protection log for
-- "semi-protected".
-- details of why this page was deleted." Uses the message
-- "deletion-discussion-blurb-xfd" if a link to a deletion discussion is
-- present, or "deletion-discussion-blurb-noxfd" if not.
--
--
-- ${PROTECTIONLOG} - a link to the protection log or the pending changes log,
-- ${PROTECTIONLOG} - a link to the protection log or the pending changes log,
-- depending on the protection action.
-- depending on the protection action.
--
-- ${TALKPAGE} - a link to the talk page. If a section is specified, links
-- straight to that talk page section.
--
-- ${TOOLTIPBLURB} - uses the PAGETYPE, PROTECTIONTYPE and EXPIRY parameters to
-- create a blurb like "This template is semi-protected", or "This article is
-- move-protected until DD Month YYYY".
--]]
--]]


cfg.bannerDataNamespaceHasPriority = {
-- If the reason specified to the template is listed in this table,
-- namespace data will take priority over reason data in the bannerData
-- table.
vandalism = true,
}
cfg.bannerDataNamespaceKeys = {
-- The string to use as a namespace key for bannerData for each
-- namespace number.