User contributions for Couchor

Search for contributionsExpandCollapse
⧼contribs-top⧽
⧼contribs-date⧽
(newest | oldest) View ( | older 250) (20 | 50 | 100 | 250 | 500)

19 August 2022

  • 22:2722:27, 19 August 2022 diff hist +581 N Module:Category handler/blacklistCreated page with "return { '^Main Page$', -- don't categorise the main page. -- Don't categorise the following pages or their subpages. -- "%f[/\0]" matches if the next character is "/" or the end of the string. '^Liquipedia:Cascade%-protected items%f[/\0]', '^User:UBX%f[/\0]', -- The userbox "template" space. '^User talk:UBX%f[/\0]', -- Don't categorise subpages of these pages, but allow -- categorisation of the base page. '^Wikipedia:Template messages/.*$', -- Don't categor..." current
  • 22:2622:26, 19 August 2022 diff hist +6,736 N Module:Category handlerCreated page with "-- Load required modules local yesno = require('Module:Yesno') -- Lazily load things we don't always need local mShared, mappings local p = {} -------------------------------------------------------------------------------- -- Helper functions -------------------------------------------------------------------------------- local function trimWhitespace(s, removeBlanks) if type(s) ~= 'string' then return s end s = s:match('^%s*(.-)%s*$') if removeBlanks then i..." current
  • 22:0722:07, 19 August 2022 diff hist −27 Module:Squad/RowNo edit summary Tag: Manual revert
  • 22:0322:03, 19 August 2022 diff hist +12 Module:Squad/RowNo edit summary Tag: Reverted
  • 21:4821:48, 19 August 2022 diff hist +15 Module:Squad/RowNo edit summary Tag: Reverted
  • 21:4821:48, 19 August 2022 diff hist −14 Module:Squad/CustomNo edit summary current Tag: Manual revert
  • 21:4621:46, 19 August 2022 diff hist +14 Module:Squad/CustomNo edit summary Tag: Reverted
  • 21:4121:41, 19 August 2022 diff hist −18 Module:Squad/RowNo edit summary
  • 21:3121:31, 19 August 2022 diff hist +6 Module:Squad/RowNo edit summary
  • 21:2921:29, 19 August 2022 diff hist +13 Module:Squad/RowNo edit summary
  • 21:2721:27, 19 August 2022 diff hist +1,444 N Module:VariablesCreated page with "local Class = require('Module:Class') local Variables = {} ---Stores a wiki-variable and returns the empty string ---@param name string Key of the wiki-variable ---@param value string Value of the wiki-variable ---@return string #always the empty string function Variables.varDefine(name, value) return mw.ext.VariablesLua.vardefine(name, value) end ---Stores a wiki-variable and returns the stored value ---@param name string Key of the wiki-variable ---@param value str..." current
  • 21:2721:27, 19 August 2022 diff hist +2,409 N Module:LocalisationCreated page with "local Class = require('Module:Class') local Localisation = {} local String = require('Module:StringUtils') local Logic = require('Module:Logic') function Localisation.getCountryName(country, noentry) local data = mw.loadData('Module:Localisation/data/country') -- clean the entered country value country = Localisation._cleanCountry(country) -- First try to look it up local countryname = data[country] -- Return message if none is found if countryname == nil then..." current
  • 21:2621:26, 19 August 2022 diff hist +4,603 N Module:PlayerCreated page with "local getFlag = require('Module:Localisation').getCountryName local p = {} function p._cleanInput(name) local arrayLink local arrayName if (name or '') ~= '' then name = name:gsub("%b{}", "") name = name:gsub("%b<>", "") name = name:gsub("%b[]", "") name = mw.text.trim(name) arrayLink, arrayName = p._split(name) end return arrayLink, arrayName end function p._split(name) local link = '' if (name or '') ~= '' then local nameArray =..." current
  • 21:2621:26, 19 August 2022 diff hist +1,355 N Module:FnUtilCreated page with "local FnUtil = {} -- Creates a memoized copy of a 0 or 1 param function. function FnUtil.memoize(f) local called = {} local results = {} local nilCalled = false local nilResult return function(x) if x == nil then if not nilCalled then nilCalled = true nilResult = f(x) end return nilResult else if not called[x] then called[x] = true results[x] = f(x) end return results[x] end end end --[[ Memoized variant of the Y combinator..." current
  • 21:2521:25, 19 August 2022 diff hist +10,367 N Module:TableCreated page with "local Table = {} function Table.randomize(tbl) math.randomseed(os.time()) for i = #tbl, 2, -1 do local j = math.random(i) tbl[i], tbl[j] = tbl[j], tbl[i] end return tbl end function Table.size(tbl) local i = 0 for _ in pairs(tbl) do i = i + 1 end return i end function Table.includes(tbl, value) for _, entry in ipairs(tbl) do if entry == value then return true end end return false end function Table.filter(tbl, predicate, argument) local filt..." current
  • 21:2521:25, 19 August 2022 diff hist +1,763 N Module:LogicCreated page with "local Logic = {} function Logic.emptyOr(val1, val2, default) if not Logic.isEmpty(val1) then return val1 elseif not Logic.isEmpty(val2) then return val2 else return default end end function Logic.nilOr(...) local args = require('Module:Table').pack(...) for i = 1, args.n do local arg = args[i] local val if type(arg) == 'function' then val = arg() else val = arg end if val ~= nil then return val end end return nil end function Logic..." current
  • 21:2421:24, 19 August 2022 diff hist +2,078 N Module:TemplateCreated page with "local Arguments = require('Module:Arguments') local Json = require('Module:Json') local PageVariableNamespace = require('Module:PageVariableNamespace') local Template = {} function Template.safeExpand(frame, title, args, defaultTemplate) local result, value = pcall(frame.expandTemplate, frame, {title = title, args = args}) if result then return value else local templateName = 'Template:' .. (title or '') .. '' return defaultTemplate or templateName end en..." current
  • 21:2321:23, 19 August 2022 diff hist +38,247 N Module:Flags/MasterDataCreated page with "-- There are four tables: -- data (contains flag images. Should have one entry per image) -- twoLetter (two-letter country codes as per ISO 3166-1 alpha-2) -- threeLetter (three-letter country codes) -- aliases (redirects to the appropriate index in the data table) -- This table includes: -- ISO 3166-1 alpha-2 -- ISO 3166-1 alpha-2 User-assigned Code Elements -- ISO 3166-1 alpha-2 Exceptional Reservations -- ISO 3166-1 alpha-2 Traditional Reservations --..."
  • 21:2221:22, 19 August 2022 diff hist +778 N Module:ReferenceCleanerCreated page with "local Class = require('Module:Class') local ReferenceCleaner = {} function ReferenceCleaner.clean(dateWithRef) if dateWithRef == nil then return '' end -- due to '-' and '?' being part of the 'magic' characters for patterns -- we have to escape them with '%' dateWithRef = dateWithRef:gsub('%-%?%?', '-01') dateWithRef = dateWithRef:gsub('%-XX', '-01') local correctDate = string.match(dateWithRef, '(%d+-%d+-%d+)') if correctDate then return correctDate end..." current
  • 21:2021:20, 19 August 2022 diff hist +4 Template:SquadNo edit summary Tags: Manual revert Reverted
  • 21:2021:20, 19 August 2022 diff hist +3,879 N Module:Squad/CustomCreated page with "local Class = require('Module:Class') local Json = require('Module:Json') local ReferenceCleaner = require('Module:ReferenceCleaner') local Squad = require('Module:Squad') local SquadRow = require('Module:Squad/Row') local String = require('Module:StringUtils') local Variables = require('Module:Variables') local CustomSquad = {} function CustomSquad.header(self) local makeHeader = function(wikiText) local headerCell = mw.html.create('th') if wikiText == nil then..."
  • 21:1821:18, 19 August 2022 diff hist +2 Template:SquadNo edit summary Tag: Reverted
  • 21:1021:10, 19 August 2022 diff hist +1,143 N Module:JsonCreated page with "local Json = {} local Arguments = require('Module:Arguments') function Json.fromArgs(frame) local args = Arguments.getArgs(frame) return Json.stringify(args) end function Json.stringify(obj, pretty) return mw.text.jsonEncode(obj, pretty == true and mw.text.JSON_PRETTY or nil) end function Json.parse(obj) local parse = function(object) return mw.text.jsonDecode(object, mw.text.JSON_TRY_FIXING) end local status, res = pcall(parse, obj); if status then return re..."
  • 21:0321:03, 19 August 2022 diff hist −1 Template:SquadNo edit summary Tag: Reverted
  • 21:0321:03, 19 August 2022 diff hist 0 Template:SquadNo edit summary Tag: Reverted
  • 21:0221:02, 19 August 2022 diff hist +6 Template:SquadNo edit summary Tag: Reverted
  • 21:0121:01, 19 August 2022 diff hist −1 Template:SquadNo edit summary Tag: Reverted
  • 21:0121:01, 19 August 2022 diff hist −3 Template:SquadNo edit summary Tag: Reverted
  • 20:5820:58, 19 August 2022 diff hist +9,867 N Module:ArgumentsCreated page with "local libraryUtil = require('libraryUtil') local checkType = libraryUtil.checkType local arguments = {} -- Generate four different tidyVal functions, so that we don't have to check the -- options every time we call it. local function tidyValDefault(key, val) if type(val) == 'string' then val = val:match('^%s*(.-)%s*$') if val == '' then return nil else return val end else return val end end local function tidyValTrimOnly(key, val) if type(val) ==..."
  • 20:5720:57, 19 August 2022 diff hist +3,450 N Module:ClassCreated page with "local Arguments = require('Module:Arguments') local Class = {} Class.PRIVATE_FUNCTION_SPECIFIER = '_' function Class.new(base, init) local instance = {} if not init and type(base) == 'function' then init = base base = nil elseif type(base) == 'table' then for index, value in pairs(base) do instance[index] = value end instance._base = base end instance.__index = instance local metatable = {} metatable.__call = function(class_tbl, ...) local o..." current
  • 20:5720:57, 19 August 2022 diff hist −7 Template:SquadNo edit summary Tag: Reverted
  • 20:5320:53, 19 August 2022 diff hist +1,891 N Module:StringUtilsCreated page with "local String = {} function String.startsWith(str, start) return str:sub(1, #start) == start --str:find('^' .. start) ~= nil end function String.endsWith(str, ending) return ending == '' or str:sub(-#ending) == ending end function String.split(inputstr, sep) if inputstr ~= nil then if sep == nil then sep = '%s' end inputstr = inputstr:gsub(sep, '&') local t = {} local i = 1 for str in string.gmatch(inputstr, '([^&]+)') do t[i] = str i = i + 1..." current
  • 20:5320:53, 19 August 2022 diff hist +2,656 N Module:SquadCreated page with "local Class = require('Module:Class') local Arguments = require('Module:Arguments') local String = require('Module:StringUtils') local Squad = Class.new() Squad.TYPE_ACTIVE = 0 Squad.TYPE_INACTIVE = 1 Squad.TYPE_FORMER = 2 Squad.TYPE_FORMER_INACTIVE = 3 function Squad:init(frame) self.frame = frame self.args = Arguments.getArgs(frame) self.root = mw.html.create('div') self.root :addClass('table-responsive') -- TODO: is this needed? :css('margin-bottom', '1..."
  • 20:5020:50, 19 August 2022 diff hist +4,797 N Module:FlagsCreated page with "local MasterData = mw.loadData('Module:Flags/MasterData') local Template = require('Module:Template') local Logic = require('Module:Logic') local Table = require('Module:Table') local String = require('Module:StringUtils') local FnUtil = require('Module:FnUtil') local Class = require('Module:Class') local Flags = {} -- Returns a flag --[[ supported args are: flag - country name, flag code, or alias of the Flag shouldLink - boolean that decides if the flag should link..."
  • 20:5020:50, 19 August 2022 diff hist −137 Module:Squad/RowNo edit summary
  • 20:5020:50, 19 August 2022 diff hist +5,643 N Module:Squad/RowCreated page with "--- -- @Liquipedia -- wiki=commons -- page=Module:Squad/Row -- -- Please see https://github.com/Liquipedia/Lua-Modules to contribute -- local Class = require('Module:Class') local Flags = require('Module:Flags') local Player = require('Module:Player') local ReferenceCleaner = require('Module:ReferenceCleaner') local String = require('Module:StringUtils') local Template = require('Module:Template') local Table = require('Module:Table') -- TODO: Decided on all valid type..."

