Module:Shortcut/doc
This module depends on the following other modules: |
This template uses TemplateStyles: |
Template:Lua sidebar This module makes a box showing the shortcut links to a page.
Usage
editFrom wikitext
editFrom wikitext, this module should be called from a template, usually {{Shortcut}}
. Please see the template page for documentation. However, it can also be called using the syntax {{#invoke:shortcut|main|arguments}}
.
From Lua
editTo use this module from Lua, first load it.
local mShortcut = require('Module:Shortcut')
Then you can create shortcut boxes with the following syntax:
mShortcut._main(shortcuts, options, frame, cfg)
- shortcuts: an array of shortcut page names (required)
- options: a table of options with support for the following subkeys
msg
: a message to leave after the list of shortcutscategory
: if set to a "falsy" Boolean value (one regarded as false by Module:Yesno, such as "no"), categorization is suppressed
- frame: is a optional frame object, only intended to be used internally
- cfg: is a table of optional config values, only intended for testing
Technical details
editThis module has a configuration file at Module:Shortcut/config. It can be used to translate this module into different languages or to change details like category names.