Jump to content

Module:Editnotice load/doc

From Wikipedia, the free encyclopedia
Editnotice load
DescriptionThis module is an advanced editnotice loader.
Author(s)User:Awesome Aasim
Code sourceEditnotice load
StatusAlpha
Dependencies

This module is an advanced editnotice loader. WIP

Features:

  • Category editnotices
  • Editnotices based on page ID
  • Group notices by prefixes

Relevant pages:

Documentation

Package items

Editnotice_load.page(frame) (function)
Gets the page the editnotice belongs to
Parameter: frame the calling frame (table)
Returns: the page by which the editnotice belongs (string)
Editnotice_load.getEditnotice(frame, noticeArgs, title, type) (function)
Gets any editnotice and its associated data
Parameters:
frame the processing frame (table)
noticeArgs the arguments to pass to the editnotice (table)
title the string for the page the editnotice belongs to (string)
type the editnotice type (string)
Returns: a table with the editnotice name and contents (table)
Editnotice_load.showEditnotice(builder, links, editnoticeData, editnoticeName, editnoticeClass) (function)
Shows any editnotice
Parameters:
builder the builder for the editnotice (table)
links a container for all the links (table)
editnoticeData a table with editnotice data from p.getEditnotice (table)
editnoticeName the name of the editnotice (string)
editnoticeClass the class to add to the editnotice (string)
Editnotice_load.protectionEditnotice(frame) (function)
Generates only the contents for protection editnotices
Parameter: frame the preprocessing frame (table)
Returns: builder the editnotice contents (string)
Editnotice_load.editnotice(frame) (function)
Gets the editnotice type
Parameter: frame the preprocessing frame (table)
Returns: type the string corresponding to the type (string)
Editnotice_load.main(frame) (function)
The main entry point for the editnotice loader
Parameter: frame the preprocessing frame (table)
Returns: output the output of the module (string)

Other items

getEditnoticeType(title) (function)
Gets the editnotice type of any editnotice
Parameter: title a title object for the editnotice (table)
Returns: the editnotice type (string)
getEditnoticeMainPage(currPage, editnoticeType) (function)
Gets the page that the editnotice is stored
Parameters:
currPage the page the editnotice is being displayed on (table)
editnoticeType the editnotice type (table)
Returns: the page which has the editnotice (string)