https://en.wikipedia.org/w/index.php?action=history&feed=atom&title=Module%3ALoad_WikiProject_Modules%2Fsandbox Module:Load WikiProject Modules/sandbox - Revision history 2025-06-01T23:31:00Z Revision history for this page on the wiki MediaWiki 1.45.0-wmf.3 https://en.wikipedia.org/w/index.php?title=Module:Load_WikiProject_Modules/sandbox&diff=1277328761&oldid=prev Myotus at 00:49, 24 February 2025 2025-02-24T00:49:58Z <p></p> <table style="background-color: #fff; color: #202122;" data-mw="interface"> <col class="diff-marker" /> <col class="diff-content" /> <col class="diff-marker" /> <col class="diff-content" /> <tr class="diff-title" lang="en"> <td colspan="2" style="background-color: #fff; color: #202122; text-align: center;">← Previous revision</td> <td colspan="2" style="background-color: #fff; color: #202122; text-align: center;">Revision as of 00:49, 24 February 2025</td> </tr><tr> <td colspan="2" class="diff-lineno">Line 21:</td> <td colspan="2" class="diff-lineno">Line 21:</td> </tr> <tr> <td class="diff-marker"></td> <td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div> index['Maps'] = 'MapPin.svg'</div></td> <td class="diff-marker"></td> <td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div> index['Maps'] = 'MapPin.svg'</div></td> </tr> <tr> <td class="diff-marker"></td> <td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div> index['Metrics'] = 'ArticleCheck.svg'</div></td> <td class="diff-marker"></td> <td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div> index['Metrics'] = 'ArticleCheck.svg'</div></td> </tr> <tr> <td class="diff-marker" data-marker="−"></td> <td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;"><div> index['<del style="font-weight: bold; text-decoration: none;">Assessment</del>'] = 'ArticleCheck.svg'</div></td> <td class="diff-marker" data-marker="+"></td> <td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;"><div> index['<ins style="font-weight: bold; text-decoration: none;">Assessments</ins>'] = 'ArticleCheck.svg'</div></td> </tr> <tr> <td class="diff-marker"></td> <td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div> index['News'] = 'Calendar icon 2.svg'</div></td> <td class="diff-marker"></td> <td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div> index['News'] = 'Calendar icon 2.svg'</div></td> </tr> <tr> <td class="diff-marker"></td> <td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div> index['Offline App'] = 'Offline logo.svg'</div></td> <td class="diff-marker"></td> <td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div> index['Offline App'] = 'Offline logo.svg'</div></td> </tr> </table> Myotus https://en.wikipedia.org/w/index.php?title=Module:Load_WikiProject_Modules/sandbox&diff=1277327705&oldid=prev Myotus: adding Assessment 2025-02-24T00:43:13Z <p>adding Assessment</p> <table style="background-color: #fff; color: #202122;" data-mw="interface"> <col class="diff-marker" /> <col class="diff-content" /> <col class="diff-marker" /> <col class="diff-content" /> <tr class="diff-title" lang="en"> <td colspan="2" style="background-color: #fff; color: #202122; text-align: center;">← Previous revision</td> <td colspan="2" style="background-color: #fff; color: #202122; text-align: center;">Revision as of 00:43, 24 February 2025</td> </tr><tr> <td colspan="2" class="diff-lineno">Line 21:</td> <td colspan="2" class="diff-lineno">Line 21:</td> </tr> <tr> <td class="diff-marker"></td> <td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div> index['Maps'] = 'MapPin.svg'</div></td> <td class="diff-marker"></td> <td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div> index['Maps'] = 'MapPin.svg'</div></td> </tr> <tr> <td class="diff-marker"></td> <td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div> index['Metrics'] = 'ArticleCheck.svg'</div></td> <td class="diff-marker"></td> <td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div> index['Metrics'] = 'ArticleCheck.svg'</div></td> </tr> <tr> <td colspan="2" class="diff-empty diff-side-deleted"></td> <td class="diff-marker" data-marker="+"></td> <td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;"><div> index['Assessment'] = 'ArticleCheck.svg'</div></td> </tr> <tr> <td class="diff-marker"></td> <td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div> index['News'] = 'Calendar icon 2.svg'</div></td> <td class="diff-marker"></td> <td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div> index['News'] = 'Calendar icon 2.svg'</div></td> </tr> <tr> <td class="diff-marker"></td> <td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div> index['Offline App'] = 'Offline logo.svg'</div></td> <td class="diff-marker"></td> <td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div> index['Offline App'] = 'Offline logo.svg'</div></td> </tr> </table> Myotus https://en.wikipedia.org/w/index.php?title=Module:Load_WikiProject_Modules/sandbox&diff=1001307838&oldid=prev Pppery: Pppery moved page Module:Load WikiProject Modules/testcases to Module:Load WikiProject Modules/sandbox without leaving a redirect: Seems to be a sandbox, not testcases 2021-01-19T03:31:02Z <p>Pppery moved page <a href="/w/index.php?title=Module:Load_WikiProject_Modules/testcases&amp;action=edit&amp;redlink=1" class="new" title="Module:Load WikiProject Modules/testcases (page does not exist)">Module:Load WikiProject Modules/testcases</a> to <a href="/wiki/Module:Load_WikiProject_Modules/sandbox" title="Module:Load WikiProject Modules/sandbox">Module:Load WikiProject Modules/sandbox</a> without leaving a redirect: Seems to be a sandbox, not testcases</p> <table style="background-color: #fff; color: #202122;" data-mw="interface"> <tr class="diff-title" lang="en"> <td colspan="1" style="background-color: #fff; color: #202122; text-align: center;">← Previous revision</td> <td colspan="1" style="background-color: #fff; color: #202122; text-align: center;">Revision as of 03:31, 19 January 2021</td> </tr><tr><td colspan="2" class="diff-notice" lang="en"><div class="mw-diff-empty">(No difference)</div> </td></tr></table> Pppery https://en.wikipedia.org/w/index.php?title=Module:Load_WikiProject_Modules/sandbox&diff=994131658&oldid=prev Breadyornot: ←Created page with 'local p = {} function standardicon(modulename) index = {} -- Take modulename as input, returns corresponding icon filename -- Returns default icon if no icon...' 2020-12-14T06:16:15Z <p><a href="/wiki/Wikipedia:AES" class="mw-redirect" title="Wikipedia:AES">←</a>Created page with &#039;local p = {} function standardicon(modulename) index = {} -- Take modulename as input, returns corresponding icon filename -- Returns default icon if no icon...&#039;</p> <p><b>New page</b></p><div>local p = {}<br /> <br /> function standardicon(modulename)<br /> index = {}<br /> -- Take modulename as input, returns corresponding icon filename<br /> -- Returns default icon if no icon is defined<br /> -- Grow the library! Add default icons as needed by adding this line below:<br /> -- index[&#039;MODULENAME&#039;] = &#039;FILE NAME.ext&#039;<br /> index[&#039;About&#039;] = &#039;Information Noun 176431.svg&#039;<br /> index[&#039;About us&#039;] = &#039;Information Noun 176431.svg&#039;<br /> index[&#039;Alerts&#039;] = &#039;Bell icon.svg&#039;<br /> index[&#039;Article alerts&#039;] = &#039;Bell icon.svg&#039;<br /> index[&#039;Article Alerts&#039;] = &#039;Bell icon.svg&#039;<br /> index[&#039;Partners&#039;] = &#039;Handshake noun.svg&#039;<br /> index[&#039;Partnerships&#039;] = &#039;Handshake noun.svg&#039;<br /> index[&#039;Discussions&#039;] = &#039;Speechbubbles icon.svg&#039;<br /> index[&#039;Events&#039;] = &#039;Simpleicons Business calendar-with-a-clock-time-tools.svg&#039; -- Is this PD-shapes?<br /> index[&#039;External Links&#039;] = &#039;Link icon.svg&#039;<br /> index[&#039;External links&#039;] = &#039;Link icon.svg&#039;<br /> index[&#039;Links&#039;] = &#039;Link icon.svg&#039;<br /> index[&#039;Maps&#039;] = &#039;MapPin.svg&#039;<br /> index[&#039;Metrics&#039;] = &#039;ArticleCheck.svg&#039;<br /> index[&#039;News&#039;] = &#039;Calendar icon 2.svg&#039;<br /> index[&#039;Offline App&#039;] = &#039;Offline logo.svg&#039;<br /> index[&#039;Press&#039;] = &#039;Cite newspaper.svg&#039;<br /> index[&#039;Recent changes&#039;] = &#039;Clock icon.svg&#039;<br /> index[&#039;Recent Changes&#039;] = &#039;Clock icon.svg&#039;<br /> index[&#039;Recognized content&#039;] = &#039;RibbonPrize.svg&#039;<br /> index[&#039;Recognized Content&#039;] = &#039;RibbonPrize.svg&#039;<br /> index[&#039;Related Projects&#039;] = &#039;Contributions icon.svg&#039; -- Not for use for the update bot, special use case, that expands the page <br /> index[&#039;Related WikiProjects&#039;] = &#039;Contributions icon.svg&#039;<br /> index[&#039;Requests&#039;] = &#039;Quotes icon.svg&#039;<br /> index[&#039;Research&#039;] = &#039;Microscope icon (black OCL).svg&#039;<br /> index[&#039;Resources&#039;] = &#039;Cite book.svg&#039;<br /> index[&#039;Showcase&#039;] = &#039;RibbonPrize.svg&#039;<br /> index[&#039;Tasks&#039;] = &#039;ListBullet.svg&#039;<br /> index[&#039;Tools&#039;] = &#039;Octicons-tools-minor.svg&#039;<br /> index[&#039;Translations&#039;] = &#039;Translation icon.svg&#039;<br /> index[&#039;Watchlist&#039;] = &#039;OpenEye icon.svg&#039;<br /> index[&#039;Worklists&#039;] = &#039;ListBullet.svg&#039;<br /> for t, fn in pairs(index) do<br /> if t == modulename then<br /> return fn<br /> end<br /> end<br /> return &#039;Beta icon.svg&#039; -- default if nothing matches<br /> end<br /> <br /> function editlinktest(modulename)<br /> no_edit_links = {&#039;Discussions&#039;, &#039;Alerts&#039;, &#039;Showcase&#039;, &#039;Related WikiProjects&#039;} -- no edit link for these standard modules<br /> <br /> for _, l in pairs(no_edit_links) do<br /> if l == modulename then<br /> return &#039;no&#039;<br /> end<br /> end<br /> return &#039;yes&#039;<br /> end<br /> <br /> function p.build(frame)<br /> title = &#039;&#039;<br /> intro = &#039;&#039;<br /> image = &#039;&#039;<br /> color = &#039;#6af&#039; -- default value<br /> displaymode = &#039;normal&#039; -- default value<br /> modules = {}<br /> for key, value in pairs(frame:getParent().args) do -- iterate through arguments, pick out values<br /> if key == &#039;title&#039; then<br /> title = value<br /> elseif key == &#039;intro&#039; then<br /> intro = value<br /> elseif key == &#039;image&#039; then<br /> image = value<br /> elseif key == &#039;color&#039; then<br /> color = value<br /> elseif key == &#039;displaymode&#039; then<br /> displaymode = value<br /> elseif string.find(key, &#039;module&#039;) ~= nil then -- matches module1, module2, etc.<br /> id = string.gsub(key, &#039;module&#039;, &#039;&#039;)<br /> id = tonumber(id)<br /> modules[id] = value<br /> end<br /> end<br /> <br /> -- Rendering table of contents and body<br /> toc_args = {width = 80, height = 55} -- passed into Image Array module<br /> toc_args[&#039;font-size&#039;] = &#039;100%&#039;<br /> toc_args[&#039;margin&#039;] = 0<br /> body = &quot;&quot;<br /> <br /> -- Load a Table of Contents entry, transclude module, for each named module<br /> counter = 0<br /> for _, module in pairs(modules) do<br /> counter = counter + 1<br /> toc_args[&#039;image&#039; .. counter] = standardicon(module)<br /> toc_args[&#039;alt&#039; .. counter] = module<br /> if displaymode == &quot;writing&quot; then<br /> if module == &quot;Metrics&quot; or module == &quot;Showcase&quot; or module == &quot;About us&quot; or module == &quot;Press&quot; or module == &quot;Research&quot; or module == &quot;External links&quot; then<br /> toc_args[&#039;link&#039; .. counter] = &quot;Wikipedia:WikiProject Writing/&quot; .. module<br /> else<br /> toc_args[&#039;link&#039; .. counter] = &quot;#&quot; .. module<br /> end<br /> else<br /> toc_args[&#039;link&#039; .. counter] = &quot;#&quot; .. module<br /> end<br /> toc_args[&#039;caption&#039; .. counter] = &quot;[[&quot; .. toc_args[&#039;link&#039; .. counter] .. &quot;|&quot; .. module .. &quot;]]&quot;<br /> if module == &quot;Related WikiProjects&quot; then<br /> -- Load the appropriate subpage of [[Wikipedia:Related WikiProjects]]<br /> moduletitle = &#039;Related WikiProjects&#039; .. &#039;/&#039; .. title<br /> moduletitle_encoded = string.gsub(&#039;Wikipedia:&#039; .. moduletitle, &#039; &#039;, &#039;_&#039;)<br /> body = body .. &quot;\n&quot; .. frame:expandTemplate{ title = &#039;WPX header&#039;, args = { module, color = color, modulename = moduletitle_encoded, editlink = editlinktest(module) } }<br /> body = body .. &quot;\n&quot; .. frame:expandTemplate{ title = &quot;Wikipedia:Related WikiProjects/&quot; .. title, args = {color} }<br /> else<br /> if displaymode == &quot;normal&quot; or ( displaymode == &quot;womeninred&quot; and module ~= &quot;Metrics&quot; and module ~= &quot;Showcase&quot; and module ~= &quot;About us&quot; and module ~= &quot;Press&quot; and module ~= &quot;Research&quot; and module ~= &quot;External links&quot; ) then<br /> moduletitle = title .. &#039;/&#039; .. module<br /> moduletitle_encoded = string.gsub(&#039;Wikipedia:&#039; .. moduletitle, &#039; &#039;, &#039;_&#039;)<br /> body = body .. &quot;\n&quot; .. frame:expandTemplate{ title = &#039;WPX header&#039;, args = { module, color = color, modulename = moduletitle_encoded, editlink = editlinktest(module) } }<br /> if mw.title.makeTitle(&#039;Wikipedia&#039;, moduletitle).exists == true then<br /> body = body .. &quot;\n&quot; .. frame:expandTemplate{ title = &#039;Wikipedia:&#039; .. moduletitle, args = {color} } .. &quot;\n&lt;div style=&#039;clear:both;&#039;&gt;&lt;/div&gt;&quot;<br /> else<br /> -- Is module in question a Standard Module? If so, load the template with corresponding editintro<br /> if mw.title.makeTitle(&#039;Template&#039;, &#039;WPX module/&#039; .. module).exists == true then<br /> preload = &#039;&amp;preload=Template:WPX_module/&#039; .. string.gsub(module, &#039; &#039;, &#039;_&#039;)<br /> editintro = &#039;&amp;editintro=Template:WPX_editintro/&#039; .. string.gsub(module, &#039; &#039;, &#039;_&#039;)<br /> else<br /> preload = &#039;&#039; -- no preload<br /> editintro = &#039;&amp;editintro=Template:WPX_editintro/Generic&#039; -- generic editintro<br /> end<br /> -- Create notice<br /> create_url = &#039;//en.wikipedia.org/wiki/Wikipedia:&#039; .. string.gsub(moduletitle, &#039; &#039;, &#039;_&#039;) .. &#039;?action=edit&#039; .. preload .. editintro<br /> create_button = frame:expandTemplate{ title = &#039;Template:Clickable button 2&#039;, args = {&#039;Create Module&#039;, url = create_url, class = &#039;mw-ui-progressive&#039; } }<br /> body = body .. &#039;[[Wikipedia:&#039; .. moduletitle .. &#039;]] does not exist. &#039; .. create_button<br /> end<br /> end<br /> end<br /> <br /> end<br /> <br /> toc_args[&#039;perrow&#039;] = counter -- sets length of image array to the number of icons<br /> toc = &quot;&lt;div style=&#039;margin-bottom:4em;&#039;&gt;&quot; .. frame:expandTemplate{ title=&#039;Image_array&#039;, args = toc_args } .. &quot;&lt;/div&gt;&lt;div style=&#039;clear:both;&#039;&gt;&lt;/div&gt;&quot;<br /> <br /> -- Adding header<br /> header = &quot;__NOTOC__\n&lt;div style=&#039;display: flex; display: -webkit-flex; flex-flow: row wrap; -webkit-flex-flow: row wrap;&#039;&gt;&quot; -- top container<br /> if displaymode == &quot;writing&quot; then<br /> header = header .. &quot;&lt;div style=&#039;flex: 1 0; -webkit-flex: 1 0; border-top: solid .7em &quot; .. color .. &quot;;&#039;&gt;&quot; -- intro<br /> else<br /> header = header .. &quot;&lt;div style=&#039;flex: 1 0; -webkit-flex: 1 0; padding-bottom: 3em; border-top: solid .7em &quot; .. color .. &quot;;&#039;&gt;&quot; -- intro<br /> end<br /> -- Adding project icon<br /> header = header .. &quot;&lt;div class=&#039;nomobile&#039; style=&#039;float:left; margin-top: 1em; margin-right: 2em; margin-bottom: 1em; text-align: center;&#039;&gt;&quot;<br /> header = header .. image .. &quot;&lt;/div&gt;&quot;<br /> -- Adding project title<br /> header = header .. &quot;&lt;div style=&#039;font-size: 120%; padding: 0;&#039;&gt;&quot; -- header<br /> header = header .. &quot;&lt;h1 style=&#039;font-weight: bold; border-bottom: none; margin:0; padding-top:0.5em;&#039;&gt;&quot; .. title .. &quot;&lt;/h1&gt;&lt;/div&gt;&quot;<br /> if displaymode == &quot;writing&quot; then<br /> header = header .. toc<br /> end<br /> -- Adding intro blurb<br /> header = header .. &quot;&lt;div style=&#039;margin-top: 1em; font-size: 110%;&#039;&gt;&quot;<br /> header = header .. intro .. &quot;&lt;/div&gt;&quot;<br /> -- Adding announcement section<br /> if mw.title.makeTitle(&#039;Wikipedia&#039;, title .. &quot;/&quot; .. &quot;Announcements&quot;).exists == true then<br /> header = header .. frame:expandTemplate{ title = &#039;Wikipedia:&#039; .. title .. &quot;/&quot; .. &quot;Announcements&quot;, args = { } }<br /> end<br /> header = header .. &quot;&lt;/div&gt;&quot;<br /> -- Adding member box<br /> header = header .. &quot;&lt;div style=&#039;flex: 0 1; -webkit-flex: 0 20em;&#039;&gt;&quot;<br /> header = header .. frame:expandTemplate{ title = &#039;WPX member box&#039;, args = { } }<br /> header = header .. &quot;&lt;/div&gt;&quot;<br /> -- Closing off header<br /> header = header .. &quot;&lt;/div&gt;&lt;/div&gt;&quot;<br /> <br /> -- Assembling parts<br /> if displaymode == &quot;womeninred&quot; then<br /> contents = header .. body<br /> else<br /> contents = header .. toc .. body<br /> end<br /> return contents<br /> end<br /> <br /> return p</div> Breadyornot