79 548
contributi
(Moving Gigamax to AltForms, adding Alcremie forms *** sovrascritto il testo esistente ***) |
(Updating alt forms links to point to specific subpages *** sovrascritto il testo esistente ***) |
||
local txt = require('Modulo:Wikilib/strings') -- luacheck: no unused
local tab = require('Modulo:Wikilib/tables') -- luacheck: no unused
--[[
Creates the link for an alternative form. There are two general
kinds of link: those pointing to the specific subpage of the Pokémon,
and those pointing to general pages (eg: "Forma di Alola").
This function handles boths, depending on the arguments.
This function also handles empty form name, yielding no link at all
(an empty string).
Arguments:
- black: a boolean value. If true returns black links, otherwise normal
- formName: name of the specific form
- poke: base name of the Pokémon
- general: an optional string argument. If given, the function assumes
the link target should be the general page whose title is given by
the value of this parameter (eg: for a Megaevoluzione, this
parameter should be "Megaevoluzione")
--]]
local function makeSingleLink(black, formName, poke, general)
return ""
end
local target
if general then
else
target = table.concat{string.fu(poke), "/Forme"}
end
black = black and " black-text" or "",
formName = formName,
target = target
})
end
-- Creates links to alternative forms
local function makeLinks
▲ and '<div class="small-text black-text">[[Differenze di forma#${anchor}|${formName}]]</div>'
local index = black and 'blacklinks' or 'links'
-- Adds standard links
for name, poke in pairs(t) do
poke[index] = table.map(poke.names, function(formName)
return
▲ anchor = poke.anchor or string.fu(name),
▲ formName = formName
end)
end
|