Jump to content

User contributions for Thehighwayman

A user with 540 edits. Account created on 23 February 2025.
Search for contributionsExpandCollapse
⧼contribs-top⧽
⧼contribs-date⧽
(newest | oldest) View ( | ) (20 | 50 | 100 | 250 | 500)

13 March 2025

  • 02:2002:20, 13 March 2025 diff hist +515 N Module:Test2 Created page with "function splitLines(text) local lines = {} for line in text:gmatch("[^\r\n]+") do table.insert(lines, line) end return lines end local p = {} function p.Sitename(frame) local extDataTable = mw.ext.externalData.getExternalData(frame.args[1])[1]["__text"] local dataLines = splitLines(extDataTable) local sitename = '' for i,line in ipairs(dataLines) do if line:match("og:site_name") then sitename = line:match('content="([^"]+)"') break..."
  • 02:2002:20, 13 March 2025 diff hist 0 m Module:Test Protected "Module:Test" ([Edit=Allow only administrators] (indefinite) [Move=Allow only administrators] (indefinite)) current
  • 02:1902:19, 13 March 2025 diff hist +454 N Module:Test Created page with "local p = {} function p.test( frame ) -- Get contents of page local pageContent = tostring(mw.title.getCurrentTitle():getContent()) -- Split contents of page in lines local pageLines = mw.text.split(pageContent,'\n',true) local render = '' for i=1,#pageLines do -- Get every line starting with '==', that is, a header if mw.text.split(pageLines[i], '%s')[1] == '==' then render = render .. pageLines[i] end end return render end return p"
  • 02:1902:19, 13 March 2025 diff hist 0 m Module:TOC Protected "Module:TOC" ([Edit=Allow only administrators] (indefinite) [Move=Allow only administrators] (indefinite)) current
  • 02:1902:19, 13 March 2025 diff hist +3,307 N Module:TOC Created page with "local p = {} -- creates a table to capture data processed here function p.main( frame ) -- create function which will process data from the template (which is the frame). Currently the template is Template:Custom TOC -- Inside Custom TOC it essentially performs {{#invoke:TOC|main}} which invokes this module and calls the function main local args = frame:getParent().args -- creates a table "args" capturing data from template's transclusion, that is, when the template..."
  • 02:1802:18, 13 March 2025 diff hist 0 m Module:Sidebar/styles.css Protected "Module:Sidebar/styles.css" ([Edit=Allow only administrators] (indefinite) [Move=Allow only administrators] (indefinite)) current
  • 02:1802:18, 13 March 2025 diff hist +3,836 N Module:Sidebar/styles.css Created page with "{{pp-template}}: TODO: Invert width design to be "mobile first": .sidebar { TODO: Ask if we should have max-width 22em instead: width: 25em; @noflip: float: right; @noflip: clear: right; @noflip: margin: 0.5em 0 1em 1em; background-color: var(--color-surface-2); border: 1px solid #aaa; padding: 0.2em; border-spacing: 0.4em 0; text-align: center; line-height: 1.4em; font-size: 88%; /* Timeless has display: none on .nomobile at..."
  • 02:1702:17, 13 March 2025 diff hist 0 m Module:Sidebar/configuration Protected "Module:Sidebar/configuration" ([Edit=Allow only administrators] (indefinite) [Move=Allow only administrators] (indefinite)) current
  • 02:1702:17, 13 March 2025 diff hist +1,595 N Module:Sidebar/configuration Created page with "return { i18n = { child_yes = 'yes', float_none = 'none', float_left = 'left', wrap_true = 'true', navbar_none = 'none', navbar_off = 'off', default_list_title = 'List', title_not_to_add_navbar = 'Template:Sidebar', collapse_title_not_to_add_navbar = 'Template:Sidebar with collapsible lists', templatestyles = 'Module:Sidebar/styles.css', category = { child = '', conversion = '' }, pattern = { collapse_sandbox = '/sandbox$', sandbox..."
  • 02:1502:15, 13 March 2025 diff hist 0 m Module:Sidebar Protected "Module:Sidebar" ([Edit=Allow only administrators] (indefinite) [Move=Allow only administrators] (indefinite)) current
  • 02:1402:14, 13 March 2025 diff hist +10,521 N Module:Sidebar Created page with "-- -- This module implements {{Sidebar}} -- require('Module:No globals') local cfg = mw.loadData('Module:Sidebar/configuration') local p = {} local getArgs = require('Module:Arguments').getArgs --[[ Categorizes calling templates and modules with a 'style' parameter of any sort for tracking to convert to TemplateStyles. TODO after a long cleanup: Catch sidebars in other namespaces than Template and Module. TODO would probably want to remove /log and /archive as CS1 do..."
  • 02:1302:13, 13 March 2025 diff hist 0 m Module:Selected recent additions Protected "Module:Selected recent additions" ([Edit=Allow only administrators] (indefinite) [Move=Allow only administrators] (indefinite)) current
  • 02:1102:11, 13 March 2025 diff hist +5,330 N Module:Selected recent additions Created page with "local randomModule = require('Module:Random') function cleanupArgs(argsTable) local cleanArgs = {} for key, val in pairs(argsTable) do if type(val) == 'string' then val = val:match('^%s*(.-)%s*$') if val ~= '' then cleanArgs[key] = val end else cleanArgs[key] = val end end return cleanArgs end function isAffirmed(val) if not(val) then return false end local affirmedWords = ' add added affirm affirmed include included on true yes y ' return..."
  • 02:1102:11, 13 March 2025 diff hist 0 m Module:Reply to Protected "Module:Reply to" ([Edit=Allow only administrators] (indefinite) [Move=Allow only administrators] (indefinite)) current
  • 02:1102:11, 13 March 2025 diff hist +1,667 N Module:Reply to Created page with "local p = {} local function makeError(msg) msg ='Error in Template:Reply to: ' .. msg return mw.text.tag('strong', {['class']='error'}, msg) end function p.replyto(frame) local origArgs = frame:getParent().args local args = {} local maxArg = 1 local usernames = 0 for k, v in pairs(origArgs) do if type(k) == 'number' then if mw.ustring.match(v,'%S') then if k > maxArg then maxArg = k end usernames = usernames + 1 local title = mw.title.new(v)..."
  • 02:1002:10, 13 March 2025 diff hist 0 m Module:Reading time Protected "Module:Reading time" ([Edit=Allow only administrators] (indefinite) [Move=Allow only administrators] (indefinite)) current
  • 02:0902:09, 13 March 2025 diff hist +1,864 N Module:Reading time Created page with "-- Calculate estimated reading time for any page rounded to multiple of 5. Outputs "X-Y minutes". -- invoke on any page or template with {{#invoke:Reading time|estimateReadingTime|YourPageHere}} (change YourPageHere) local p = {} local mw = require("mw") function p.estimateReadingTime(frame) -- Get the page title from the frame parameter local pageTitle = frame.args[1] -- Ensure that pageTitle is a string if type(pageTitle) == "string" then --..."
  • 02:0902:09, 13 March 2025 diff hist 0 m Module:Random slideshow Protected "Module:Random slideshow" ([Edit=Allow only administrators] (indefinite) [Move=Allow only administrators] (indefinite)) current
  • 02:0502:05, 13 March 2025 diff hist +8,794 N Module:Random slideshow Created page with "-- Creates a slideshow gallery where the order is randomised. Intended for use on portal pages. local p = {} local excerptModule = require('Module:Excerpt/portals') local randomModule = require('Module:Random') function cleanupArgs(argsTable) local cleanArgs = {} for key, val in pairs(argsTable) do if type(val) == 'string' then val = val:match('^%s*(.-)%s*$') if val ~= '' then cleanArgs[key] = val end else cleanArgs[key] = val end end return c..."
  • 02:0502:05, 13 March 2025 diff hist 0 m Module:Random portal component Protected "Module:Random portal component" ([Edit=Allow only administrators] (indefinite) [Move=Allow only administrators] (indefinite)) current
  • 02:0402:04, 13 March 2025 diff hist +7,060 N Module:Random portal component Created page with "-- This module implements Template:Random portal component local p = {} local mRandom = require('Module:Random') local currentTitle = mw.title.getCurrentTitle() -- tracking function added by BHG 29/04/2019 -- called as subPageTrackingCategories(pages, args.max) local function subPageTrackingCategories(pages, max, header) local retval = ""; local thispagetitle = mw.title.getCurrentTitle().text -- don't track DYK etc, only selected/featured articles, biogs etc..."
  • 02:0402:04, 13 March 2025 diff hist 0 m Module:Random Protected "Module:Random" ([Edit=Allow only administrators] (indefinite) [Move=Allow only administrators] (indefinite)) current
  • 02:0302:03, 13 March 2025 diff hist +753 N Module:Random Created page with "local p = {} function p.random(frame) local parent = frame:getParent() local a = tonumber(parent.args[1]) or 1 local b = tonumber(parent.args[2]) or 100 local Date = os.date() local h = Date:match("(%d+):%d+:%d+") local m = Date:match("%d+:(%d+):%d+") local s = Date:match("%d+:%d+:(%d+)") local rnd = s * s * math.random(a,b) local loop = 0 while (rnd > b or rnd < a) do loop = loop +1 if (loop > 50) then rnd = a break end if (rnd > b)..."
  • 02:0302:03, 13 March 2025 diff hist 0 m Module:Purge Protected "Module:Purge" ([Edit=Allow only administrators] (indefinite) [Move=Allow only administrators] (indefinite)) current
  • 02:0302:03, 13 March 2025 diff hist +1,097 N Module:Purge Created page with "-- This module implements Template:Purge. local p = {} local function makeUrlLink(url, display) return string.format('[%s %s]', url, display) end function p._main(args) -- Make the URL local url do local title if args.page then title = mw.title.new(args.page) if not title then error(string.format( "'%s' is not a valid page name", args.page ), 2) end else title = mw.title.getCurrentTitle() end if args.anchor then title..."
  • 02:0202:02, 13 March 2025 diff hist 0 m Module:Pagetype/config Protected "Module:Pagetype/config" ([Edit=Allow only administrators] (indefinite) [Move=Allow only administrators] (indefinite)) current
  • 02:0202:02, 13 March 2025 diff hist +3,847 N Module:Pagetype/config Created page with "-------------------------------------------------------------------------------- -- Module:Pagetype configuration data -- -- This page holds localisation and configuration data for Module:Pagetype. -- -------------------------------------------------------------------------------- local cfg = {} -- Don't edit this line. -------------------------------------------------------------------------------- -- St..."
  • 02:0102:01, 13 March 2025 diff hist 0 m Module:Pagetype Protected "Module:Pagetype" ([Edit=Allow only administrators] (indefinite) [Move=Allow only administrators] (indefinite)) current
  • 02:0002:00, 13 March 2025 diff hist +6,765 N Module:Pagetype Created page with "-------------------------------------------------------------------------------- -- -- -- PAGETYPE -- -- -- -- This is a meta-module intended to replace {{pagetype}} and similar -- -- templates. It automatically detects namespaces, and allows for..."
  • 02:0002:00, 13 March 2025 diff hist 0 m Module:Number of works Protected "Module:Number of works" ([Edit=Allow only administrators] (indefinite) [Move=Allow only administrators] (indefinite)) current
  • 02:0002:00, 13 March 2025 diff hist +431 N Module:Number of works Created page with "-- This module is DEPRECATED. We turned to using DPL lists to count numbers of works in a library card. local p = {} function p.getWorkCount(frame) local category = frame.args.category or '' local pages = mw.site.stats.pagesInCategory(category) if tonumber(pages) == 1 then return "1 work" else return pages .. " works" end end function p.main(frame) return p.getWorkCount(frame) end"
  • 01:5801:58, 13 March 2025 diff hist 0 m Module:No globals Protected "Module:No globals" ([Edit=Allow only administrators] (indefinite) [Move=Allow only administrators] (indefinite)) current
  • 01:5801:58, 13 March 2025 diff hist +307 N Module:No globals Created page with "local mt = getmetatable(_G) or {} function mt.__index (t, k) if k ~= 'arg' then error('Tried to read nil global ' .. tostring(k), 2) end return nil end function mt.__newindex(t, k, v) if k ~= 'arg' then error('Tried to write global ' .. tostring(k), 2) end rawset(t, k, v) end setmetatable(_G, mt)"
  • 01:5801:58, 13 March 2025 diff hist 0 m Module:Navbox Protected "Module:Navbox" ([Edit=Allow only administrators] (indefinite) [Move=Allow only administrators] (indefinite)) current
  • 01:5701:57, 13 March 2025 diff hist +12,794 N Module:Navbox Created page with "-- -- This module implements {{Navbox}} -- local p = {} local navbar = require('Module:Navbar')._navbar local getArgs -- lazily initialized local args local border local listnums local ODD_EVEN_MARKER = '\127_ODDEVEN_\127' local RESTART_MARKER = '\127_ODDEVEN0_\127' local REGEX_MARKER = '\127_ODDEVEN(%d?)_\127' local function striped(wikitext) -- Return wikitext with markers replaced for odd/even striping. -- Child (subgroup) navboxes are flagged with a category th..."
  • 01:5601:56, 13 March 2025 diff hist 0 m Module:Navbar/styles.css Protected "Module:Navbar/styles.css" ([Edit=Allow only administrators] (indefinite) [Move=Allow only administrators] (indefinite)) current
  • 01:5601:56, 13 March 2025 diff hist +1,057 N Module:Navbar/styles.css Created page with ".navbar { display: inline; font-size: 88%; font-weight: normal; } .navbar-collapse { float: left; text-align: left; } .navbar-boxtext { word-spacing: 0; } .navbar ul { display: inline-block; white-space: nowrap; line-height: inherit; } .navbar-brackets::before { margin-right: -0.125em; content: '[ '; } .navbar-brackets::after { margin-left: -0.125em; content: ' ]'; } .navbar li { word-spacing: -0.125em; } .navbar-mini abbr { border-bottom: none; te..."
  • 01:5501:55, 13 March 2025 diff hist 0 m Module:Namespace detect/data Protected "Module:Namespace detect/data" ([Edit=Allow only administrators] (indefinite) [Move=Allow only administrators] (indefinite)) current
  • 01:5401:54, 13 March 2025 diff hist +2,569 N Module:Namespace detect/data Created page with "-------------------------------------------------------------------------------- -- Namespace detect data -- -- This module holds data for Module:Namespace detect to be loaded per -- -- page, rather than per #invoke, for performance reasons. -- -------------------------------------------------------------------------------- local cfg = require('Module:Namespace detect/config') local function..."
  • 01:5201:52, 13 March 2025 diff hist 0 m Module:Namespace detect/config Protected "Module:Namespace detect/config" ([Edit=Allow only administrators] (indefinite) [Move=Allow only administrators] (indefinite)) current
  • 01:5101:51, 13 March 2025 diff hist +3,545 N Module:Namespace detect/config Created page with "-------------------------------------------------------------------------------- -- Namespace detect configuration data -- -- -- -- This module stores configuration data for Module:Namespace detect. Here -- -- you can localise the module to your wiki's language. -- --..."
  • 01:5101:51, 13 March 2025 diff hist 0 m Module:Namespace detect Protected "Module:Namespace detect" ([Edit=Allow only administrators] (indefinite) [Move=Allow only administrators] (indefinite)) current
  • 01:5101:51, 13 March 2025 diff hist +5,992 N Module:Namespace detect Created page with "--[[ -------------------------------------------------------------------------------- -- -- -- NAMESPACE DETECT -- -- -- -- This module implements the {{namespace detect}} template in Lua, with a -- -- few improvements: all namespaces and all namespace aliases are..."
  • 01:5001:50, 13 March 2025 diff hist 0 m Module:Multiple image Protected "Module:Multiple image" ([Edit=Allow only administrators] (indefinite) [Move=Allow only administrators] (indefinite)) current
  • 01:5001:50, 13 March 2025 diff hist +9,354 N Module:Multiple image Created page with "-- implements template:multiple image local p = {} local autoscaledimages local nonautoscaledimages local function isnotempty(s) return s and s:match( '^%s*(.-)%s*$' ) ~= '' end local function removepx(s) return tostring(s or ''):match('^(.*)[Pp][Xx]%s*$') or s end local function getdimensions(s, w, h) if tonumber(w) and tonumber(h) then nonautoscaledimages = true return tonumber(w), tonumber(h) end local file = s and mw.title.new('File:' .. mw.uri.decod..."
  • 01:4801:48, 13 March 2025 diff hist 0 m Module:Message box/ombox.css Protected "Module:Message box/ombox.css" ([Edit=Allow only administrators] (indefinite) [Move=Allow only administrators] (indefinite)) current
  • 01:4801:48, 13 March 2025 diff hist +1,361 N Module:Message box/ombox.css Created page with "{{pp|small=y}}: .ombox { margin: 4px 0; border-collapse: collapse; border: 1px solid #a2a9b1; Default "notice" gray: background-color: #f8f9fa; box-sizing: border-box; } For the "small=yes" option.: .ombox.mbox-small { font-size: 88%; line-height: 1.25em; } .ombox-speedy { border: 2px solid #b32424; Red: background-color: #fee7e6; Pink: } .ombox-delete { border: 2px solid #b32424; Red: } .ombox-content { border: 1p..."
  • 01:4701:47, 13 March 2025 diff hist 0 m Module:Message box/configuration Protected "Module:Message box/configuration" ([Edit=Allow only administrators] (indefinite) [Move=Allow only administrators] (indefinite)) current
  • 01:4601:46, 13 March 2025 diff hist +6,474 N Module:Message box/configuration Created page with "-------------------------------------------------------------------------------- -- Message box configuration -- -- -- -- This module contains configuration data for Module:Message box. -- -------------------------------------------------------------------------------- return { ambox = { types = { speedy = { class = 'ambox-spee..."
  • 01:4601:46, 13 March 2025 diff hist 0 m Module:Message box/ambox.css Protected "Module:Message box/ambox.css" ([Edit=Allow only administrators] (indefinite) [Move=Allow only administrators] (indefinite)) current
(newest | oldest) View ( | ) (20 | 50 | 100 | 250 | 500)