Anonymous

Module:Color: Difference between revisions

From Zelda Wiki, the Zelda encyclopedia
m
no edit summary
m (support any valid HTML color on talk pages and such)
mNo edit summary
Line 23: Line 23:
-- Backwards compatibility for inputting any valid HTML color
-- Backwards compatibility for inputting any valid HTML color
-- In articles we should only allow defined game colors, but we can keep support for any HTML color on user and talk pages to avoid breaking user signatures that use the template this way
-- In articles we should only allow defined game colors, but we can keep support for any HTML color on user and talk pages to avoid breaking user signatures that use the template this way
if colorData == nil and (mw.title.getCurrentTitle().isTalkPage or mw.title.getCurrentTitle().nsText == "User") then
if colorData == nil and (mw.title.getCurrentTitle().isTalkPage or mw.title.getCurrentTitle().nsText == "User" or mw.title.getCurrentTitle().nsText == "Zelda Wiki") then
html = mw.html.create("span")
html = mw.html.create("span")
:css("color", colorId)
:css("color", colorId)