Jump to content

Module:RfD and Module:RfD/sandbox: Difference between pages

(Difference between pages)
Page 1
Page 2
Content deleted Content added
NOINDEX only if actually displaying the RfD notice
 
test
 
Line 10: Line 10:
.. " Please share your thoughts on the matter at '''[[Wikipedia:Redirects for discussion/Log/%s %s %s#%s|this redirect's entry]]''' on the [[Wikipedia:Redirects for discussion|redirects for discussion]] page.<br />"
.. " Please share your thoughts on the matter at '''[[Wikipedia:Redirects for discussion/Log/%s %s %s#%s|this redirect's entry]]''' on the [[Wikipedia:Redirects for discussion|redirects for discussion]] page.<br />"
.. " '''Click on the link below''' to go to the current destination page.<br />"
.. " '''Click on the link below''' to go to the current destination page.<br />"
.. "''Please do not remove this notice before the discussion is closed''. <br />"
.. "<small>Please notify the good-faith creator and any main contributors of the redirect by placing <code>&#123;&#123;[[Wikipedia:Substitution|subst]]:[[Template:Rfd notice|Rfd notice]]&#124;%s&#125;&#125; &#126;&#126;&#126;&#126;</code> on their talk page.</small>__EXPECTUNUSEDTEMPLATE__"
.. "<small>Please notify the good-faith creator and any main contributors of the redirect by placing <code>&#123;&#123;[[Wikipedia:Substitution|subst]]:[[Template:Rfd notice|Rfd notice]]&#124;%s&#125;&#125; &#126;&#126;&#126;&#126;</code> on their talk page.</small>__EXPECTUNUSEDTEMPLATE__"
local deleteReason = '[[Wikipedia:Redirects for discussion]] debate closed as delete'
local deleteReason = '[[Wikipedia:Redirects for discussion]] debate closed as delete'
Line 33: Line 34:
},
},
['tiny'] = {
['tiny'] = {
['tags'] = {'<span ', '</span> '},
['tags'] = {' <span ', '</span> '},
['style'] = '',
['style'] = '',
['message'] = messageOnTransclusionsTiny:format(args.year, args.month, args.day, discussionPage)
['message'] = messageOnTransclusionsTiny:format(args.year, args.month, args.day, discussionPage)
},
}
}
}
local size = sizeAttrs[args.showontransclusion] and args.showontransclusion or 'standard'
local size = sizeAttrs[args.showontransclusion] and args.showontransclusion or 'standard'
Line 43: Line 44:
local classes = 'class="boilerplate metadata plainlinks ' .. visibility .. '" '
local classes = 'class="boilerplate metadata plainlinks ' .. visibility .. '" '
local id = 'id="rfd-t" '
local id = 'id="rfd-t" '
local style = 'style="font-size: 85%; text-align: left;' .. sizeAttrs[size]['style'] .. '" '
local style = 'style="background-color: transparent; padding: 0; font-size: xx-small; color: #000000;'
.. 'text-align: left;' .. sizeAttrs[size]['style'] .. '" '
return tags[1] .. classes .. id .. style .. '>' .. sizeAttrs[size]['message'] .. tags[2]
return tags[1] .. classes .. id .. style .. '>' .. sizeAttrs[size]['message'] .. tags[2]
end
end
Line 71: Line 73:
end
end
if category then category = category..'[[Category:Temporary maintenance holdings/RFD]]' end
if category then category = category..'[[Category:Temporary maintenance holdings/RFD]]' end
return string.format('%s<span id="delete-reason" style="display: none;">%s</span>%s%s',
local noindex = mw.getCurrentFrame():expandTemplate{title="NOINDEX"}
return string.format('%s%s<span id="delete-reason" style="display: none;">%s</span>%s%s',
noindex,
messageBox.main('mbox', {
messageBox.main('mbox', {
type = 'delete',
type = 'delete',
Line 103: Line 103:
-- Since we don't have grandparent access, though, it means the thing we're calling doesn't either, so it doesn't really matter yet
-- Since we don't have grandparent access, though, it means the thing we're calling doesn't either, so it doesn't really matter yet
local parsedTarget = pframe:expandTemplate{title = ':' .. target.prefixedText, args = pframe.args}
local parsedTarget = pframe:expandTemplate{title = ':' .. target.prefixedText, args = pframe.args}
local showontransclusion = frame.args.showontransclusion
if frame.args.showontransclusion and not mw.isSubsting() then
showontransclusion = require('Module:Yesno')(showontransclusion, showontransclusion)
if showontransclusion and not (showontransclusion == '' or mw.isSubsting()) then
return makeTransclusionTag(args, redirect) .. parsedTarget
return makeTransclusionTag(args, redirect) .. parsedTarget
else
return parsedTarget
end
end
return parsedTarget
end
end
end
end
Line 146: Line 145:
-- called during subst when the template is initially placed on the page
-- called during subst when the template is initially placed on the page
function p.main(frame)
function p.main(frame)
local titleText
local pframe = frame:getParent()
local pframe = frame:getParent()
local pargs = pframe.args
local pargs = pframe.args