18 August 2022

17 August 2022

16 August 2022

12 August 2022

  • 10:3810:38, 12 August 2022 diff hist +125 Template:Infobox companyNo edit summary
  • 08:4308:43, 12 August 2022 diff hist +808 N Template:ReflistCreated page with "<div class="reflist <!-- -->{{#if: {{{1|}}} | {{#iferror: {{#ifexpr: {{{1|1}}} > 1 }} | references-column-width | references-column-count references-column-count-{{#if:1|{{{1}}}}} }} | {{#if: {{{colwidth|}}} | references-column-width }} }}" style="<!-- -->{{#if: {{{1|}}} | {{#iferror: {{#ifexpr: {{{1|1}}} > 1 }} | {{column-width|{{#if:1|{{{1}}}}}}} | {{column-count|{{#if:1|{{{1}}}}}}} }} | {{#if: {{{colwidth|}}} | {{..." current
  • 08:4108:41, 12 August 2022 diff hist +579 N Template:Citation/make linkCreated page with "{{#if:{{{1|}}} |[{{{1}}} {{{2}}}] |{{{2}}} }}<noinclude><!-- Code notes (here so that people /read/ it) 1. Parameter #2 is always nonempty when called from {{Citation/core}}. 2. It's up to {{Citation/core}} to stop italicized "'foo' & 'bar'" from becoming "'''foo' & 'bar'''". Citation/core does this by having a <nowiki></nowiki> at both beginning and end of the call to this template. Since this is only needed once, it's more efficient to do it in {..." current
  • 08:4008:40, 12 August 2022 diff hist +5,402 N Template:Cite webCreated page with "<includeonly>{{Citation/core |Citation class=web |Surname1 = {{{last|{{{surname|{{{last1|{{{surname1|{{{author1|{{{author|{{{authors|}}}}}}}}}}}}}}}}}}}}} |Surname2 = {{{last2|{{{surname2|{{{author2|}}}}}}}}} |Surname3 = {{{last3|{{{surname3|{{{author3|}}}}}}}}} |Surname4 = {{{last4|{{{surname4|{{{author4|}}}}}}}}} |Surname5 = {{{last5|{{{surname5|{{{author5|}}}}}}}}} |Surname6 = {{{last6|{{{surname6|{{{author6|}}}}}}}}} |Surname7 = {{{last7|{{{surname7|{..." current
  • 08:4008:40, 12 August 2022 diff hist +22,125 N Template:Citation/coreCreated page with "<span class="citation {{{Citation class|{{{Citation type|}}}}}}" {{ #switch:{{{Ref|}}} ||none = |#default = id="{{anchorencode:{{{Ref}}}}}" |harv = {{#if:{{{Surname1|}}}{{{EditorSurname1|}}} |id="CITEREF{{anchorencode:{{#if:{{{Surname1|}}} |{{{Surname1}}}{{{Surname2|}}}{{{Surname3|}}}{{{Surname4|}}} |{{{EditorSurname1|}}}{{{EditorSurname2|}}}{{{EditorSurname3|}}}{{{EditorSurname4|}}} }}{{{Year|{{{Date|}}}}}}}}" }} }}>{{ <!--============ Aut..." current

8 August 2022

6 August 2022

5 August 2022

4 August 2022

4 July 2022

(newest | oldest) View ( | older 250) (20 | 50 | 100 | 250 | 500)