<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.pxls.space/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Vanilla</id>
	<title>Pxls Wiki - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.pxls.space/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Vanilla"/>
	<link rel="alternate" type="text/html" href="https://wiki.pxls.space/view/Special:Contributions/Vanilla"/>
	<updated>2026-06-23T22:04:53Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.43.0</generator>
	<entry>
		<id>https://wiki.pxls.space/index.php?title=User:Vanilla&amp;diff=20204</id>
		<title>User:Vanilla</title>
		<link rel="alternate" type="text/html" href="https://wiki.pxls.space/index.php?title=User:Vanilla&amp;diff=20204"/>
		<updated>2023-12-04T03:43:05Z</updated>

		<summary type="html">&lt;p&gt;Vanilla: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Hey there! I&#039;m the ex-owner of Pxls and managed development for the site. I can be reached on Discord at vanyilla.&lt;br /&gt;
Test&lt;/div&gt;</summary>
		<author><name>Vanilla</name></author>
	</entry>
	<entry>
		<id>https://wiki.pxls.space/index.php?title=User:Vanilla&amp;diff=16141</id>
		<title>User:Vanilla</title>
		<link rel="alternate" type="text/html" href="https://wiki.pxls.space/index.php?title=User:Vanilla&amp;diff=16141"/>
		<updated>2023-06-10T23:09:42Z</updated>

		<summary type="html">&lt;p&gt;Vanilla: Update position and Discord tag&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Hey there! I&#039;m the ex-owner of Pxls and managed development for the site. I can be reached on Discord at vanyilla.&lt;/div&gt;</summary>
		<author><name>Vanilla</name></author>
	</entry>
	<entry>
		<id>https://wiki.pxls.space/index.php?title=User:Vanilla&amp;diff=15493</id>
		<title>User:Vanilla</title>
		<link rel="alternate" type="text/html" href="https://wiki.pxls.space/index.php?title=User:Vanilla&amp;diff=15493"/>
		<updated>2023-04-23T18:37:13Z</updated>

		<summary type="html">&lt;p&gt;Vanilla: Reword and update Discord tag&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Hey there! I&#039;m the owner of Pxls and manage development for the site. I can be reached on Discord at Vanilla#2656.&lt;/div&gt;</summary>
		<author><name>Vanilla</name></author>
	</entry>
	<entry>
		<id>https://wiki.pxls.space/index.php?title=Temriel&amp;diff=15019</id>
		<title>Temriel</title>
		<link rel="alternate" type="text/html" href="https://wiki.pxls.space/index.php?title=Temriel&amp;diff=15019"/>
		<updated>2023-03-14T21:59:33Z</updated>

		<summary type="html">&lt;p&gt;Vanilla: Reverted edits by Pxls players need to touch grass (talk) to last revision by imported&amp;gt;LenEnjoyer&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{HentaiLover_User_Template|name=Temriel|pixels_placed=413k+|joined=24th of October - 2019, [[C28]]|faction_allegence=[[The Purple Empire]] &amp;lt;br&amp;gt; [[Chromatic Empire]]|image2=File:Pfp ver of awesome art.png}}&lt;br /&gt;
The user [https://pxls.space/profile/Temriel Temriel] has been a member since 24/10/2019, taking several hiatuses with different lengths, with the last one ending on 23/11/2021. He is currently the faction leader of [[The Purple Empire]], and co-leader/co-founder/second in command (Chancellor) of the [[Chromatic Empire]].   &lt;br /&gt;
&lt;br /&gt;
To conform and immerse himself more in the site, he has come up with a sort of dynastic house, with the name of the &amp;quot;House of Deltearia&amp;quot; (possessive: Deltearian). This house rules over [[The Purple Empire]] as the leading house, and Temriel himself being head of house.     &lt;br /&gt;
== Canvases ==&lt;br /&gt;
&lt;br /&gt;
=== 2019 ===&lt;br /&gt;
&lt;br /&gt;
==== [[Canvas 28]] ====&lt;br /&gt;
Temriel joined pxls on the 24th of October 2019 after hearing it from an external source (editors note, he did not come with the [[TikTok Invasion]], it was something else). He started in the bottom right of the canvas, slowly but surely placing blue pixels, until an explosion of people joined his discord server, massively inflating the Empire&#039;s size, which would then be the reason for it&#039;s downfall. The faction (and by extension, Temriel) attacked artwork, lattices, and was pretty hostile, which means that it only lasted a few days until Temriel gave the ownership to someone else on the Discord server as the Empire was collapsing. He originally thought that this would be the last time he would be on pxls as he couldn&#039;t show his face afterwards due to the humiliating defeat, however next canvas he would return once again. &lt;br /&gt;
&lt;br /&gt;
==== [[Canvas 29]] ====&lt;br /&gt;
When he came back once again, [[the Swedish Empire]] was his new faction to place for, and for most of the canvas he was uninvolved with drama personally, and mostly just placed on the Swedish flag that the faction had put over the country. He would help in the conquest of Norway, help in the &amp;quot;sinkmark&amp;quot; initiative and later respect [[Pinkmark|Pinkmarks]] position as controllers of Denmark, even though he did want the Swedish Empire to take it over as well.  Later, he would help the Swedish colonial attempts and subsequent conquest of Peru. &lt;br /&gt;
&lt;br /&gt;
==== [[Canvas 30]] ====&lt;br /&gt;
This canvas saw the Swedish Empire join the [[Second Pixel Axis]], which Temriel would help place on in small amounts. After a long while when the template was completed, he saw fit to recreate [[The Blue Empire]] from [[Canvas 28]], but in a much smaller and way less organized form. No discord server would be created to support this, and he would never make notice of it during the time it existed. &lt;br /&gt;
&lt;br /&gt;
He would end this canvas having placed 2443 pixels. &lt;br /&gt;
&lt;br /&gt;
===== [[Canvas 30a]] =====&lt;br /&gt;
Seeing that the SPA wasn&#039;t making any real artwork this canvas, Temriel once again decided to make a solo piece. It was a repeatable pattern it a specific way so it could be considered a lattice. This would also count as a sort-of revival of [[The Blue Empire]] once again, but as on c30, it was not official.&lt;br /&gt;
&lt;br /&gt;
=== 2021 ===&lt;br /&gt;
&lt;br /&gt;
==== [[Canvas 51]] ====&lt;br /&gt;
During late November of this canvas, Temriel decided to finally return after a long hiatus of not using pxls. He would found and lead a purple-based background [[faction]] known as [[The Purple Empire]], or &#039;&#039;&#039;TPE&#039;&#039;&#039;. The name officially uses the definitive article as to not have the acronym be &amp;quot;PE&amp;quot;, a personal choice he himself decided. &lt;br /&gt;
&lt;br /&gt;
He would end this canvas having placed 3809 pixels, the lowest in recent history (ignoring [[-snip- mode]] canvases).&lt;br /&gt;
&lt;br /&gt;
=== 2021/2022 ===&lt;br /&gt;
&lt;br /&gt;
==== [[Canvas 52]] ====&lt;br /&gt;
aeaeae&lt;br /&gt;
&lt;br /&gt;
He would end this canvas having placed 17424 pixels.&lt;br /&gt;
&lt;br /&gt;
=== 2022 ===&lt;br /&gt;
&lt;br /&gt;
==== [[Canvas 53]] ====&lt;br /&gt;
He would end this canvas having placed 22100 pixels.&lt;br /&gt;
&lt;br /&gt;
==== [[Canvas 54]] ====&lt;br /&gt;
He would end this canvas having placed 20295 pixels.&lt;br /&gt;
&lt;br /&gt;
==== [[Canvas 55]] ====&lt;br /&gt;
Finding a spot for TPE this canvas was easy, with the claiming template only being the emblem, name, and discord invite. This would later get expanded to include various other artworks. The initial claim went next to the [[Femboy Café]] after he had conversed with [[Femboy Café|DelilahArt]] about going next to his faction, and surrounding it in the colour purple. This however did not go to plan after the multiple DDoS attacks against the Pxls.space platform during the [[Place Invasion]], in tandem with the much higher user- and cooldown- times. &lt;br /&gt;
&lt;br /&gt;
Dealing with the aftermath of the [[Place Invasion]], like with the other background factions alike, such as [[Orange Gang]] and the [[Navy Blue Grand Monarchy]], was a chaotic experience no one really was used to. Standard policy for all three factions was to not allow artwork on their backgrounds after it had been placed, which succeed for [[Orange Gang]], most likely due to it being a lighter colour, and the [[Navy Blue Grand Monarchy]], due to their sheer strength. Temriel&#039;s faction, the [[The Purple Empire]] however, was not as lucky. Compared to other TPE canvases, this one was by far the most art packed canvas, though thankfully almost all artwork built over TPE was at least some shade of purple. The entire invasion, along with the high cooldowns and user counts, lead to Temriel not nearly placing as many pixels as before, and his ability to defend TPE&#039;s background was therefore quite lackluster, which he would consider &amp;quot;Quite the embarrassment, and not really fun to be forced to see your pixels be placed over.&amp;quot;&lt;br /&gt;
&lt;br /&gt;
However, during the later days of this canvas, a new faction would be formed, with Temriel as one of the co-founders. This, of course, would become the [[Chromatic Empire]], with Temriel as the factions&#039; Chancellor. Along with [[PineApple|pineApple (Liam)]] and [[Orange Gang|Monster_Chicken]], the three factions of [[The Purple Empire]], the [[Navy Blue Grand Monarchy]] and [[Orange Gang]], would unify under a singular banner to both strengthen each other and protect each others backgrounds. [[H2O Fan Club]] (then H2O Lattice) would later also join the Chromatic Empire as a full Imperial Subject, akin to the other factions already apart of the Chromatic Empire.&lt;br /&gt;
&lt;br /&gt;
He would end this canvas having placed 13774 pixels.&lt;br /&gt;
&lt;br /&gt;
==== [[Canvas 56]] ====&lt;br /&gt;
He would end this canvas having placed 11633 pixels.&lt;br /&gt;
&lt;br /&gt;
==== [[Canvas 56a]] ====&lt;br /&gt;
He would end this canvas having placed 1712 pixels.&lt;br /&gt;
&lt;br /&gt;
==== [[Canvas 57]] ====&lt;br /&gt;
He would end this canvas having placed 18043 pixels.&lt;br /&gt;
&lt;br /&gt;
==== [[Canvas 58]] ====&lt;br /&gt;
He would end this canvas having placed 30989 pixels.&lt;br /&gt;
&lt;br /&gt;
==== [[Canvas 59]] ====&lt;br /&gt;
He would end this canvas having placed 30937 pixels.&lt;br /&gt;
&lt;br /&gt;
==== [[Canvas 60]] ====&lt;br /&gt;
He would end this canvas having placed 45639 pixels&lt;br /&gt;
&lt;br /&gt;
==== [[Canvas 60a]] ====&lt;br /&gt;
He would end this canvas having placed 5147 pixels, the most he has ever placed on a [[-snip- mode]] canvas. &lt;br /&gt;
&lt;br /&gt;
==== [[Canvas 61]] ====&lt;br /&gt;
He would end this canvas having placed 27773 pixels.&lt;br /&gt;
&lt;br /&gt;
==== [[Canvas 62]] ====&lt;br /&gt;
He would end this canvas having placed 36730 pixels.&lt;br /&gt;
&lt;br /&gt;
==== [[Canvas 63]] ====&lt;br /&gt;
He would end this canvas having placed 47245 pixels, the most he has ever placed in a single canvas.&lt;br /&gt;
&lt;br /&gt;
=== 2022/2023 ===&lt;br /&gt;
&lt;br /&gt;
==== [[Canvas 64]] ====&lt;br /&gt;
He would end this canvas having placed 39474 pixels.&lt;br /&gt;
&lt;br /&gt;
=== 2023 ===&lt;br /&gt;
&lt;br /&gt;
==== [[Canvas 64a]] ====&lt;br /&gt;
He would end this canvas having placed 1209 pixels, the lowest so far in recent history.&lt;br /&gt;
&lt;br /&gt;
== Factions ==&lt;br /&gt;
&lt;br /&gt;
=== Current Factions ===&lt;br /&gt;
&lt;br /&gt;
====[[The Purple Empire]]====&lt;br /&gt;
Self proclaimed emperor of [[the Purple Empire]], created the same day his latest hiatus ended, on 23/11/2021, this is a faction, like it&#039;s name entails, a faction for purple. When it started, it only placed purple pixels and did not make any arts, which proved to be not the best strategy. This continued for the rest of [[canvas 51]] and 1/3 into [[canvas 52]]. It was during this time that DelilahVR reached out to him to try to get him to actually put art on the canvas, which didn&#039;t go too well. Temriel originally thought that it was not needed, yet realized later on that background factions need art to survive properly.&lt;br /&gt;
&lt;br /&gt;
====[[Chromatic Empire]]====&lt;br /&gt;
Temriel and the rest of [[The Purple Empire]] joined the [[Chromatic Empire]] on [[canvas 55]] as a founding member, and shortly after Temriel became the Empire&#039;s Chancellor, while the Imperial Chromatic throne was given to [[pineApple]]. &lt;br /&gt;
&lt;br /&gt;
=== Previous Factions ===&lt;br /&gt;
&lt;br /&gt;
====[[The Blue Empire]]====&lt;br /&gt;
The first faction that Temriel had been a part of was his own faction of [[The Blue Empire]], a pxls spin-off of the Blue Corner from /r/place (not to be confused with the [[Navy Blue Grand Monarchy]]). This faction has re-appeared 4 times, first on [[Canvas 28]], slightly on [[Canvas 30]], a larger bit on [[Canvas 30a]] and lastly on [[Canvas 37]]. &lt;br /&gt;
&lt;br /&gt;
==== [[Swedish Empire|The Swedish Empire]] ====&lt;br /&gt;
After the disastrous campaigns Temriel had launched during [[Canvas 28]], and the subsequent downfall of the Empire, he decided to switch factions and place for one that represented his home country of Sweden. It appeared to be a success in reviving his interest in pxls further, as he was additionally active on [[Canvas 30]] and other currently unknown canvases.&lt;br /&gt;
&lt;br /&gt;
==== [[Second Pixel Axis]] ====&lt;br /&gt;
During [[Canvas 29]] in the later parts of the canvas, the idea of a [[Second Pixel Axis]] was come up with between the leaders of several nationalistic factions, and [[ManePxls]]. When the template for it was announced on [[Canvas 30]], he began placing on it to symbolize his allegiance to both the [[Swedish Empire]] and to the [[Second Pixel Axis]].&lt;br /&gt;
&lt;br /&gt;
During [[Canvas 32]] he also placed for the faction in the large and controversial art collab between the [[Second Pixel Axis]] and the [[New Pixel Allies]]. Notably, he also helped in slight amounts with the :pizdec: lattice surrounding the artworks.&lt;br /&gt;
&lt;br /&gt;
==== [[Polonian Pxls]] ====&lt;br /&gt;
On several canvases, starting from [[Canvas 38]], &#039;&#039;&#039;Temriel&#039;&#039;&#039; had found himself aligning with a Polish-themed faction, owned by [[Polonian Pxls|YoujPL]]. He placed for the faction on [[Canvas 38]], [[Canvas 39]], [[Canvas 40]], [[Canvas 41]], [[Canvas 42]] and [[Canvas 43]]. During [[Canvas 44]], he only placed around 250 pixels for the faction, and on [[Canvas 45]] and [[Canvas 46]] it was less than 100 a canvas.&lt;br /&gt;
&lt;br /&gt;
==== [[The Magenta Empire]] ====&lt;br /&gt;
A very short concept faction, based upon the colour of Purple. This was due to Temriel thinking the Purple on-site was called Magenta. When he realized his mistake, the faction name was quickly changed to [[The Purple Empire]], what we have now.&lt;br /&gt;
&lt;br /&gt;
The concept was not dead however, as on [[Canvas 60]], upon discovering most of the canvas was purple Temriel decided to revive the faction idea but have it be mauve instead. Finding out that the acronym could be changed to &amp;quot;TEM&amp;quot; from [[E-Aria]], &#039;&#039;&#039;The Magenta Empire&#039;&#039;&#039; became a thing again, but this time mauve. &lt;br /&gt;
[[Category:Users]]&lt;br /&gt;
[[Category:WIP]]&lt;/div&gt;</summary>
		<author><name>Vanilla</name></author>
	</entry>
	<entry>
		<id>https://wiki.pxls.space/index.php?title=Pxls_staff&amp;diff=14998</id>
		<title>Pxls staff</title>
		<link rel="alternate" type="text/html" href="https://wiki.pxls.space/index.php?title=Pxls_staff&amp;diff=14998"/>
		<updated>2023-03-13T18:21:23Z</updated>

		<summary type="html">&lt;p&gt;Vanilla: Reverted edits by TheWaffleLord (talk) to last revision by Vanilla&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The &#039;&#039;&#039;Pxls staff &#039;&#039;&#039;are a group of users who are in charge of maintaining civility and enforcing general rules among the Pxls community. They have access to [[Pxls staff#Permissions and privileges|advanced permissions]] on the site and Discord server to meet this goal.&lt;br /&gt;
&lt;br /&gt;
== History ==&lt;br /&gt;
[Note from the author: this section should be written by someone with more experience and qualification on the subject haha]&lt;br /&gt;
&lt;br /&gt;
== Permissions and privileges ==&lt;br /&gt;
&lt;br /&gt;
=== Site ===&lt;br /&gt;
* &#039;&#039;&#039;Chatban: &#039;&#039;&#039;Purges messages from a certain user (optional) and prevents them from talking in the website chat for &#039;&#039;x&#039;&#039; amount of time. Does not prevent them placing pixels on the canvas.&lt;br /&gt;
* &#039;&#039;&#039;Canvas ban: &#039;&#039;&#039;Prevents a user from placing on the canvas or talking in chat for &#039;&#039;x&#039;&#039; amount of time. This also (optionally) removes their pixels on the canvas, in a fashion similar to a [[nuke]].&lt;br /&gt;
* &#039;&#039;&#039;Faction management: &#039;&#039;&#039;Can delete&amp;lt;ref&amp;gt;As evidenced by the deleting of a faction tag with a shield on it for impersonating the staff badge.&amp;lt;/ref&amp;gt; factions from the site list. (admin only)&lt;br /&gt;
* &#039;&#039;&#039;Staff badge: &#039;&#039;&#039;Exists to set them apart in the chat. Both admins and moderators show up under this badge.&lt;br /&gt;
&lt;br /&gt;
=== Discord server ===&lt;br /&gt;
* &#039;&#039;&#039;Kicking/Banning: &#039;&#039;&#039;A one-off removal or a permanent ejection from the Discord server.&lt;br /&gt;
* &#039;&#039;&#039;Announcements: &#039;&#039;&#039;Can send out announcements to a) the main Pxls.space server and by extension any Discord servers &amp;quot;following&amp;quot; the announcements channel, and b) an announcements feed on the website. (admin only)&lt;br /&gt;
&lt;br /&gt;
=== Other responsibilities ===&lt;br /&gt;
* Authority figures on the Pxls.space subreddit (possibly)&amp;lt;ref&amp;gt;[https://docs.google.com/forms/d/e/1FAIpQLSe3UYqJX-QRR2v0Huda_q643WeBFLodf9elfOFhIDBSguM7wQ/viewform Pxls.space moderator application]&amp;lt;/ref&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Current Pxls staff ==&lt;br /&gt;
{| class=&amp;quot;article-table sortable&amp;quot;&lt;br /&gt;
!Canvas name&lt;br /&gt;
!Role(s)&lt;br /&gt;
!Notes&lt;br /&gt;
|-&lt;br /&gt;
|Nanineye&lt;br /&gt;
|Owner, Manager, Administrator&lt;br /&gt;
|Owner of the Pxls.space Discord server, co-owns the site&lt;br /&gt;
|-&lt;br /&gt;
|Sidestep&lt;br /&gt;
|Manager, Administrator&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|Iceydwagon&lt;br /&gt;
|Administrator&lt;br /&gt;
|Dark on discord, Pxls subreddit moderator, Leader of [[Void]]&lt;br /&gt;
|-&lt;br /&gt;
|Etos2&lt;br /&gt;
|Moderator&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|drake&lt;br /&gt;
|Moderator&lt;br /&gt;
|koro on discord, Leader of [[Grayscale Pxls]]&lt;br /&gt;
|-&lt;br /&gt;
|gaudi999&lt;br /&gt;
|Moderator&lt;br /&gt;
|Gaudi on discord, Leader of [[Gura&#039;s Supermarket]]&lt;br /&gt;
|-&lt;br /&gt;
|filipus098&lt;br /&gt;
|Trail Moderator&lt;br /&gt;
|Currently only moderator to be both canvas and discord banned previously&lt;br /&gt;
|-&lt;br /&gt;
|_Etta&lt;br /&gt;
|Trail Moderator&lt;br /&gt;
|Leader of the [[Margraviate of Solvernia]]&lt;br /&gt;
|-&lt;br /&gt;
|Vanilla&lt;br /&gt;
|Project Lead, Developer&lt;br /&gt;
|Pxls subreddit moderator, owns the site&lt;br /&gt;
|-&lt;br /&gt;
|__&lt;br /&gt;
|Developer&lt;br /&gt;
|[ ] on discord&lt;br /&gt;
|-&lt;br /&gt;
|Mikarific&lt;br /&gt;
|Developer&lt;br /&gt;
|Creator of Stem Place Pxls clone, Leader of [[Pride Faction]]&lt;br /&gt;
|-&lt;br /&gt;
|Doxylamin&lt;br /&gt;
|Developer&lt;br /&gt;
|&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Former Pxls staff ==&lt;br /&gt;
pahanya, Chalkless, Rasputin, Styx, GlowingSocc, c4rt, nerfarrow, pharot, [[Atomic10|Andrew]], [[Fruity|cutiefruity]], squiddies, Ske, Elly, Hoppy Tiller, Rainsford, Sorunome, Alanha, Ludus, [[Kori]], Lana, Vanilla, Chocolate, Elaine, Darky, gunnerwolf, Simius, SR17740, Netux, Helislothic, Faust, [[funta]], Nya, [[TheWaffleLord]], Sen_Ruoka, dani26795, Snegovich&lt;br /&gt;
&lt;br /&gt;
==See also==&lt;br /&gt;
&lt;br /&gt;
==References==&lt;br /&gt;
&amp;lt;references /&amp;gt;&lt;br /&gt;
[[Category:WIP]]&lt;br /&gt;
[[Category:Users]]&lt;br /&gt;
[[Category:General Info]]&lt;/div&gt;</summary>
		<author><name>Vanilla</name></author>
	</entry>
	<entry>
		<id>https://wiki.pxls.space/index.php?title=User:Vanilla&amp;diff=14717</id>
		<title>User:Vanilla</title>
		<link rel="alternate" type="text/html" href="https://wiki.pxls.space/index.php?title=User:Vanilla&amp;diff=14717"/>
		<updated>2023-03-04T01:30:40Z</updated>

		<summary type="html">&lt;p&gt;Vanilla: Created page&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Hey there! I&#039;m the current owner of Pxls and work on development for the site. I can be reached on Discord at FlyingSixtySix#4323.&lt;/div&gt;</summary>
		<author><name>Vanilla</name></author>
	</entry>
	<entry>
		<id>https://wiki.pxls.space/index.php?title=Pxls.space_Wiki&amp;diff=14716</id>
		<title>Pxls.space Wiki</title>
		<link rel="alternate" type="text/html" href="https://wiki.pxls.space/index.php?title=Pxls.space_Wiki&amp;diff=14716"/>
		<updated>2023-03-04T01:18:05Z</updated>

		<summary type="html">&lt;p&gt;Vanilla: Removed IP address notice and added link to official archives&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Welcome to the unofficial Pxls.space Wiki!&#039;&#039;&#039; Enjoy your stay!&lt;br /&gt;
&lt;br /&gt;
❗ &#039;&#039;&#039;Be sure to follow the rules listed [[Rules|here]] when making edits to a wiki page, or when creating a new wiki page.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
❗ &#039;&#039;&#039;For the time being, all edits require an account.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
If you want to hang out with editors of the wiki or discuss changes, come join us in the Discord!&lt;br /&gt;
&lt;br /&gt;
https://discord.gg/6zBT6CTnpd&lt;br /&gt;
&amp;lt;gallery&amp;gt;&lt;br /&gt;
&lt;br /&gt;
File:Pxls Canvas 44 Inital.png|thumb|[[Canvases]]&lt;br /&gt;
File:Pxls Canvas 40-0.png|thumb|[[Factions]]&lt;br /&gt;
File:Trollface Battle.PNG|thumb|[[Wars]]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/gallery&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===&#039;&#039;&#039;What is Pxls.space?&#039;&#039;&#039;===&lt;br /&gt;
Pxls.space is a clone of the [https://en.wikipedia.org/wiki/Place_(Reddit) r/place social experiment] performed by the social platform Reddit on the 1st of April 2017. (April Fools Day). After several weeks, the canvas resets and takes on a new shape.&lt;br /&gt;
&lt;br /&gt;
Join the official pxls.space Discord server here: https://pxls.space/discord&lt;br /&gt;
&lt;br /&gt;
Official archives: https://archives.pxls.space/&lt;br /&gt;
&lt;br /&gt;
Third-party site with archives: https://pxlsfiddle.com/&lt;br /&gt;
&lt;br /&gt;
[[Category:Browse]]&lt;/div&gt;</summary>
		<author><name>Vanilla</name></author>
	</entry>
	<entry>
		<id>https://wiki.pxls.space/index.php?title=MediaWiki:Tagline&amp;diff=14609</id>
		<title>MediaWiki:Tagline</title>
		<link rel="alternate" type="text/html" href="https://wiki.pxls.space/index.php?title=MediaWiki:Tagline&amp;diff=14609"/>
		<updated>2023-03-03T15:06:33Z</updated>

		<summary type="html">&lt;p&gt;Vanilla: Remove tagline&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Vanilla</name></author>
	</entry>
	<entry>
		<id>https://wiki.pxls.space/index.php?title=Template:Quote&amp;diff=7757</id>
		<title>Template:Quote</title>
		<link rel="alternate" type="text/html" href="https://wiki.pxls.space/index.php?title=Template:Quote&amp;diff=7757"/>
		<updated>2023-03-01T20:07:42Z</updated>

		<summary type="html">&lt;p&gt;Vanilla: Add redirect to Blockquote&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;#REDIRECT [[Template:Blockquote]]&lt;/div&gt;</summary>
		<author><name>Vanilla</name></author>
	</entry>
	<entry>
		<id>https://wiki.pxls.space/index.php?title=Template:Blockquote&amp;diff=7756</id>
		<title>Template:Blockquote</title>
		<link rel="alternate" type="text/html" href="https://wiki.pxls.space/index.php?title=Template:Blockquote&amp;diff=7756"/>
		<updated>2023-03-01T20:06:44Z</updated>

		<summary type="html">&lt;p&gt;Vanilla: Removed redirect to Template:Quote&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;templatestyles src=&amp;quot;Template:Blockquote/styles.css&amp;quot; /&amp;gt;&amp;lt;!--&lt;br /&gt;
--&amp;gt;&amp;lt;blockquote class=&amp;quot;templatequote {{{class|}}}&amp;quot; {{#if:{{{style|}}}|style=&amp;quot;{{{style}}}&amp;quot;}}&amp;gt;{{{text|{{{content|{{{quotetext|{{{quote|{{{1|&amp;lt;includeonly&amp;gt;{{error|Error: No text given for quotation (or equals sign used in the actual argument to an unnamed parameter)}}{{main other|[[Category:Pages incorrectly using the quote template]]}}&amp;lt;/includeonly&amp;gt;&amp;lt;noinclude&amp;gt;{{lorem ipsum}}&amp;lt;/noinclude&amp;gt;}}}}}}}}}}}}}}}{{#if:{{{sign|}}}{{{cite|}}}{{{author|}}}{{{by|}}}{{{personquoted|}}}{{{source|}}}{{{ts|}}}{{{title|}}}{{{publication|}}}{{{quotesource|}}}{{{char|}}}{{{character|}}}{{{2|}}}{{{3|}}}{{{4|}}}{{{5|}}}|{{#if:{{{multiline|}}}|&amp;lt;nowiki /&amp;gt;}}&lt;br /&gt;
&amp;lt;div class=&amp;quot;templatequotecite&amp;quot;&amp;gt;—&amp;amp;thinsp;&amp;lt;cite&amp;gt;{{#if:{{{char|{{{character|{{{5|}}}}}}}}}|{{{char|{{{character|{{{5|}}}}}}}}}, in&amp;amp;#32;}}{{Comma separated entries&lt;br /&gt;
 | {{if empty|{{{sign|}}}|{{{cite|}}}|{{{author|}}}|{{{by|}}}|{{{personquoted|}}}|{{{2|}}}}}&lt;br /&gt;
 | {{if empty|{{{title|}}}|{{{publication|}}}|{{{ts|}}}|{{{quotesource|}}}|{{{3|}}}}}&lt;br /&gt;
 | {{if empty|{{{source|}}}|{{{4|}}}}}&lt;br /&gt;
 }}&amp;lt;/cite&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
}}&amp;lt;/blockquote&amp;gt;{{#if:{{{id|}}}{{{diff|}}}{{{4|}}}{{{5|}}}|{{main other|[[Category:Pages incorrectly using the Blockquote template]]}}}}{{#invoke:Check for unknown parameters|check|unknown={{main other|[[Category:Pages using Blockquote template with unknown parameters|_VALUE_{{PAGENAME}}]]}}|preview=Page using [[Template:Blockquote]] with unknown parameter &amp;quot;_VALUE_&amp;quot;|ignoreblank=y| 1 | 2 | 3 | 4 | 5 | author | by | char | character | cite | class | content | diff | id | multiline | personquoted | publication | quote | quotesource | quotetext | sign | source | style | text | title | ts }}&amp;lt;noinclude&amp;gt;&lt;br /&gt;
{{documentation}}&amp;lt;!-- Add categories to the /doc subpage, not here! --&amp;gt;&lt;br /&gt;
&amp;lt;/noinclude&amp;gt;&lt;/div&gt;</summary>
		<author><name>Vanilla</name></author>
	</entry>
	<entry>
		<id>https://wiki.pxls.space/index.php?title=Template:Blockquote&amp;diff=7753</id>
		<title>Template:Blockquote</title>
		<link rel="alternate" type="text/html" href="https://wiki.pxls.space/index.php?title=Template:Blockquote&amp;diff=7753"/>
		<updated>2023-03-01T20:05:28Z</updated>

		<summary type="html">&lt;p&gt;Vanilla: Add Quote template redirect&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;#REDIRECT [[Template:Quote]]&lt;br /&gt;
&amp;lt;templatestyles src=&amp;quot;Template:Blockquote/styles.css&amp;quot; /&amp;gt;&amp;lt;!--&lt;br /&gt;
--&amp;gt;&amp;lt;blockquote class=&amp;quot;templatequote {{{class|}}}&amp;quot; {{#if:{{{style|}}}|style=&amp;quot;{{{style}}}&amp;quot;}}&amp;gt;{{{text|{{{content|{{{quotetext|{{{quote|{{{1|&amp;lt;includeonly&amp;gt;{{error|Error: No text given for quotation (or equals sign used in the actual argument to an unnamed parameter)}}{{main other|[[Category:Pages incorrectly using the quote template]]}}&amp;lt;/includeonly&amp;gt;&amp;lt;noinclude&amp;gt;{{lorem ipsum}}&amp;lt;/noinclude&amp;gt;}}}}}}}}}}}}}}}{{#if:{{{sign|}}}{{{cite|}}}{{{author|}}}{{{by|}}}{{{personquoted|}}}{{{source|}}}{{{ts|}}}{{{title|}}}{{{publication|}}}{{{quotesource|}}}{{{char|}}}{{{character|}}}{{{2|}}}{{{3|}}}{{{4|}}}{{{5|}}}|{{#if:{{{multiline|}}}|&amp;lt;nowiki /&amp;gt;}}&lt;br /&gt;
&amp;lt;div class=&amp;quot;templatequotecite&amp;quot;&amp;gt;—&amp;amp;thinsp;&amp;lt;cite&amp;gt;{{#if:{{{char|{{{character|{{{5|}}}}}}}}}|{{{char|{{{character|{{{5|}}}}}}}}}, in&amp;amp;#32;}}{{Comma separated entries&lt;br /&gt;
 | {{if empty|{{{sign|}}}|{{{cite|}}}|{{{author|}}}|{{{by|}}}|{{{personquoted|}}}|{{{2|}}}}}&lt;br /&gt;
 | {{if empty|{{{title|}}}|{{{publication|}}}|{{{ts|}}}|{{{quotesource|}}}|{{{3|}}}}}&lt;br /&gt;
 | {{if empty|{{{source|}}}|{{{4|}}}}}&lt;br /&gt;
 }}&amp;lt;/cite&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
}}&amp;lt;/blockquote&amp;gt;{{#if:{{{id|}}}{{{diff|}}}{{{4|}}}{{{5|}}}|{{main other|[[Category:Pages incorrectly using the Blockquote template]]}}}}{{#invoke:Check for unknown parameters|check|unknown={{main other|[[Category:Pages using Blockquote template with unknown parameters|_VALUE_{{PAGENAME}}]]}}|preview=Page using [[Template:Blockquote]] with unknown parameter &amp;quot;_VALUE_&amp;quot;|ignoreblank=y| 1 | 2 | 3 | 4 | 5 | author | by | char | character | cite | class | content | diff | id | multiline | personquoted | publication | quote | quotesource | quotetext | sign | source | style | text | title | ts }}&amp;lt;noinclude&amp;gt;&lt;br /&gt;
{{documentation}}&amp;lt;!-- Add categories to the /doc subpage, not here! --&amp;gt;&lt;br /&gt;
&amp;lt;/noinclude&amp;gt;&lt;/div&gt;</summary>
		<author><name>Vanilla</name></author>
	</entry>
	<entry>
		<id>https://wiki.pxls.space/index.php?title=Template:Blockquote/styles.css&amp;diff=7752</id>
		<title>Template:Blockquote/styles.css</title>
		<link rel="alternate" type="text/html" href="https://wiki.pxls.space/index.php?title=Template:Blockquote/styles.css&amp;diff=7752"/>
		<updated>2023-03-01T20:02:23Z</updated>

		<summary type="html">&lt;p&gt;Vanilla: https://en.wikipedia.org/w/index.php?title=Template:Blockquote/styles.css&amp;amp;action=edit&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;/* {{pp-template}} */&lt;br /&gt;
.templatequote {&lt;br /&gt;
	overflow: hidden;&lt;br /&gt;
	margin: 1em 0;&lt;br /&gt;
	padding: 0 40px;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
.templatequote .templatequotecite {&lt;br /&gt;
    line-height: 1.5em;&lt;br /&gt;
    /* @noflip */&lt;br /&gt;
    text-align: left;&lt;br /&gt;
    /* @noflip */&lt;br /&gt;
    padding-left: 1.6em;&lt;br /&gt;
    margin-top: 0;&lt;br /&gt;
}&lt;/div&gt;</summary>
		<author><name>Vanilla</name></author>
	</entry>
	<entry>
		<id>https://wiki.pxls.space/index.php?title=Template:Blockquote&amp;diff=7751</id>
		<title>Template:Blockquote</title>
		<link rel="alternate" type="text/html" href="https://wiki.pxls.space/index.php?title=Template:Blockquote&amp;diff=7751"/>
		<updated>2023-03-01T20:02:04Z</updated>

		<summary type="html">&lt;p&gt;Vanilla: https://en.wikipedia.org/w/index.php?title=Template:Blockquote&amp;amp;action=edit&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;templatestyles src=&amp;quot;Template:Blockquote/styles.css&amp;quot; /&amp;gt;&amp;lt;!--&lt;br /&gt;
--&amp;gt;&amp;lt;blockquote class=&amp;quot;templatequote {{{class|}}}&amp;quot; {{#if:{{{style|}}}|style=&amp;quot;{{{style}}}&amp;quot;}}&amp;gt;{{{text|{{{content|{{{quotetext|{{{quote|{{{1|&amp;lt;includeonly&amp;gt;{{error|Error: No text given for quotation (or equals sign used in the actual argument to an unnamed parameter)}}{{main other|[[Category:Pages incorrectly using the quote template]]}}&amp;lt;/includeonly&amp;gt;&amp;lt;noinclude&amp;gt;{{lorem ipsum}}&amp;lt;/noinclude&amp;gt;}}}}}}}}}}}}}}}{{#if:{{{sign|}}}{{{cite|}}}{{{author|}}}{{{by|}}}{{{personquoted|}}}{{{source|}}}{{{ts|}}}{{{title|}}}{{{publication|}}}{{{quotesource|}}}{{{char|}}}{{{character|}}}{{{2|}}}{{{3|}}}{{{4|}}}{{{5|}}}|{{#if:{{{multiline|}}}|&amp;lt;nowiki /&amp;gt;}}&lt;br /&gt;
&amp;lt;div class=&amp;quot;templatequotecite&amp;quot;&amp;gt;—&amp;amp;thinsp;&amp;lt;cite&amp;gt;{{#if:{{{char|{{{character|{{{5|}}}}}}}}}|{{{char|{{{character|{{{5|}}}}}}}}}, in&amp;amp;#32;}}{{Comma separated entries&lt;br /&gt;
 | {{if empty|{{{sign|}}}|{{{cite|}}}|{{{author|}}}|{{{by|}}}|{{{personquoted|}}}|{{{2|}}}}}&lt;br /&gt;
 | {{if empty|{{{title|}}}|{{{publication|}}}|{{{ts|}}}|{{{quotesource|}}}|{{{3|}}}}}&lt;br /&gt;
 | {{if empty|{{{source|}}}|{{{4|}}}}}&lt;br /&gt;
 }}&amp;lt;/cite&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
}}&amp;lt;/blockquote&amp;gt;{{#if:{{{id|}}}{{{diff|}}}{{{4|}}}{{{5|}}}|{{main other|[[Category:Pages incorrectly using the Blockquote template]]}}}}{{#invoke:Check for unknown parameters|check|unknown={{main other|[[Category:Pages using Blockquote template with unknown parameters|_VALUE_{{PAGENAME}}]]}}|preview=Page using [[Template:Blockquote]] with unknown parameter &amp;quot;_VALUE_&amp;quot;|ignoreblank=y| 1 | 2 | 3 | 4 | 5 | author | by | char | character | cite | class | content | diff | id | multiline | personquoted | publication | quote | quotesource | quotetext | sign | source | style | text | title | ts }}&amp;lt;noinclude&amp;gt;&lt;br /&gt;
{{documentation}}&amp;lt;!-- Add categories to the /doc subpage, not here! --&amp;gt;&lt;br /&gt;
&amp;lt;/noinclude&amp;gt;&lt;/div&gt;</summary>
		<author><name>Vanilla</name></author>
	</entry>
	<entry>
		<id>https://wiki.pxls.space/index.php?title=MediaWiki:Common.css&amp;diff=7745</id>
		<title>MediaWiki:Common.css</title>
		<link rel="alternate" type="text/html" href="https://wiki.pxls.space/index.php?title=MediaWiki:Common.css&amp;diff=7745"/>
		<updated>2023-03-01T14:28:12Z</updated>

		<summary type="html">&lt;p&gt;Vanilla: https://en.wikipedia.org/w/index.php?title=MediaWiki:Common.css&amp;amp;action=edit&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;/*&lt;br /&gt;
 * This is the CSS common to all desktop skins on en.Wikipedia.&lt;br /&gt;
 * Styling inside .mw-parser-output should generally use TemplateStyles.&lt;br /&gt;
 */&lt;br /&gt;
/* Reset italic styling set by user agent */&lt;br /&gt;
cite,&lt;br /&gt;
dfn {&lt;br /&gt;
	font-style: inherit;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
/* Straight quote marks for &amp;lt;q&amp;gt; */&lt;br /&gt;
q {&lt;br /&gt;
	quotes: &#039;&amp;quot;&#039; &#039;&amp;quot;&#039; &amp;quot;&#039;&amp;quot; &amp;quot;&#039;&amp;quot;;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
/* Avoid collision of blockquote with floating elements by swapping margin and padding */&lt;br /&gt;
blockquote {&lt;br /&gt;
	overflow: hidden;&lt;br /&gt;
	margin: 1em 0;&lt;br /&gt;
	padding: 0 40px;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
/* Consistent size for &amp;lt;small&amp;gt;, &amp;lt;sub&amp;gt; and &amp;lt;sup&amp;gt; */&lt;br /&gt;
small {&lt;br /&gt;
	font-size: 85%;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
.mw-body-content sub,&lt;br /&gt;
.mw-body-content sup {&lt;br /&gt;
	font-size: 80%;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
/* Same spacing for indented and unindented paragraphs on talk pages */&lt;br /&gt;
.ns-talk .mw-body-content dd {&lt;br /&gt;
	margin-top: 0.4em;&lt;br /&gt;
	margin-bottom: 0.4em;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
/* Reduce page jumps by hiding collapsed/dismissed content */&lt;br /&gt;
.client-js .mw-special-Watchlist #watchlist-message,&lt;br /&gt;
.client-js .collapsible:not( .mw-made-collapsible).collapsed &amp;gt; tbody &amp;gt; tr:not(:first-child),&lt;br /&gt;
&lt;br /&gt;
/* Avoid FOUC/reflows on collapsed elements. */&lt;br /&gt;
/* This copies MediaWiki&#039;s solution for T42812 to apply to innercollapse/outercollapse (T325115). */&lt;br /&gt;
/* TODO: Use :is() selector at some reasonable future when support is good for Most Clients */&lt;br /&gt;
/* Reference: https://gerrit.wikimedia.org/g/mediawiki/core/+/ecda06cb2aef55b77c4b4d7ecda492d634419ead/resources/src/jquery/jquery.makeCollapsible.styles.less#75 */&lt;br /&gt;
.client-js .outercollapse .innercollapse.mw-collapsible:not( .mw-made-collapsible ) &amp;gt; p,&lt;br /&gt;
.client-js .outercollapse .innercollapse.mw-collapsible:not( .mw-made-collapsible ) &amp;gt; table,&lt;br /&gt;
.client-js .outercollapse .innercollapse.mw-collapsible:not( .mw-made-collapsible ) &amp;gt; thead + tbody,&lt;br /&gt;
.client-js .outercollapse .innercollapse.mw-collapsible:not( .mw-made-collapsible ) tr:not( :first-child ),&lt;br /&gt;
.client-js .outercollapse .innercollapse.mw-collapsible:not( .mw-made-collapsible ) .mw-collapsible-content,&lt;br /&gt;
&lt;br /&gt;
/* Hide charinsert base for those not using the gadget */&lt;br /&gt;
#editpage-specialchars {&lt;br /&gt;
	display: none;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
/* Make the list of references smaller&lt;br /&gt;
 * Keep in sync with Template:Refbegin/styles.css&lt;br /&gt;
 * And Template:Reflist/styles.css&lt;br /&gt;
 */&lt;br /&gt;
ol.references {&lt;br /&gt;
	font-size: 90%;&lt;br /&gt;
	margin-bottom: 0.5em;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
/* Cite customizations for Parsoid&lt;br /&gt;
 * Once everything uses the one true parser these are just customizations&lt;br /&gt;
 */&lt;br /&gt;
span[ rel=&amp;quot;mw:referencedBy&amp;quot; ] {&lt;br /&gt;
	counter-reset: mw-ref-linkback 0;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
span[ rel=&#039;mw:referencedBy&#039; ] &amp;gt; a::before {&lt;br /&gt;
	content: counter( mw-ref-linkback, lower-alpha );&lt;br /&gt;
	font-size: 80%;&lt;br /&gt;
	font-weight: bold;&lt;br /&gt;
	font-style: italic;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
a[ rel=&amp;quot;mw:referencedBy&amp;quot; ]::before {&lt;br /&gt;
	font-weight: bold;&lt;br /&gt;
	content: &amp;quot;^&amp;quot;;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
span[ rel=&amp;quot;mw:referencedBy&amp;quot; ]::before {&lt;br /&gt;
	content: &amp;quot;^ &amp;quot;;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
.mw-ref &amp;gt; a[data-mw-group=lower-alpha]::after {&lt;br /&gt;
	content: &#039;[&#039; counter( mw-Ref, lower-alpha ) &#039;]&#039;;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
.mw-ref &amp;gt; a[data-mw-group=upper-alpha]::after {&lt;br /&gt;
	content: &#039;[&#039; counter( mw-Ref, upper-alpha ) &#039;]&#039;;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
.mw-ref &amp;gt; a[data-mw-group=decimal]::after {&lt;br /&gt;
	content: &#039;[&#039; counter( mw-Ref, decimal ) &#039;]&#039;;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
.mw-ref &amp;gt; a[data-mw-group=lower-roman]::after {&lt;br /&gt;
	content: &#039;[&#039; counter( mw-Ref, lower-roman ) &#039;]&#039;;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
.mw-ref &amp;gt; a[data-mw-group=upper-roman]::after {&lt;br /&gt;
	content: &#039;[&#039; counter( mw-Ref, upper-roman ) &#039;]&#039;;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
.mw-ref &amp;gt; a[data-mw-group=lower-greek]::after {&lt;br /&gt;
	content: &#039;[&#039; counter( mw-Ref, lower-greek ) &#039;]&#039;;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
/* Styling for jQuery makeCollapsible, matching that of collapseButton */&lt;br /&gt;
.mw-parser-output .mw-collapsible-toggle:not(.mw-ui-button) {&lt;br /&gt;
	font-weight: normal;&lt;br /&gt;
	padding-right: 0.2em;&lt;br /&gt;
	padding-left: 0.2em;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
.mw-collapsible-leftside-toggle .mw-collapsible-toggle {&lt;br /&gt;
	/* @noflip */&lt;br /&gt;
	float: left;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
/* Lists in wikitable data cells are always left-aligned */&lt;br /&gt;
.wikitable td ul,&lt;br /&gt;
.wikitable td ol,&lt;br /&gt;
.wikitable td dl {&lt;br /&gt;
	/* @noflip */&lt;br /&gt;
	text-align: left;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
/* Change the external link icon to a PDF icon for all PDF files */&lt;br /&gt;
.mw-parser-output a[href$=&amp;quot;.pdf&amp;quot;].external,&lt;br /&gt;
.mw-parser-output a[href*=&amp;quot;.pdf?&amp;quot;].external,&lt;br /&gt;
.mw-parser-output a[href*=&amp;quot;.pdf#&amp;quot;].external,&lt;br /&gt;
.mw-parser-output a[href$=&amp;quot;.PDF&amp;quot;].external,&lt;br /&gt;
.mw-parser-output a[href*=&amp;quot;.PDF?&amp;quot;].external,&lt;br /&gt;
.mw-parser-output a[href*=&amp;quot;.PDF#&amp;quot;].external {&lt;br /&gt;
	background: url(&amp;quot;//upload.wikimedia.org/wikipedia/commons/4/4d/Icon_pdf_file.png&amp;quot;) no-repeat right;&lt;br /&gt;
	/* @noflip */&lt;br /&gt;
	padding: 8px 18px 8px 0;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
/* System messages styled similarly to fmbox */&lt;br /&gt;
div.mw-warning-with-logexcerpt,&lt;br /&gt;
div.mw-lag-warn-high,&lt;br /&gt;
div.mw-cascadeprotectedwarning,&lt;br /&gt;
div#mw-protect-cascadeon,&lt;br /&gt;
div.titleblacklist-warning {&lt;br /&gt;
	clear: both;&lt;br /&gt;
	margin: 0.2em 0;&lt;br /&gt;
	border: 1px solid #bb7070;&lt;br /&gt;
	background-color: #ffdbdb;&lt;br /&gt;
	padding: 0.25em 0.9em;&lt;br /&gt;
	box-sizing: border-box;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
/* default colors for partial block message */&lt;br /&gt;
.mw-contributions-blocked-notice-partial .mw-warning-with-logexcerpt {&lt;br /&gt;
	border-color: #fc3;&lt;br /&gt;
	background-color: #fef6e7;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
/* Increase the height of the image upload box */&lt;br /&gt;
#wpUploadDescription {&lt;br /&gt;
	height: 13em;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
/* Minimum thumb width */&lt;br /&gt;
figure[typeof~=&#039;mw:File/Thumb&#039;],&lt;br /&gt;
figure[typeof~=&#039;mw:File/Frame&#039;],&lt;br /&gt;
.thumbinner {&lt;br /&gt;
	min-width: 100px;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
/* Prevent floating boxes from overlapping any category listings,&lt;br /&gt;
   file histories, edit previews, and edit [Show changes] views. */&lt;br /&gt;
#mw-subcategories,&lt;br /&gt;
#mw-pages,&lt;br /&gt;
#mw-category-media,&lt;br /&gt;
#filehistory,&lt;br /&gt;
#wikiPreview,&lt;br /&gt;
#wikiDiff {&lt;br /&gt;
	clear: both;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
/* Styling for tags in changes pages */&lt;br /&gt;
.mw-tag-markers {&lt;br /&gt;
	font-style: italic;&lt;br /&gt;
	font-size: 90%;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
/* Hide stuff meant for accounts with special permissions. Made visible again in&lt;br /&gt;
   [[MediaWiki:Group-checkuser.css]], [[MediaWiki:Group-sysop.css]], [[MediaWiki:Group-abusefilter.css]],&lt;br /&gt;
   [[MediaWiki:Group-abusefilter-helper.css]], [[MediaWiki:Group-patroller.css]],&lt;br /&gt;
   [[MediaWiki:Group-templateeditor.css]], [[MediaWiki:Group-extendedmover.css]],&lt;br /&gt;
   [[MediaWiki:Group-extendedconfirmed.css]], and [[Mediawiki:Group-autoconfirmed.css]]. */&lt;br /&gt;
.checkuser-show,&lt;br /&gt;
.sysop-show,&lt;br /&gt;
.abusefilter-show,&lt;br /&gt;
.abusefilter-helper-show,&lt;br /&gt;
.patroller-show,&lt;br /&gt;
.templateeditor-show,&lt;br /&gt;
.extendedmover-show,&lt;br /&gt;
.extendedconfirmed-show,&lt;br /&gt;
.autoconfirmed-show,&lt;br /&gt;
.user-show {&lt;br /&gt;
	display: none;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
/* Hide the redlink generated by {{Editnotice}},&lt;br /&gt;
   this overrides the &amp;quot;.sysop-show { display: none; }&amp;quot; above that applies&lt;br /&gt;
   to the same link as well. See [[phab:T45013]]&lt;br /&gt;
&lt;br /&gt;
   Hide the images in editnotices to keep them readable in VE view.&lt;br /&gt;
   Long term, editnotices should become a core feature so that they can be designed responsive. */&lt;br /&gt;
.ve-ui-mwNoticesPopupTool-item .editnotice-redlink,&lt;br /&gt;
.ve-ui-mwNoticesPopupTool-item .mbox-image,&lt;br /&gt;
.ve-ui-mwNoticesPopupTool-item .mbox-imageright {&lt;br /&gt;
	display: none !important;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
/* Remove bullets when there are multiple edit page warnings */&lt;br /&gt;
ul.permissions-errors {&lt;br /&gt;
	margin: 0;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
ul.permissions-errors &amp;gt; li {&lt;br /&gt;
	list-style: none;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
/* larger inline math */&lt;br /&gt;
span.mwe-math-mathml-inline {&lt;br /&gt;
	font-size: 118%;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
/* Make &amp;lt;math display=&amp;quot;block&amp;quot;&amp;gt; be left aligned with one space indent for &lt;br /&gt;
 * compatibility with style conventions&lt;br /&gt;
 */&lt;br /&gt;
.mwe-math-fallback-image-display,&lt;br /&gt;
.mwe-math-mathml-display {&lt;br /&gt;
	margin-left: 1.6em !important;&lt;br /&gt;
	margin-top: 0.6em;&lt;br /&gt;
	margin-bottom: 0.6em;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
.mwe-math-mathml-display math {&lt;br /&gt;
	display: inline;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
@media screen {&lt;br /&gt;
	/* Gallery styles background changes are restricted to screen view.&lt;br /&gt;
	   In printing we should avoid applying backgrounds. */&lt;br /&gt;
	/* The backgrounds for galleries. */&lt;br /&gt;
	#content .gallerybox div.thumb {&lt;br /&gt;
		/* Light gray padding */&lt;br /&gt;
		background-color: #f8f9fa;&lt;br /&gt;
	}&lt;br /&gt;
	/* Put a chequered background behind images, only visible if they have transparency.&lt;br /&gt;
	   &#039;.filehistory a img&#039; and &#039;#file img:hover&#039; are handled by MediaWiki core (as of 1.19) */&lt;br /&gt;
	.gallerybox .thumb img {&lt;br /&gt;
		background: #fff url(//upload.wikimedia.org/wikipedia/commons/5/5d/Checker-16x16.png) repeat;&lt;br /&gt;
	}&lt;br /&gt;
	/* But not on articles, user pages, or portals. */&lt;br /&gt;
	.ns-0 .gallerybox .thumb img,&lt;br /&gt;
	.ns-2 .gallerybox .thumb img,&lt;br /&gt;
	.ns-100 .gallerybox .thumb img {&lt;br /&gt;
		background-image: none;&lt;br /&gt;
	}&lt;br /&gt;
&lt;br /&gt;
	/* Display &amp;quot;From Wikipedia, the free encyclopedia&amp;quot; in skins that support it,&lt;br /&gt;
	   do not apply to print mode */&lt;br /&gt;
	#siteSub {&lt;br /&gt;
		display: block;&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
/* Hide FlaggedRevs notice UI when there are no pending changes */&lt;br /&gt;
.flaggedrevs_draft_synced,&lt;br /&gt;
.flaggedrevs_stable_synced,&lt;br /&gt;
/* &amp;quot;Temporary&amp;quot; to remove links in sidebar T255381 */&lt;br /&gt;
#t-upload,&lt;br /&gt;
/* Hide broken download box on Special:Book pending T285400 */&lt;br /&gt;
.mw-special-Book #coll-downloadbox {&lt;br /&gt;
	display: none;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
/*&lt;br /&gt;
 * BELOW HERE THERE BE SOONTOBE TEMPLATESTYLES THINGS;&lt;br /&gt;
 * SEE [[MediaWiki talk:Common.css/to do]]&lt;br /&gt;
 */&lt;br /&gt;
&lt;br /&gt;
/* Infobox template style */&lt;br /&gt;
.infobox {&lt;br /&gt;
	border: 1px solid #a2a9b1;&lt;br /&gt;
	border-spacing: 3px;&lt;br /&gt;
	background-color: #f8f9fa;&lt;br /&gt;
	color: black;&lt;br /&gt;
	/* @noflip */&lt;br /&gt;
	margin: 0.5em 0 0.5em 1em;&lt;br /&gt;
	padding: 0.2em;&lt;br /&gt;
	/* @noflip */&lt;br /&gt;
	float: right;&lt;br /&gt;
	/* @noflip */&lt;br /&gt;
	clear: right;&lt;br /&gt;
	font-size: 88%;&lt;br /&gt;
	line-height: 1.5em;&lt;br /&gt;
	width: 22em;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
.infobox-header,&lt;br /&gt;
.infobox-label,&lt;br /&gt;
.infobox-above,&lt;br /&gt;
.infobox-full-data,&lt;br /&gt;
.infobox-data,&lt;br /&gt;
.infobox-below,&lt;br /&gt;
.infobox-subheader,&lt;br /&gt;
.infobox-image,&lt;br /&gt;
.infobox-navbar,&lt;br /&gt;
/* Remove element selector when every .infobox thing is using the standard module/templates  */&lt;br /&gt;
.infobox th,&lt;br /&gt;
.infobox td {&lt;br /&gt;
	vertical-align: top;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
.infobox-label,&lt;br /&gt;
.infobox-data,&lt;br /&gt;
/* Remove element selector when every .infobox thing is using the standard module/templates  */&lt;br /&gt;
.infobox th,&lt;br /&gt;
.infobox td {&lt;br /&gt;
	/* @noflip */&lt;br /&gt;
	text-align: left;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
/* Remove .infobox when element selectors above are removed */&lt;br /&gt;
.infobox .infobox-above,&lt;br /&gt;
.infobox .infobox-title,&lt;br /&gt;
/* Remove element selector when every .infobox thing is using the standard module/templates  */&lt;br /&gt;
.infobox caption {&lt;br /&gt;
	font-size: 125%;&lt;br /&gt;
	font-weight: bold;&lt;br /&gt;
	text-align: center;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
.infobox-title,&lt;br /&gt;
/* Remove element selector when every .infobox thing is using the standard module/templates  */&lt;br /&gt;
.infobox caption {&lt;br /&gt;
	padding: 0.2em;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
/* Remove .infobox when element selectors above are removed */&lt;br /&gt;
.infobox .infobox-header,&lt;br /&gt;
.infobox .infobox-subheader,&lt;br /&gt;
.infobox .infobox-image,&lt;br /&gt;
.infobox .infobox-full-data,&lt;br /&gt;
.infobox .infobox-below {&lt;br /&gt;
	text-align: center;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
/* Remove .infobox when element selectors above are removed */&lt;br /&gt;
.infobox .infobox-navbar {&lt;br /&gt;
	/* @noflip */&lt;br /&gt;
	text-align: right;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
/* Normal font styling for wikitable row headers with scope=&amp;quot;row&amp;quot; tag */&lt;br /&gt;
.wikitable.plainrowheaders th[scope=row],&lt;br /&gt;
.wikitable.plainrowheaders th[scope=rowgroup] {&lt;br /&gt;
	font-weight: normal;&lt;br /&gt;
	/* @noflip */&lt;br /&gt;
	text-align: left;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
/* Remove underlines from certain links */&lt;br /&gt;
.nounderlines a,&lt;br /&gt;
.IPA a:link,&lt;br /&gt;
.IPA a:visited {&lt;br /&gt;
	text-decoration: none !important;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
/* Prevent line breaks in silly places where desired (nowrap)&lt;br /&gt;
   and links when we don&#039;t want them to (nowraplinks a) */&lt;br /&gt;
.nowrap,&lt;br /&gt;
.nowraplinks a {&lt;br /&gt;
	white-space: nowrap;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
/* But allow wrapping where desired: */&lt;br /&gt;
.wrap,&lt;br /&gt;
.wraplinks a {&lt;br /&gt;
	white-space: normal;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
/* texhtml class for inline math (based on generic times-serif class) */&lt;br /&gt;
span.texhtml {&lt;br /&gt;
	font-family: &amp;quot;Nimbus Roman No9 L&amp;quot;, &amp;quot;Times New Roman&amp;quot;, Times, serif;&lt;br /&gt;
	font-size: 118%;&lt;br /&gt;
	line-height: 1;&lt;br /&gt;
	white-space: nowrap;&lt;br /&gt;
	/* Force tabular and lining display for texhtml */&lt;br /&gt;
	-webkit-font-feature-settings: &amp;quot;lnum&amp;quot;, &amp;quot;tnum&amp;quot;, &amp;quot;kern&amp;quot; 0;&lt;br /&gt;
	font-feature-settings: &amp;quot;lnum&amp;quot;, &amp;quot;tnum&amp;quot;, &amp;quot;kern&amp;quot; 0;&lt;br /&gt;
	font-variant-numeric: lining-nums tabular-nums;&lt;br /&gt;
	font-kerning: none;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
span.texhtml span.texhtml {&lt;br /&gt;
	font-size: 100%;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
@media screen {&lt;br /&gt;
	.nochecker .gallerybox .thumb img {&lt;br /&gt;
		background-image: none;&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
/* Put anything you mean to be a sitewide addition above the TemplateStyles&lt;br /&gt;
 * comment above.&lt;br /&gt;
 */&lt;/div&gt;</summary>
		<author><name>Vanilla</name></author>
	</entry>
	<entry>
		<id>https://wiki.pxls.space/index.php?title=Template:Infobox_military_conflict&amp;diff=6920</id>
		<title>Template:Infobox military conflict</title>
		<link rel="alternate" type="text/html" href="https://wiki.pxls.space/index.php?title=Template:Infobox_military_conflict&amp;diff=6920"/>
		<updated>2023-03-01T00:47:39Z</updated>

		<summary type="html">&lt;p&gt;Vanilla: AAAAAAAAAA&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;includeonly&amp;gt;{{#invoke:Infobox military conflict|main}}&amp;lt;/includeonly&amp;gt;&amp;lt;noinclude&amp;gt;{{documentation}}&amp;lt;/noinclude&amp;gt;&lt;/div&gt;</summary>
		<author><name>Vanilla</name></author>
	</entry>
	<entry>
		<id>https://wiki.pxls.space/index.php?title=Module:Documentation/doc&amp;diff=6919</id>
		<title>Module:Documentation/doc</title>
		<link rel="alternate" type="text/html" href="https://wiki.pxls.space/index.php?title=Module:Documentation/doc&amp;diff=6919"/>
		<updated>2023-03-01T00:44:30Z</updated>

		<summary type="html">&lt;p&gt;Vanilla: https://en.wikipedia.org/w/index.php?title=Module:Documentation/doc&amp;amp;action=edit&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{used in system}}&lt;br /&gt;
{{Module rating|protected}}&lt;br /&gt;
{{Lua|Module:Documentation/config|Module:Arguments|Module:Message box|Module:Module wikitext|Module:Protection banner}}&lt;br /&gt;
{{Uses TemplateStyles|Module:Documentation/styles.css}}&lt;br /&gt;
This module displays a blue box containing documentation for [[Help:Template|templates]], [[Wikipedia:Lua|Lua modules]], or other pages. The {{tl|documentation}} template invokes it.&lt;br /&gt;
&lt;br /&gt;
== Normal usage ==&lt;br /&gt;
&lt;br /&gt;
For most uses, you should use the {{tl|documentation}} template; please see that template&#039;s page for its usage instructions and parameters.&lt;br /&gt;
&lt;br /&gt;
== Use in other modules ==&lt;br /&gt;
&lt;br /&gt;
To use this module from another Lua module, first load it with &amp;lt;code&amp;gt;require&amp;lt;/code&amp;gt;:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
local documentation = require(&#039;Module:Documentation&#039;).main&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Then you can simply call it using a table of arguments.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
documentation{content = &#039;Some documentation&#039;, [&#039;link box&#039;] = &#039;My custom link box&#039;}&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Please refer to the [[Template:Documentation/doc|template documentation]] for usage instructions and a list of parameters.&lt;br /&gt;
&lt;br /&gt;
== Porting to other wikis ==&lt;br /&gt;
&lt;br /&gt;
The module has a configuration file at [[Module:Documentation/config]] which is intended to allow easy translation and porting to other wikis. Please see the code comments in the config page for instructions. If you have any questions, or you need a feature which is not currently implemented, please leave a message at &amp;lt;span class=&amp;quot;plainlinks&amp;quot;&amp;gt;[https://en.wikipedia.org/wiki/Template_talk:Documentation Template talk:Documentation]&amp;lt;/span&amp;gt;&amp;lt;!-- this link uses external link syntax because it is intended to direct users from third-party wikis to the Wikipedia template talk page; in this situation, an internal link would unhelpfully just point to their local template talk page, and the existence of any given interwiki prefix cannot be assumed --&amp;gt; to get the attention of a developer.&lt;br /&gt;
&lt;br /&gt;
The messages that need to be customized to display a documentation template/module at the top of module pages are [[MediaWiki:Scribunto-doc-page-show]] and [[MediaWiki:Scribunto-doc-page-does-not-exist]].&lt;/div&gt;</summary>
		<author><name>Vanilla</name></author>
	</entry>
	<entry>
		<id>https://wiki.pxls.space/index.php?title=Module:Documentation&amp;diff=6918</id>
		<title>Module:Documentation</title>
		<link rel="alternate" type="text/html" href="https://wiki.pxls.space/index.php?title=Module:Documentation&amp;diff=6918"/>
		<updated>2023-03-01T00:43:31Z</updated>

		<summary type="html">&lt;p&gt;Vanilla: https://en.wikipedia.org/w/index.php?title=Module:Documentation&amp;amp;action=edit&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;-- This module implements {{documentation}}.&lt;br /&gt;
&lt;br /&gt;
-- Get required modules.&lt;br /&gt;
local getArgs = require(&#039;Module:Arguments&#039;).getArgs&lt;br /&gt;
&lt;br /&gt;
-- Get the config table.&lt;br /&gt;
local cfg = mw.loadData(&#039;Module:Documentation/config&#039;)&lt;br /&gt;
&lt;br /&gt;
local p = {}&lt;br /&gt;
&lt;br /&gt;
-- Often-used functions.&lt;br /&gt;
local ugsub = mw.ustring.gsub&lt;br /&gt;
&lt;br /&gt;
----------------------------------------------------------------------------&lt;br /&gt;
-- Helper functions&lt;br /&gt;
--&lt;br /&gt;
-- These are defined as local functions, but are made available in the p&lt;br /&gt;
-- table for testing purposes.&lt;br /&gt;
----------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
local function message(cfgKey, valArray, expectType)&lt;br /&gt;
	--[[&lt;br /&gt;
	-- Gets a message from the cfg table and formats it if appropriate.&lt;br /&gt;
	-- The function raises an error if the value from the cfg table is not&lt;br /&gt;
	-- of the type expectType. The default type for expectType is &#039;string&#039;.&lt;br /&gt;
	-- If the table valArray is present, strings such as $1, $2 etc. in the&lt;br /&gt;
	-- message are substituted with values from the table keys [1], [2] etc.&lt;br /&gt;
	-- For example, if the message &amp;quot;foo-message&amp;quot; had the value &#039;Foo $2 bar $1.&#039;,&lt;br /&gt;
	-- message(&#039;foo-message&#039;, {&#039;baz&#039;, &#039;qux&#039;}) would return &amp;quot;Foo qux bar baz.&amp;quot;&lt;br /&gt;
	--]]&lt;br /&gt;
	local msg = cfg[cfgKey]&lt;br /&gt;
	expectType = expectType or &#039;string&#039;&lt;br /&gt;
	if type(msg) ~= expectType then&lt;br /&gt;
		error(&#039;message: type error in message cfg.&#039; .. cfgKey .. &#039; (&#039; .. expectType .. &#039; expected, got &#039; .. type(msg) .. &#039;)&#039;, 2)&lt;br /&gt;
	end&lt;br /&gt;
	if not valArray then&lt;br /&gt;
		return msg&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local function getMessageVal(match)&lt;br /&gt;
		match = tonumber(match)&lt;br /&gt;
		return valArray[match] or error(&#039;message: no value found for key $&#039; .. match .. &#039; in message cfg.&#039; .. cfgKey, 4)&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	return ugsub(msg, &#039;$([1-9][0-9]*)&#039;, getMessageVal)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
p.message = message&lt;br /&gt;
&lt;br /&gt;
local function makeWikilink(page, display)&lt;br /&gt;
	if display then&lt;br /&gt;
		return mw.ustring.format(&#039;[[%s|%s]]&#039;, page, display)&lt;br /&gt;
	else&lt;br /&gt;
		return mw.ustring.format(&#039;[[%s]]&#039;, page)&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
p.makeWikilink = makeWikilink&lt;br /&gt;
&lt;br /&gt;
local function makeCategoryLink(cat, sort)&lt;br /&gt;
	local catns = mw.site.namespaces[14].name&lt;br /&gt;
	return makeWikilink(catns .. &#039;:&#039; .. cat, sort)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
p.makeCategoryLink = makeCategoryLink&lt;br /&gt;
&lt;br /&gt;
local function makeUrlLink(url, display)&lt;br /&gt;
	return mw.ustring.format(&#039;[%s %s]&#039;, url, display)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
p.makeUrlLink = makeUrlLink&lt;br /&gt;
&lt;br /&gt;
local function makeToolbar(...)&lt;br /&gt;
	local ret = {}&lt;br /&gt;
	local lim = select(&#039;#&#039;, ...)&lt;br /&gt;
	if lim &amp;lt; 1 then&lt;br /&gt;
		return nil&lt;br /&gt;
	end&lt;br /&gt;
	for i = 1, lim do&lt;br /&gt;
		ret[#ret + 1] = select(i, ...)&lt;br /&gt;
	end&lt;br /&gt;
	-- &#039;documentation-toolbar&#039;&lt;br /&gt;
	return &#039;&amp;lt;span class=&amp;quot;&#039; .. message(&#039;toolbar-class&#039;) .. &#039;&amp;quot;&amp;gt;(&#039;&lt;br /&gt;
		.. table.concat(ret, &#039; &amp;amp;#124; &#039;) .. &#039;)&amp;lt;/span&amp;gt;&#039;&lt;br /&gt;
end	&lt;br /&gt;
&lt;br /&gt;
p.makeToolbar = makeToolbar&lt;br /&gt;
&lt;br /&gt;
----------------------------------------------------------------------------&lt;br /&gt;
-- Argument processing&lt;br /&gt;
----------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
local function makeInvokeFunc(funcName)&lt;br /&gt;
	return function (frame)&lt;br /&gt;
		local args = getArgs(frame, {&lt;br /&gt;
			valueFunc = function (key, value)&lt;br /&gt;
				if type(value) == &#039;string&#039; then&lt;br /&gt;
					value = value:match(&#039;^%s*(.-)%s*$&#039;) -- Remove whitespace.&lt;br /&gt;
					if key == &#039;heading&#039; or value ~= &#039;&#039; then&lt;br /&gt;
						return value&lt;br /&gt;
					else&lt;br /&gt;
						return nil&lt;br /&gt;
					end&lt;br /&gt;
				else&lt;br /&gt;
					return value&lt;br /&gt;
				end&lt;br /&gt;
			end&lt;br /&gt;
		})&lt;br /&gt;
		return p[funcName](args)&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
----------------------------------------------------------------------------&lt;br /&gt;
-- Entry points&lt;br /&gt;
----------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
function p.nonexistent(frame)&lt;br /&gt;
	if mw.title.getCurrentTitle().subpageText == &#039;testcases&#039; then&lt;br /&gt;
		return frame:expandTemplate{title = &#039;module test cases notice&#039;}&lt;br /&gt;
	else&lt;br /&gt;
		return p.main(frame)&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
p.main = makeInvokeFunc(&#039;_main&#039;)&lt;br /&gt;
&lt;br /&gt;
function p._main(args)&lt;br /&gt;
	--[[&lt;br /&gt;
	-- This function defines logic flow for the module.&lt;br /&gt;
	-- @args - table of arguments passed by the user&lt;br /&gt;
	--]]&lt;br /&gt;
	local env = p.getEnvironment(args)&lt;br /&gt;
	local root = mw.html.create()&lt;br /&gt;
	root&lt;br /&gt;
		:wikitext(p._getModuleWikitext(args, env))&lt;br /&gt;
		:wikitext(p.protectionTemplate(env))&lt;br /&gt;
		:wikitext(p.sandboxNotice(args, env))&lt;br /&gt;
		:tag(&#039;div&#039;)&lt;br /&gt;
			-- &#039;documentation-container&#039;&lt;br /&gt;
			:addClass(message(&#039;container&#039;))&lt;br /&gt;
			:attr(&#039;role&#039;, &#039;complementary&#039;)&lt;br /&gt;
			:attr(&#039;aria-labelledby&#039;, args.heading ~= &#039;&#039; and &#039;documentation-heading&#039; or nil)&lt;br /&gt;
			:attr(&#039;aria-label&#039;, args.heading == &#039;&#039; and &#039;Documentation&#039; or nil)&lt;br /&gt;
			:newline()&lt;br /&gt;
			:tag(&#039;div&#039;)&lt;br /&gt;
				-- &#039;documentation&#039;&lt;br /&gt;
				:addClass(message(&#039;main-div-classes&#039;))&lt;br /&gt;
				:newline()&lt;br /&gt;
				:wikitext(p._startBox(args, env))&lt;br /&gt;
				:wikitext(p._content(args, env))&lt;br /&gt;
				:tag(&#039;div&#039;)&lt;br /&gt;
					-- &#039;documentation-clear&#039;&lt;br /&gt;
					:addClass(message(&#039;clear&#039;))&lt;br /&gt;
					:done()&lt;br /&gt;
				:newline()&lt;br /&gt;
				:done()&lt;br /&gt;
			:wikitext(p._endBox(args, env))&lt;br /&gt;
			:done()&lt;br /&gt;
		:wikitext(p.addTrackingCategories(env))&lt;br /&gt;
	-- &#039;Module:Documentation/styles.css&#039;&lt;br /&gt;
	return mw.getCurrentFrame():extensionTag (&lt;br /&gt;
		&#039;templatestyles&#039;, &#039;&#039;, {src=cfg[&#039;templatestyles&#039;]&lt;br /&gt;
	}) .. tostring(root)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
----------------------------------------------------------------------------&lt;br /&gt;
-- Environment settings&lt;br /&gt;
----------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
function p.getEnvironment(args)&lt;br /&gt;
	--[[&lt;br /&gt;
	-- Returns a table with information about the environment, including title&lt;br /&gt;
	-- objects and other namespace- or path-related data.&lt;br /&gt;
	-- @args - table of arguments passed by the user&lt;br /&gt;
	--&lt;br /&gt;
	-- Title objects include:&lt;br /&gt;
	-- env.title - the page we are making documentation for (usually the current title)&lt;br /&gt;
	-- env.templateTitle - the template (or module, file, etc.)&lt;br /&gt;
	-- env.docTitle - the /doc subpage.&lt;br /&gt;
	-- env.sandboxTitle - the /sandbox subpage.&lt;br /&gt;
	-- env.testcasesTitle - the /testcases subpage.&lt;br /&gt;
	--&lt;br /&gt;
	-- Data includes:&lt;br /&gt;
	-- env.protectionLevels - the protection levels table of the title object.&lt;br /&gt;
	-- env.subjectSpace - the number of the title&#039;s subject namespace.&lt;br /&gt;
	-- env.docSpace - the number of the namespace the title puts its documentation in.&lt;br /&gt;
	-- env.docpageBase - the text of the base page of the /doc, /sandbox and /testcases pages, with namespace.&lt;br /&gt;
	-- env.compareUrl - URL of the Special:ComparePages page comparing the sandbox with the template.&lt;br /&gt;
	-- &lt;br /&gt;
	-- All table lookups are passed through pcall so that errors are caught. If an error occurs, the value&lt;br /&gt;
	-- returned will be nil.&lt;br /&gt;
	--]]&lt;br /&gt;
	&lt;br /&gt;
	local env, envFuncs = {}, {}&lt;br /&gt;
&lt;br /&gt;
	-- Set up the metatable. If triggered we call the corresponding function in the envFuncs table. The value&lt;br /&gt;
	-- returned by that function is memoized in the env table so that we don&#039;t call any of the functions&lt;br /&gt;
	-- more than once. (Nils won&#039;t be memoized.)&lt;br /&gt;
	setmetatable(env, {&lt;br /&gt;
		__index = function (t, key)&lt;br /&gt;
			local envFunc = envFuncs[key]&lt;br /&gt;
			if envFunc then&lt;br /&gt;
				local success, val = pcall(envFunc)&lt;br /&gt;
				if success then&lt;br /&gt;
					env[key] = val -- Memoise the value.&lt;br /&gt;
					return val&lt;br /&gt;
				end&lt;br /&gt;
			end&lt;br /&gt;
			return nil&lt;br /&gt;
		end&lt;br /&gt;
	})	&lt;br /&gt;
&lt;br /&gt;
	function envFuncs.title()&lt;br /&gt;
		-- The title object for the current page, or a test page passed with args.page.&lt;br /&gt;
		local title&lt;br /&gt;
		local titleArg = args.page&lt;br /&gt;
		if titleArg then&lt;br /&gt;
			title = mw.title.new(titleArg)&lt;br /&gt;
		else&lt;br /&gt;
			title = mw.title.getCurrentTitle()&lt;br /&gt;
		end&lt;br /&gt;
		return title&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	function envFuncs.templateTitle()&lt;br /&gt;
		--[[&lt;br /&gt;
		-- The template (or module, etc.) title object.&lt;br /&gt;
		-- Messages:&lt;br /&gt;
		-- &#039;sandbox-subpage&#039; --&amp;gt; &#039;sandbox&#039;&lt;br /&gt;
		-- &#039;testcases-subpage&#039; --&amp;gt; &#039;testcases&#039;&lt;br /&gt;
		--]]&lt;br /&gt;
		local subjectSpace = env.subjectSpace&lt;br /&gt;
		local title = env.title&lt;br /&gt;
		local subpage = title.subpageText&lt;br /&gt;
		if subpage == message(&#039;sandbox-subpage&#039;) or subpage == message(&#039;testcases-subpage&#039;) then&lt;br /&gt;
			return mw.title.makeTitle(subjectSpace, title.baseText)&lt;br /&gt;
		else&lt;br /&gt;
			return mw.title.makeTitle(subjectSpace, title.text)&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	function envFuncs.docTitle()&lt;br /&gt;
		--[[&lt;br /&gt;
		-- Title object of the /doc subpage.&lt;br /&gt;
		-- Messages:&lt;br /&gt;
		-- &#039;doc-subpage&#039; --&amp;gt; &#039;doc&#039;&lt;br /&gt;
		--]]&lt;br /&gt;
		local title = env.title&lt;br /&gt;
		local docname = args[1] -- User-specified doc page.&lt;br /&gt;
		local docpage&lt;br /&gt;
		if docname then&lt;br /&gt;
			docpage = docname&lt;br /&gt;
		else&lt;br /&gt;
			docpage = env.docpageBase .. &#039;/&#039; .. message(&#039;doc-subpage&#039;)&lt;br /&gt;
		end&lt;br /&gt;
		return mw.title.new(docpage)&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	function envFuncs.sandboxTitle()&lt;br /&gt;
		--[[&lt;br /&gt;
		-- Title object for the /sandbox subpage.&lt;br /&gt;
		-- Messages:&lt;br /&gt;
		-- &#039;sandbox-subpage&#039; --&amp;gt; &#039;sandbox&#039;&lt;br /&gt;
		--]]&lt;br /&gt;
		return mw.title.new(env.docpageBase .. &#039;/&#039; .. message(&#039;sandbox-subpage&#039;))&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	function envFuncs.testcasesTitle()&lt;br /&gt;
		--[[&lt;br /&gt;
		-- Title object for the /testcases subpage.&lt;br /&gt;
		-- Messages:&lt;br /&gt;
		-- &#039;testcases-subpage&#039; --&amp;gt; &#039;testcases&#039;&lt;br /&gt;
		--]]&lt;br /&gt;
		return mw.title.new(env.docpageBase .. &#039;/&#039; .. message(&#039;testcases-subpage&#039;))&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	function envFuncs.protectionLevels()&lt;br /&gt;
		-- The protection levels table of the title object.&lt;br /&gt;
		return env.title.protectionLevels&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	function envFuncs.subjectSpace()&lt;br /&gt;
		-- The subject namespace number.&lt;br /&gt;
		return mw.site.namespaces[env.title.namespace].subject.id&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	function envFuncs.docSpace()&lt;br /&gt;
		-- The documentation namespace number. For most namespaces this is the&lt;br /&gt;
		-- same as the subject namespace. However, pages in the Article, File,&lt;br /&gt;
		-- MediaWiki or Category namespaces must have their /doc, /sandbox and&lt;br /&gt;
		-- /testcases pages in talk space.&lt;br /&gt;
		local subjectSpace = env.subjectSpace&lt;br /&gt;
		if subjectSpace == 0 or subjectSpace == 6 or subjectSpace == 8 or subjectSpace == 14 then&lt;br /&gt;
			return subjectSpace + 1&lt;br /&gt;
		else&lt;br /&gt;
			return subjectSpace&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	function envFuncs.docpageBase()&lt;br /&gt;
		-- The base page of the /doc, /sandbox, and /testcases subpages.&lt;br /&gt;
		-- For some namespaces this is the talk page, rather than the template page.&lt;br /&gt;
		local templateTitle = env.templateTitle&lt;br /&gt;
		local docSpace = env.docSpace&lt;br /&gt;
		local docSpaceText = mw.site.namespaces[docSpace].name&lt;br /&gt;
		-- Assemble the link. docSpace is never the main namespace, so we can hardcode the colon.&lt;br /&gt;
		return docSpaceText .. &#039;:&#039; .. templateTitle.text&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	function envFuncs.compareUrl()&lt;br /&gt;
		-- Diff link between the sandbox and the main template using [[Special:ComparePages]].&lt;br /&gt;
		local templateTitle = env.templateTitle&lt;br /&gt;
		local sandboxTitle = env.sandboxTitle&lt;br /&gt;
		if templateTitle.exists and sandboxTitle.exists then&lt;br /&gt;
			local compareUrl = mw.uri.fullUrl(&lt;br /&gt;
				&#039;Special:ComparePages&#039;,&lt;br /&gt;
				{ page1 = templateTitle.prefixedText, page2 = sandboxTitle.prefixedText}&lt;br /&gt;
			)&lt;br /&gt;
			return tostring(compareUrl)&lt;br /&gt;
		else&lt;br /&gt;
			return nil&lt;br /&gt;
		end&lt;br /&gt;
	end		&lt;br /&gt;
&lt;br /&gt;
	return env&lt;br /&gt;
end	&lt;br /&gt;
&lt;br /&gt;
----------------------------------------------------------------------------&lt;br /&gt;
-- Auxiliary templates&lt;br /&gt;
----------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
p.getModuleWikitext = makeInvokeFunc(&#039;_getModuleWikitext&#039;)&lt;br /&gt;
&lt;br /&gt;
function p._getModuleWikitext(args, env)&lt;br /&gt;
	local currentTitle = mw.title.getCurrentTitle()&lt;br /&gt;
	if currentTitle.contentModel ~= &#039;Scribunto&#039; then return end&lt;br /&gt;
	pcall(require, currentTitle.prefixedText) -- if it fails, we don&#039;t care&lt;br /&gt;
	local moduleWikitext =  package.loaded[&amp;quot;Module:Module wikitext&amp;quot;]&lt;br /&gt;
	if moduleWikitext then&lt;br /&gt;
		return moduleWikitext.main()&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function p.sandboxNotice(args, env)&lt;br /&gt;
	--[=[&lt;br /&gt;
	-- Generates a sandbox notice for display above sandbox pages.&lt;br /&gt;
	-- @args - a table of arguments passed by the user&lt;br /&gt;
	-- @env - environment table containing title objects, etc., generated with p.getEnvironment&lt;br /&gt;
	-- &lt;br /&gt;
	-- Messages:&lt;br /&gt;
	-- &#039;sandbox-notice-image&#039; --&amp;gt; &#039;[[File:Sandbox.svg|50px|alt=|link=]]&#039;&lt;br /&gt;
	-- &#039;sandbox-notice-blurb&#039; --&amp;gt; &#039;This is the $1 for $2.&#039;&lt;br /&gt;
	-- &#039;sandbox-notice-diff-blurb&#039; --&amp;gt; &#039;This is the $1 for $2 ($3).&#039;&lt;br /&gt;
	-- &#039;sandbox-notice-pagetype-template&#039; --&amp;gt; &#039;[[Wikipedia:Template test cases|template sandbox]] page&#039;&lt;br /&gt;
	-- &#039;sandbox-notice-pagetype-module&#039; --&amp;gt; &#039;[[Wikipedia:Template test cases|module sandbox]] page&#039;&lt;br /&gt;
	-- &#039;sandbox-notice-pagetype-other&#039; --&amp;gt; &#039;sandbox page&#039;&lt;br /&gt;
	-- &#039;sandbox-notice-compare-link-display&#039; --&amp;gt; &#039;diff&#039;&lt;br /&gt;
	-- &#039;sandbox-notice-testcases-blurb&#039; --&amp;gt; &#039;See also the companion subpage for $1.&#039;&lt;br /&gt;
	-- &#039;sandbox-notice-testcases-link-display&#039; --&amp;gt; &#039;test cases&#039;&lt;br /&gt;
	-- &#039;sandbox-category&#039; --&amp;gt; &#039;Template sandboxes&#039;&lt;br /&gt;
	--]=]&lt;br /&gt;
	local title = env.title&lt;br /&gt;
	local sandboxTitle = env.sandboxTitle&lt;br /&gt;
	local templateTitle = env.templateTitle&lt;br /&gt;
	local subjectSpace = env.subjectSpace&lt;br /&gt;
	if not (subjectSpace and title and sandboxTitle and templateTitle&lt;br /&gt;
		and mw.title.equals(title, sandboxTitle)) then&lt;br /&gt;
		return nil&lt;br /&gt;
	end&lt;br /&gt;
	-- Build the table of arguments to pass to {{ombox}}. We need just two fields, &amp;quot;image&amp;quot; and &amp;quot;text&amp;quot;.&lt;br /&gt;
	local omargs = {}&lt;br /&gt;
	omargs.image = message(&#039;sandbox-notice-image&#039;)&lt;br /&gt;
	-- Get the text. We start with the opening blurb, which is something like&lt;br /&gt;
	-- &amp;quot;This is the template sandbox for [[Template:Foo]] (diff).&amp;quot;&lt;br /&gt;
	local text = &#039;&#039;&lt;br /&gt;
	local pagetype&lt;br /&gt;
	if subjectSpace == 10 then&lt;br /&gt;
		pagetype = message(&#039;sandbox-notice-pagetype-template&#039;)&lt;br /&gt;
	elseif subjectSpace == 828 then&lt;br /&gt;
		pagetype = message(&#039;sandbox-notice-pagetype-module&#039;)&lt;br /&gt;
	else&lt;br /&gt;
		pagetype = message(&#039;sandbox-notice-pagetype-other&#039;)&lt;br /&gt;
	end&lt;br /&gt;
	local templateLink = makeWikilink(templateTitle.prefixedText)&lt;br /&gt;
	local compareUrl = env.compareUrl&lt;br /&gt;
	if compareUrl then&lt;br /&gt;
		local compareDisplay = message(&#039;sandbox-notice-compare-link-display&#039;)&lt;br /&gt;
		local compareLink = makeUrlLink(compareUrl, compareDisplay)&lt;br /&gt;
		text = text .. message(&#039;sandbox-notice-diff-blurb&#039;, {pagetype, templateLink, compareLink})&lt;br /&gt;
	else&lt;br /&gt;
		text = text .. message(&#039;sandbox-notice-blurb&#039;, {pagetype, templateLink})&lt;br /&gt;
	end&lt;br /&gt;
	-- Get the test cases page blurb if the page exists. This is something like&lt;br /&gt;
	-- &amp;quot;See also the companion subpage for [[Template:Foo/testcases|test cases]].&amp;quot;&lt;br /&gt;
	local testcasesTitle = env.testcasesTitle&lt;br /&gt;
	if testcasesTitle and testcasesTitle.exists then&lt;br /&gt;
		if testcasesTitle.contentModel == &amp;quot;Scribunto&amp;quot; then&lt;br /&gt;
			local testcasesLinkDisplay = message(&#039;sandbox-notice-testcases-link-display&#039;)&lt;br /&gt;
			local testcasesRunLinkDisplay = message(&#039;sandbox-notice-testcases-run-link-display&#039;)&lt;br /&gt;
			local testcasesLink = makeWikilink(testcasesTitle.prefixedText, testcasesLinkDisplay)&lt;br /&gt;
			local testcasesRunLink = makeWikilink(testcasesTitle.talkPageTitle.prefixedText, testcasesRunLinkDisplay)&lt;br /&gt;
			text = text .. &#039;&amp;lt;br /&amp;gt;&#039; .. message(&#039;sandbox-notice-testcases-run-blurb&#039;, {testcasesLink, testcasesRunLink})&lt;br /&gt;
		else&lt;br /&gt;
			local testcasesLinkDisplay = message(&#039;sandbox-notice-testcases-link-display&#039;)&lt;br /&gt;
			local testcasesLink = makeWikilink(testcasesTitle.prefixedText, testcasesLinkDisplay)&lt;br /&gt;
			text = text .. &#039;&amp;lt;br /&amp;gt;&#039; .. message(&#039;sandbox-notice-testcases-blurb&#039;, {testcasesLink})&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	-- Add the sandbox to the sandbox category.&lt;br /&gt;
	omargs.text = text .. makeCategoryLink(message(&#039;sandbox-category&#039;))&lt;br /&gt;
&lt;br /&gt;
	-- &#039;documentation-clear&#039;&lt;br /&gt;
	return &#039;&amp;lt;div class=&amp;quot;&#039; .. message(&#039;clear&#039;) .. &#039;&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&#039;&lt;br /&gt;
		.. require(&#039;Module:Message box&#039;).main(&#039;ombox&#039;, omargs)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function p.protectionTemplate(env)&lt;br /&gt;
	-- Generates the padlock icon in the top right.&lt;br /&gt;
	-- @env - environment table containing title objects, etc., generated with p.getEnvironment&lt;br /&gt;
	-- Messages:&lt;br /&gt;
	-- &#039;protection-template&#039; --&amp;gt; &#039;pp-template&#039;&lt;br /&gt;
	-- &#039;protection-template-args&#039; --&amp;gt; {docusage = &#039;yes&#039;}&lt;br /&gt;
	local protectionLevels = env.protectionLevels&lt;br /&gt;
	if not protectionLevels then&lt;br /&gt;
		return nil&lt;br /&gt;
	end&lt;br /&gt;
	local editProt = protectionLevels.edit and protectionLevels.edit[1]&lt;br /&gt;
	local moveProt = protectionLevels.move and protectionLevels.move[1]&lt;br /&gt;
	if editProt then&lt;br /&gt;
		-- The page is edit-protected.&lt;br /&gt;
		return require(&#039;Module:Protection banner&#039;)._main{&lt;br /&gt;
			message(&#039;protection-reason-edit&#039;), small = true&lt;br /&gt;
		}&lt;br /&gt;
	elseif moveProt and moveProt ~= &#039;autoconfirmed&#039; then&lt;br /&gt;
		-- The page is move-protected but not edit-protected. Exclude move&lt;br /&gt;
		-- protection with the level &amp;quot;autoconfirmed&amp;quot;, as this is equivalent to&lt;br /&gt;
		-- no move protection at all.&lt;br /&gt;
		return require(&#039;Module:Protection banner&#039;)._main{&lt;br /&gt;
			action = &#039;move&#039;, small = true&lt;br /&gt;
		}&lt;br /&gt;
	else&lt;br /&gt;
		return nil&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
----------------------------------------------------------------------------&lt;br /&gt;
-- Start box&lt;br /&gt;
----------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
p.startBox = makeInvokeFunc(&#039;_startBox&#039;)&lt;br /&gt;
&lt;br /&gt;
function p._startBox(args, env)&lt;br /&gt;
	--[[&lt;br /&gt;
	-- This function generates the start box.&lt;br /&gt;
	-- @args - a table of arguments passed by the user&lt;br /&gt;
	-- @env - environment table containing title objects, etc., generated with p.getEnvironment&lt;br /&gt;
	-- &lt;br /&gt;
	-- The actual work is done by p.makeStartBoxLinksData and p.renderStartBoxLinks which make&lt;br /&gt;
	-- the [view] [edit] [history] [purge] links, and by p.makeStartBoxData and p.renderStartBox&lt;br /&gt;
	-- which generate the box HTML.&lt;br /&gt;
	--]]&lt;br /&gt;
	env = env or p.getEnvironment(args)&lt;br /&gt;
	local links&lt;br /&gt;
	local content = args.content&lt;br /&gt;
	if not content or args[1] then&lt;br /&gt;
		-- No need to include the links if the documentation is on the template page itself.&lt;br /&gt;
		local linksData = p.makeStartBoxLinksData(args, env)&lt;br /&gt;
		if linksData then&lt;br /&gt;
			links = p.renderStartBoxLinks(linksData)&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	-- Generate the start box html.&lt;br /&gt;
	local data = p.makeStartBoxData(args, env, links)&lt;br /&gt;
	if data then&lt;br /&gt;
		return p.renderStartBox(data)&lt;br /&gt;
	else&lt;br /&gt;
		-- User specified no heading.&lt;br /&gt;
		return nil&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function p.makeStartBoxLinksData(args, env)&lt;br /&gt;
	--[[&lt;br /&gt;
	-- Does initial processing of data to make the [view] [edit] [history] [purge] links.&lt;br /&gt;
	-- @args - a table of arguments passed by the user&lt;br /&gt;
	-- @env - environment table containing title objects, etc., generated with p.getEnvironment&lt;br /&gt;
	-- &lt;br /&gt;
	-- Messages:&lt;br /&gt;
	-- &#039;view-link-display&#039; --&amp;gt; &#039;view&#039;&lt;br /&gt;
	-- &#039;edit-link-display&#039; --&amp;gt; &#039;edit&#039;&lt;br /&gt;
	-- &#039;history-link-display&#039; --&amp;gt; &#039;history&#039;&lt;br /&gt;
	-- &#039;purge-link-display&#039; --&amp;gt; &#039;purge&#039;&lt;br /&gt;
	-- &#039;module-preload&#039; --&amp;gt; &#039;Template:Documentation/preload-module-doc&#039;&lt;br /&gt;
	-- &#039;docpage-preload&#039; --&amp;gt; &#039;Template:Documentation/preload&#039;&lt;br /&gt;
	-- &#039;create-link-display&#039; --&amp;gt; &#039;create&#039;&lt;br /&gt;
	--]]&lt;br /&gt;
	local subjectSpace = env.subjectSpace&lt;br /&gt;
	local title = env.title&lt;br /&gt;
	local docTitle = env.docTitle&lt;br /&gt;
	if not title or not docTitle then&lt;br /&gt;
		return nil&lt;br /&gt;
	end&lt;br /&gt;
	if docTitle.isRedirect then &lt;br /&gt;
		docTitle = docTitle.redirectTarget&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local data = {}&lt;br /&gt;
	data.title = title&lt;br /&gt;
	data.docTitle = docTitle&lt;br /&gt;
	-- View, display, edit, and purge links if /doc exists.&lt;br /&gt;
	data.viewLinkDisplay = message(&#039;view-link-display&#039;)&lt;br /&gt;
	data.editLinkDisplay = message(&#039;edit-link-display&#039;)&lt;br /&gt;
	data.historyLinkDisplay = message(&#039;history-link-display&#039;)&lt;br /&gt;
	data.purgeLinkDisplay = message(&#039;purge-link-display&#039;)&lt;br /&gt;
	-- Create link if /doc doesn&#039;t exist.&lt;br /&gt;
	local preload = args.preload&lt;br /&gt;
	if not preload then&lt;br /&gt;
		if subjectSpace == 828 then -- Module namespace&lt;br /&gt;
			preload = message(&#039;module-preload&#039;)&lt;br /&gt;
		else&lt;br /&gt;
			preload = message(&#039;docpage-preload&#039;)&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	data.preload = preload&lt;br /&gt;
	data.createLinkDisplay = message(&#039;create-link-display&#039;)&lt;br /&gt;
	return data&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function p.renderStartBoxLinks(data)&lt;br /&gt;
	--[[&lt;br /&gt;
	-- Generates the [view][edit][history][purge] or [create][purge] links from the data table.&lt;br /&gt;
	-- @data - a table of data generated by p.makeStartBoxLinksData&lt;br /&gt;
	--]]&lt;br /&gt;
	&lt;br /&gt;
	local function escapeBrackets(s)&lt;br /&gt;
		-- Escapes square brackets with HTML entities.&lt;br /&gt;
		s = s:gsub(&#039;%[&#039;, &#039;&amp;amp;#91;&#039;) -- Replace square brackets with HTML entities.&lt;br /&gt;
		s = s:gsub(&#039;%]&#039;, &#039;&amp;amp;#93;&#039;)&lt;br /&gt;
		return s&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local ret&lt;br /&gt;
	local docTitle = data.docTitle&lt;br /&gt;
	local title = data.title&lt;br /&gt;
	local purgeLink = makeUrlLink(title:fullUrl{action = &#039;purge&#039;}, data.purgeLinkDisplay)&lt;br /&gt;
	if docTitle.exists then&lt;br /&gt;
		local viewLink = makeWikilink(docTitle.prefixedText, data.viewLinkDisplay)&lt;br /&gt;
		local editLink = makeUrlLink(docTitle:fullUrl{action = &#039;edit&#039;}, data.editLinkDisplay)&lt;br /&gt;
		local historyLink = makeUrlLink(docTitle:fullUrl{action = &#039;history&#039;}, data.historyLinkDisplay)&lt;br /&gt;
		ret = &#039;[%s] [%s] [%s] [%s]&#039;&lt;br /&gt;
		ret = escapeBrackets(ret)&lt;br /&gt;
		ret = mw.ustring.format(ret, viewLink, editLink, historyLink, purgeLink)&lt;br /&gt;
	else&lt;br /&gt;
		local createLink = makeUrlLink(docTitle:fullUrl{action = &#039;edit&#039;, preload = data.preload}, data.createLinkDisplay)&lt;br /&gt;
		ret = &#039;[%s] [%s]&#039;&lt;br /&gt;
		ret = escapeBrackets(ret)&lt;br /&gt;
		ret = mw.ustring.format(ret, createLink, purgeLink)&lt;br /&gt;
	end&lt;br /&gt;
	return ret&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function p.makeStartBoxData(args, env, links)&lt;br /&gt;
	--[=[&lt;br /&gt;
	-- Does initial processing of data to pass to the start-box render function, p.renderStartBox.&lt;br /&gt;
	-- @args - a table of arguments passed by the user&lt;br /&gt;
	-- @env - environment table containing title objects, etc., generated with p.getEnvironment&lt;br /&gt;
	-- @links - a string containing the [view][edit][history][purge] links - could be nil if there&#039;s an error.&lt;br /&gt;
	--&lt;br /&gt;
	-- Messages:&lt;br /&gt;
	-- &#039;documentation-icon-wikitext&#039; --&amp;gt; &#039;[[File:Test Template Info-Icon - Version (2).svg|50px|link=|alt=]]&#039;&lt;br /&gt;
	-- &#039;template-namespace-heading&#039; --&amp;gt; &#039;Template documentation&#039;&lt;br /&gt;
	-- &#039;module-namespace-heading&#039; --&amp;gt; &#039;Module documentation&#039;&lt;br /&gt;
	-- &#039;file-namespace-heading&#039; --&amp;gt; &#039;Summary&#039;&lt;br /&gt;
	-- &#039;other-namespaces-heading&#039; --&amp;gt; &#039;Documentation&#039;&lt;br /&gt;
	-- &#039;testcases-create-link-display&#039; --&amp;gt; &#039;create&#039;&lt;br /&gt;
	--]=]&lt;br /&gt;
	local subjectSpace = env.subjectSpace&lt;br /&gt;
	if not subjectSpace then&lt;br /&gt;
		-- Default to an &amp;quot;other namespaces&amp;quot; namespace, so that we get at least some output&lt;br /&gt;
		-- if an error occurs.&lt;br /&gt;
		subjectSpace = 2&lt;br /&gt;
	end&lt;br /&gt;
	local data = {}&lt;br /&gt;
	&lt;br /&gt;
	-- Heading&lt;br /&gt;
	local heading = args.heading -- Blank values are not removed.&lt;br /&gt;
	if heading == &#039;&#039; then&lt;br /&gt;
		-- Don&#039;t display the start box if the heading arg is defined but blank.&lt;br /&gt;
		return nil&lt;br /&gt;
	end&lt;br /&gt;
	if heading then&lt;br /&gt;
		data.heading = heading&lt;br /&gt;
	elseif subjectSpace == 10 then -- Template namespace&lt;br /&gt;
		data.heading = message(&#039;documentation-icon-wikitext&#039;) .. &#039; &#039; .. message(&#039;template-namespace-heading&#039;)&lt;br /&gt;
	elseif subjectSpace == 828 then -- Module namespace&lt;br /&gt;
		data.heading = message(&#039;documentation-icon-wikitext&#039;) .. &#039; &#039; .. message(&#039;module-namespace-heading&#039;)&lt;br /&gt;
	elseif subjectSpace == 6 then -- File namespace&lt;br /&gt;
		data.heading = message(&#039;file-namespace-heading&#039;)&lt;br /&gt;
	else&lt;br /&gt;
		data.heading = message(&#039;other-namespaces-heading&#039;)&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	-- Heading CSS&lt;br /&gt;
	local headingStyle = args[&#039;heading-style&#039;]&lt;br /&gt;
	if headingStyle then&lt;br /&gt;
		data.headingStyleText = headingStyle&lt;br /&gt;
	else&lt;br /&gt;
		-- &#039;documentation-heading&#039;&lt;br /&gt;
		data.headingClass = message(&#039;main-div-heading-class&#039;)&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	-- Data for the [view][edit][history][purge] or [create] links.&lt;br /&gt;
	if links then&lt;br /&gt;
		-- &#039;mw-editsection-like plainlinks&#039;&lt;br /&gt;
		data.linksClass = message(&#039;start-box-link-classes&#039;)&lt;br /&gt;
		data.links = links&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	return data&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function p.renderStartBox(data)&lt;br /&gt;
	-- Renders the start box html.&lt;br /&gt;
	-- @data - a table of data generated by p.makeStartBoxData.&lt;br /&gt;
	local sbox = mw.html.create(&#039;div&#039;)&lt;br /&gt;
	sbox&lt;br /&gt;
		-- &#039;documentation-startbox&#039;&lt;br /&gt;
		:addClass(message(&#039;start-box-class&#039;))&lt;br /&gt;
		:newline()&lt;br /&gt;
		:tag(&#039;span&#039;)&lt;br /&gt;
			:addClass(data.headingClass)&lt;br /&gt;
			:attr(&#039;id&#039;, &#039;documentation-heading&#039;)&lt;br /&gt;
			:cssText(data.headingStyleText)&lt;br /&gt;
			:wikitext(data.heading)&lt;br /&gt;
	local links = data.links&lt;br /&gt;
	if links then&lt;br /&gt;
		sbox:tag(&#039;span&#039;)&lt;br /&gt;
			:addClass(data.linksClass)&lt;br /&gt;
			:attr(&#039;id&#039;, data.linksId)&lt;br /&gt;
			:wikitext(links)&lt;br /&gt;
	end&lt;br /&gt;
	return tostring(sbox)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
----------------------------------------------------------------------------&lt;br /&gt;
-- Documentation content&lt;br /&gt;
----------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
p.content = makeInvokeFunc(&#039;_content&#039;)&lt;br /&gt;
&lt;br /&gt;
function p._content(args, env)&lt;br /&gt;
	-- Displays the documentation contents&lt;br /&gt;
	-- @args - a table of arguments passed by the user&lt;br /&gt;
	-- @env - environment table containing title objects, etc., generated with p.getEnvironment&lt;br /&gt;
	env = env or p.getEnvironment(args)&lt;br /&gt;
	local docTitle = env.docTitle&lt;br /&gt;
	local content = args.content&lt;br /&gt;
	if not content and docTitle and docTitle.exists then&lt;br /&gt;
		content = args._content or mw.getCurrentFrame():expandTemplate{title = docTitle.prefixedText}&lt;br /&gt;
	end&lt;br /&gt;
	-- The line breaks below are necessary so that &amp;quot;=== Headings ===&amp;quot; at the start and end&lt;br /&gt;
	-- of docs are interpreted correctly.&lt;br /&gt;
	return &#039;\n&#039; .. (content or &#039;&#039;) .. &#039;\n&#039; &lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
p.contentTitle = makeInvokeFunc(&#039;_contentTitle&#039;)&lt;br /&gt;
&lt;br /&gt;
function p._contentTitle(args, env)&lt;br /&gt;
	env = env or p.getEnvironment(args)&lt;br /&gt;
	local docTitle = env.docTitle&lt;br /&gt;
	if not args.content and docTitle and docTitle.exists then&lt;br /&gt;
		return docTitle.prefixedText&lt;br /&gt;
	else&lt;br /&gt;
		return &#039;&#039;&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
----------------------------------------------------------------------------&lt;br /&gt;
-- End box&lt;br /&gt;
----------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
p.endBox = makeInvokeFunc(&#039;_endBox&#039;)&lt;br /&gt;
&lt;br /&gt;
function p._endBox(args, env)&lt;br /&gt;
	--[=[&lt;br /&gt;
	-- This function generates the end box (also known as the link box).&lt;br /&gt;
	-- @args - a table of arguments passed by the user&lt;br /&gt;
	-- @env - environment table containing title objects, etc., generated with p.getEnvironment&lt;br /&gt;
	-- &lt;br /&gt;
	--]=]&lt;br /&gt;
	&lt;br /&gt;
	-- Get environment data.&lt;br /&gt;
	env = env or p.getEnvironment(args)&lt;br /&gt;
	local subjectSpace = env.subjectSpace&lt;br /&gt;
	local docTitle = env.docTitle&lt;br /&gt;
	if not subjectSpace or not docTitle then&lt;br /&gt;
		return nil&lt;br /&gt;
	end&lt;br /&gt;
		&lt;br /&gt;
	-- Check whether we should output the end box at all. Add the end&lt;br /&gt;
	-- box by default if the documentation exists or if we are in the&lt;br /&gt;
	-- user, module or template namespaces.&lt;br /&gt;
	local linkBox = args[&#039;link box&#039;]&lt;br /&gt;
	if linkBox == &#039;off&#039;&lt;br /&gt;
		or not (&lt;br /&gt;
			docTitle.exists&lt;br /&gt;
			or subjectSpace == 2&lt;br /&gt;
			or subjectSpace == 828&lt;br /&gt;
			or subjectSpace == 10&lt;br /&gt;
		)&lt;br /&gt;
	then&lt;br /&gt;
		return nil&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- Assemble the link box.&lt;br /&gt;
	local text = &#039;&#039;&lt;br /&gt;
	if linkBox then&lt;br /&gt;
		text = text .. linkBox&lt;br /&gt;
	else&lt;br /&gt;
		text = text .. (p.makeDocPageBlurb(args, env) or &#039;&#039;) -- &amp;quot;This documentation is transcluded from [[Foo]].&amp;quot; &lt;br /&gt;
		if subjectSpace == 2 or subjectSpace == 10 or subjectSpace == 828 then&lt;br /&gt;
			-- We are in the user, template or module namespaces.&lt;br /&gt;
			-- Add sandbox and testcases links.&lt;br /&gt;
			-- &amp;quot;Editors can experiment in this template&#039;s sandbox and testcases pages.&amp;quot;&lt;br /&gt;
			text = text .. (p.makeExperimentBlurb(args, env) or &#039;&#039;) .. &#039;&amp;lt;br /&amp;gt;&#039;&lt;br /&gt;
			if not args.content and not args[1] then&lt;br /&gt;
				-- &amp;quot;Please add categories to the /doc subpage.&amp;quot;&lt;br /&gt;
				-- Don&#039;t show this message with inline docs or with an explicitly specified doc page,&lt;br /&gt;
				-- as then it is unclear where to add the categories.&lt;br /&gt;
				text = text .. (p.makeCategoriesBlurb(args, env) or &#039;&#039;)&lt;br /&gt;
			end&lt;br /&gt;
			text = text .. &#039; &#039; .. (p.makeSubpagesBlurb(args, env) or &#039;&#039;) --&amp;quot;Subpages of this template&amp;quot;&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	local box = mw.html.create(&#039;div&#039;)&lt;br /&gt;
	-- &#039;documentation-metadata&#039;&lt;br /&gt;
	box:attr(&#039;role&#039;, &#039;note&#039;)&lt;br /&gt;
		:addClass(message(&#039;end-box-class&#039;))&lt;br /&gt;
		-- &#039;plainlinks&#039;&lt;br /&gt;
		:addClass(message(&#039;end-box-plainlinks&#039;))&lt;br /&gt;
		:wikitext(text)&lt;br /&gt;
		:done()&lt;br /&gt;
&lt;br /&gt;
	return &#039;\n&#039; .. tostring(box)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function p.makeDocPageBlurb(args, env)&lt;br /&gt;
	--[=[&lt;br /&gt;
	-- Makes the blurb &amp;quot;This documentation is transcluded from [[Template:Foo]] (edit, history)&amp;quot;.&lt;br /&gt;
	-- @args - a table of arguments passed by the user&lt;br /&gt;
	-- @env - environment table containing title objects, etc., generated with p.getEnvironment&lt;br /&gt;
	-- &lt;br /&gt;
	-- Messages:&lt;br /&gt;
	-- &#039;edit-link-display&#039; --&amp;gt; &#039;edit&#039;&lt;br /&gt;
	-- &#039;history-link-display&#039; --&amp;gt; &#039;history&#039;&lt;br /&gt;
	-- &#039;transcluded-from-blurb&#039; --&amp;gt; &lt;br /&gt;
	-- &#039;The above [[Wikipedia:Template documentation|documentation]] &lt;br /&gt;
	-- is [[Help:Transclusion|transcluded]] from $1.&#039;&lt;br /&gt;
	-- &#039;module-preload&#039; --&amp;gt; &#039;Template:Documentation/preload-module-doc&#039;&lt;br /&gt;
	-- &#039;create-link-display&#039; --&amp;gt; &#039;create&#039;&lt;br /&gt;
	-- &#039;create-module-doc-blurb&#039; --&amp;gt;&lt;br /&gt;
	-- &#039;You might want to $1 a documentation page for this [[Wikipedia:Lua|Scribunto module]].&#039;&lt;br /&gt;
	--]=]&lt;br /&gt;
	local docTitle = env.docTitle&lt;br /&gt;
	if not docTitle then&lt;br /&gt;
		return nil&lt;br /&gt;
	end&lt;br /&gt;
	local ret&lt;br /&gt;
	if docTitle.exists then&lt;br /&gt;
		-- /doc exists; link to it.&lt;br /&gt;
		local docLink = makeWikilink(docTitle.prefixedText)&lt;br /&gt;
		local editUrl = docTitle:fullUrl{action = &#039;edit&#039;}&lt;br /&gt;
		local editDisplay = message(&#039;edit-link-display&#039;)&lt;br /&gt;
		local editLink = makeUrlLink(editUrl, editDisplay)&lt;br /&gt;
		local historyUrl = docTitle:fullUrl{action = &#039;history&#039;}&lt;br /&gt;
		local historyDisplay = message(&#039;history-link-display&#039;)&lt;br /&gt;
		local historyLink = makeUrlLink(historyUrl, historyDisplay)&lt;br /&gt;
		ret = message(&#039;transcluded-from-blurb&#039;, {docLink})&lt;br /&gt;
			.. &#039; &#039;&lt;br /&gt;
			.. makeToolbar(editLink, historyLink)&lt;br /&gt;
			.. &#039;&amp;lt;br /&amp;gt;&#039;&lt;br /&gt;
	elseif env.subjectSpace == 828 then&lt;br /&gt;
		-- /doc does not exist; ask to create it.&lt;br /&gt;
		local createUrl = docTitle:fullUrl{action = &#039;edit&#039;, preload = message(&#039;module-preload&#039;)}&lt;br /&gt;
		local createDisplay = message(&#039;create-link-display&#039;)&lt;br /&gt;
		local createLink = makeUrlLink(createUrl, createDisplay)&lt;br /&gt;
		ret = message(&#039;create-module-doc-blurb&#039;, {createLink})&lt;br /&gt;
			.. &#039;&amp;lt;br /&amp;gt;&#039;&lt;br /&gt;
	end&lt;br /&gt;
	return ret&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function p.makeExperimentBlurb(args, env)&lt;br /&gt;
	--[[&lt;br /&gt;
	-- Renders the text &amp;quot;Editors can experiment in this template&#039;s sandbox (edit | diff) and testcases (edit) pages.&amp;quot;&lt;br /&gt;
	-- @args - a table of arguments passed by the user&lt;br /&gt;
	-- @env - environment table containing title objects, etc., generated with p.getEnvironment&lt;br /&gt;
	-- &lt;br /&gt;
	-- Messages:&lt;br /&gt;
	-- &#039;sandbox-link-display&#039; --&amp;gt; &#039;sandbox&#039;&lt;br /&gt;
	-- &#039;sandbox-edit-link-display&#039; --&amp;gt; &#039;edit&#039;&lt;br /&gt;
	-- &#039;compare-link-display&#039; --&amp;gt; &#039;diff&#039;&lt;br /&gt;
	-- &#039;module-sandbox-preload&#039; --&amp;gt; &#039;Template:Documentation/preload-module-sandbox&#039;&lt;br /&gt;
	-- &#039;template-sandbox-preload&#039; --&amp;gt; &#039;Template:Documentation/preload-sandbox&#039;&lt;br /&gt;
	-- &#039;sandbox-create-link-display&#039; --&amp;gt; &#039;create&#039;&lt;br /&gt;
	-- &#039;mirror-edit-summary&#039; --&amp;gt; &#039;Create sandbox version of $1&#039;&lt;br /&gt;
	-- &#039;mirror-link-display&#039; --&amp;gt; &#039;mirror&#039;&lt;br /&gt;
	-- &#039;mirror-link-preload&#039; --&amp;gt; &#039;Template:Documentation/mirror&#039;&lt;br /&gt;
	-- &#039;sandbox-link-display&#039; --&amp;gt; &#039;sandbox&#039;&lt;br /&gt;
	-- &#039;testcases-link-display&#039; --&amp;gt; &#039;testcases&#039;&lt;br /&gt;
	-- &#039;testcases-edit-link-display&#039;--&amp;gt; &#039;edit&#039;&lt;br /&gt;
	-- &#039;template-sandbox-preload&#039; --&amp;gt; &#039;Template:Documentation/preload-sandbox&#039;&lt;br /&gt;
	-- &#039;testcases-create-link-display&#039; --&amp;gt; &#039;create&#039;&lt;br /&gt;
	-- &#039;testcases-link-display&#039; --&amp;gt; &#039;testcases&#039;&lt;br /&gt;
	-- &#039;testcases-edit-link-display&#039; --&amp;gt; &#039;edit&#039;&lt;br /&gt;
	-- &#039;module-testcases-preload&#039; --&amp;gt; &#039;Template:Documentation/preload-module-testcases&#039;&lt;br /&gt;
	-- &#039;template-testcases-preload&#039; --&amp;gt; &#039;Template:Documentation/preload-testcases&#039;&lt;br /&gt;
	-- &#039;experiment-blurb-module&#039; --&amp;gt; &#039;Editors can experiment in this module&#039;s $1 and $2 pages.&#039;&lt;br /&gt;
	-- &#039;experiment-blurb-template&#039; --&amp;gt; &#039;Editors can experiment in this template&#039;s $1 and $2 pages.&#039;&lt;br /&gt;
	--]]&lt;br /&gt;
	local subjectSpace = env.subjectSpace&lt;br /&gt;
	local templateTitle = env.templateTitle&lt;br /&gt;
	local sandboxTitle = env.sandboxTitle&lt;br /&gt;
	local testcasesTitle = env.testcasesTitle&lt;br /&gt;
	local templatePage = templateTitle.prefixedText&lt;br /&gt;
	if not subjectSpace or not templateTitle or not sandboxTitle or not testcasesTitle then&lt;br /&gt;
		return nil&lt;br /&gt;
	end&lt;br /&gt;
	-- Make links.&lt;br /&gt;
	local sandboxLinks, testcasesLinks&lt;br /&gt;
	if sandboxTitle.exists then&lt;br /&gt;
		local sandboxPage = sandboxTitle.prefixedText&lt;br /&gt;
		local sandboxDisplay = message(&#039;sandbox-link-display&#039;)&lt;br /&gt;
		local sandboxLink = makeWikilink(sandboxPage, sandboxDisplay)&lt;br /&gt;
		local sandboxEditUrl = sandboxTitle:fullUrl{action = &#039;edit&#039;}&lt;br /&gt;
		local sandboxEditDisplay = message(&#039;sandbox-edit-link-display&#039;)&lt;br /&gt;
		local sandboxEditLink = makeUrlLink(sandboxEditUrl, sandboxEditDisplay)&lt;br /&gt;
		local compareUrl = env.compareUrl&lt;br /&gt;
		local compareLink&lt;br /&gt;
		if compareUrl then&lt;br /&gt;
			local compareDisplay = message(&#039;compare-link-display&#039;)&lt;br /&gt;
			compareLink = makeUrlLink(compareUrl, compareDisplay)&lt;br /&gt;
		end&lt;br /&gt;
		sandboxLinks = sandboxLink .. &#039; &#039; .. makeToolbar(sandboxEditLink, compareLink)&lt;br /&gt;
	else&lt;br /&gt;
		local sandboxPreload&lt;br /&gt;
		if subjectSpace == 828 then&lt;br /&gt;
			sandboxPreload = message(&#039;module-sandbox-preload&#039;)&lt;br /&gt;
		else&lt;br /&gt;
			sandboxPreload = message(&#039;template-sandbox-preload&#039;)&lt;br /&gt;
		end&lt;br /&gt;
		local sandboxCreateUrl = sandboxTitle:fullUrl{action = &#039;edit&#039;, preload = sandboxPreload}&lt;br /&gt;
		local sandboxCreateDisplay = message(&#039;sandbox-create-link-display&#039;)&lt;br /&gt;
		local sandboxCreateLink = makeUrlLink(sandboxCreateUrl, sandboxCreateDisplay)&lt;br /&gt;
		local mirrorSummary = message(&#039;mirror-edit-summary&#039;, {makeWikilink(templatePage)})&lt;br /&gt;
		local mirrorPreload = message(&#039;mirror-link-preload&#039;)&lt;br /&gt;
		local mirrorUrl = sandboxTitle:fullUrl{action = &#039;edit&#039;, preload = mirrorPreload, summary = mirrorSummary}&lt;br /&gt;
		if subjectSpace == 828 then&lt;br /&gt;
			mirrorUrl = sandboxTitle:fullUrl{action = &#039;edit&#039;, preload = templateTitle.prefixedText, summary = mirrorSummary}&lt;br /&gt;
		end&lt;br /&gt;
		local mirrorDisplay = message(&#039;mirror-link-display&#039;)&lt;br /&gt;
		local mirrorLink = makeUrlLink(mirrorUrl, mirrorDisplay)&lt;br /&gt;
		sandboxLinks = message(&#039;sandbox-link-display&#039;) .. &#039; &#039; .. makeToolbar(sandboxCreateLink, mirrorLink)&lt;br /&gt;
	end&lt;br /&gt;
	if testcasesTitle.exists then&lt;br /&gt;
		local testcasesPage = testcasesTitle.prefixedText&lt;br /&gt;
		local testcasesDisplay = message(&#039;testcases-link-display&#039;)&lt;br /&gt;
		local testcasesLink = makeWikilink(testcasesPage, testcasesDisplay)&lt;br /&gt;
		local testcasesEditUrl = testcasesTitle:fullUrl{action = &#039;edit&#039;}&lt;br /&gt;
		local testcasesEditDisplay = message(&#039;testcases-edit-link-display&#039;)&lt;br /&gt;
		local testcasesEditLink = makeUrlLink(testcasesEditUrl, testcasesEditDisplay)&lt;br /&gt;
		-- for Modules, add testcases run link if exists&lt;br /&gt;
		if testcasesTitle.contentModel == &amp;quot;Scribunto&amp;quot;  and testcasesTitle.talkPageTitle and testcasesTitle.talkPageTitle.exists then&lt;br /&gt;
			local testcasesRunLinkDisplay = message(&#039;testcases-run-link-display&#039;)&lt;br /&gt;
			local testcasesRunLink = makeWikilink(testcasesTitle.talkPageTitle.prefixedText, testcasesRunLinkDisplay)&lt;br /&gt;
			testcasesLinks = testcasesLink .. &#039; &#039; .. makeToolbar(testcasesEditLink, testcasesRunLink)&lt;br /&gt;
		else&lt;br /&gt;
			testcasesLinks = testcasesLink .. &#039; &#039; .. makeToolbar(testcasesEditLink)&lt;br /&gt;
		end&lt;br /&gt;
	else&lt;br /&gt;
		local testcasesPreload&lt;br /&gt;
		if subjectSpace == 828 then&lt;br /&gt;
			testcasesPreload = message(&#039;module-testcases-preload&#039;)&lt;br /&gt;
		else&lt;br /&gt;
			testcasesPreload = message(&#039;template-testcases-preload&#039;)&lt;br /&gt;
		end&lt;br /&gt;
		local testcasesCreateUrl = testcasesTitle:fullUrl{action = &#039;edit&#039;, preload = testcasesPreload}&lt;br /&gt;
		local testcasesCreateDisplay = message(&#039;testcases-create-link-display&#039;)&lt;br /&gt;
		local testcasesCreateLink = makeUrlLink(testcasesCreateUrl, testcasesCreateDisplay)&lt;br /&gt;
		testcasesLinks = message(&#039;testcases-link-display&#039;) .. &#039; &#039; .. makeToolbar(testcasesCreateLink)&lt;br /&gt;
	end&lt;br /&gt;
	local messageName&lt;br /&gt;
	if subjectSpace == 828 then&lt;br /&gt;
		messageName = &#039;experiment-blurb-module&#039;&lt;br /&gt;
	else&lt;br /&gt;
		messageName = &#039;experiment-blurb-template&#039;&lt;br /&gt;
	end&lt;br /&gt;
	return message(messageName, {sandboxLinks, testcasesLinks})&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function p.makeCategoriesBlurb(args, env)&lt;br /&gt;
	--[[&lt;br /&gt;
	-- Generates the text &amp;quot;Please add categories to the /doc subpage.&amp;quot;&lt;br /&gt;
	-- @args - a table of arguments passed by the user&lt;br /&gt;
	-- @env - environment table containing title objects, etc., generated with p.getEnvironment&lt;br /&gt;
	-- Messages:&lt;br /&gt;
	-- &#039;doc-link-display&#039; --&amp;gt; &#039;/doc&#039;&lt;br /&gt;
	-- &#039;add-categories-blurb&#039; --&amp;gt; &#039;Please add categories to the $1 subpage.&#039;&lt;br /&gt;
	--]]&lt;br /&gt;
	local docTitle = env.docTitle&lt;br /&gt;
	if not docTitle then&lt;br /&gt;
		return nil&lt;br /&gt;
	end&lt;br /&gt;
	local docPathLink = makeWikilink(docTitle.prefixedText, message(&#039;doc-link-display&#039;))&lt;br /&gt;
	return message(&#039;add-categories-blurb&#039;, {docPathLink})&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function p.makeSubpagesBlurb(args, env)&lt;br /&gt;
	--[[&lt;br /&gt;
	-- Generates the &amp;quot;Subpages of this template&amp;quot; link.&lt;br /&gt;
	-- @args - a table of arguments passed by the user&lt;br /&gt;
	-- @env - environment table containing title objects, etc., generated with p.getEnvironment&lt;br /&gt;
	&lt;br /&gt;
	-- Messages:&lt;br /&gt;
	-- &#039;template-pagetype&#039; --&amp;gt; &#039;template&#039;&lt;br /&gt;
	-- &#039;module-pagetype&#039; --&amp;gt; &#039;module&#039;&lt;br /&gt;
	-- &#039;default-pagetype&#039; --&amp;gt; &#039;page&#039;&lt;br /&gt;
	-- &#039;subpages-link-display&#039; --&amp;gt; &#039;Subpages of this $1&#039;&lt;br /&gt;
	--]]&lt;br /&gt;
	local subjectSpace = env.subjectSpace&lt;br /&gt;
	local templateTitle = env.templateTitle&lt;br /&gt;
	if not subjectSpace or not templateTitle then&lt;br /&gt;
		return nil&lt;br /&gt;
	end&lt;br /&gt;
	local pagetype&lt;br /&gt;
	if subjectSpace == 10 then&lt;br /&gt;
		pagetype = message(&#039;template-pagetype&#039;)&lt;br /&gt;
	elseif subjectSpace == 828 then&lt;br /&gt;
		pagetype = message(&#039;module-pagetype&#039;)&lt;br /&gt;
	else&lt;br /&gt;
		pagetype = message(&#039;default-pagetype&#039;)&lt;br /&gt;
	end&lt;br /&gt;
	local subpagesLink = makeWikilink(&lt;br /&gt;
		&#039;Special:PrefixIndex/&#039; .. templateTitle.prefixedText .. &#039;/&#039;,&lt;br /&gt;
		message(&#039;subpages-link-display&#039;, {pagetype})&lt;br /&gt;
	)&lt;br /&gt;
	return message(&#039;subpages-blurb&#039;, {subpagesLink})&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
----------------------------------------------------------------------------&lt;br /&gt;
-- Tracking categories&lt;br /&gt;
----------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
function p.addTrackingCategories(env)&lt;br /&gt;
	--[[&lt;br /&gt;
	-- Check if {{documentation}} is transcluded on a /doc or /testcases page.&lt;br /&gt;
	-- @env - environment table containing title objects, etc., generated with p.getEnvironment&lt;br /&gt;
	&lt;br /&gt;
	-- Messages:&lt;br /&gt;
	-- &#039;display-strange-usage-category&#039; --&amp;gt; true&lt;br /&gt;
	-- &#039;doc-subpage&#039; --&amp;gt; &#039;doc&#039;&lt;br /&gt;
	-- &#039;testcases-subpage&#039; --&amp;gt; &#039;testcases&#039;&lt;br /&gt;
	-- &#039;strange-usage-category&#039; --&amp;gt; &#039;Wikipedia pages with strange ((documentation)) usage&#039;&lt;br /&gt;
	-- &lt;br /&gt;
	-- /testcases pages in the module namespace are not categorised, as they may have&lt;br /&gt;
	-- {{documentation}} transcluded automatically.&lt;br /&gt;
	--]]&lt;br /&gt;
	local title = env.title&lt;br /&gt;
	local subjectSpace = env.subjectSpace&lt;br /&gt;
	if not title or not subjectSpace then&lt;br /&gt;
		return nil&lt;br /&gt;
	end&lt;br /&gt;
	local subpage = title.subpageText&lt;br /&gt;
	local ret = &#039;&#039;&lt;br /&gt;
	if message(&#039;display-strange-usage-category&#039;, nil, &#039;boolean&#039;)&lt;br /&gt;
		and (&lt;br /&gt;
			subpage == message(&#039;doc-subpage&#039;)&lt;br /&gt;
			or subjectSpace ~= 828 and subpage == message(&#039;testcases-subpage&#039;)&lt;br /&gt;
		)&lt;br /&gt;
	then&lt;br /&gt;
		ret = ret .. makeCategoryLink(message(&#039;strange-usage-category&#039;))&lt;br /&gt;
	end&lt;br /&gt;
	return ret&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
return p&lt;/div&gt;</summary>
		<author><name>Vanilla</name></author>
	</entry>
	<entry>
		<id>https://wiki.pxls.space/index.php?title=Module:Infobox_military_conflict&amp;diff=6917</id>
		<title>Module:Infobox military conflict</title>
		<link rel="alternate" type="text/html" href="https://wiki.pxls.space/index.php?title=Module:Infobox_military_conflict&amp;diff=6917"/>
		<updated>2023-03-01T00:38:23Z</updated>

		<summary type="html">&lt;p&gt;Vanilla: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;require(&#039;strict&#039;)&lt;br /&gt;
&lt;br /&gt;
local infoboxStyle = mw.loadData(&#039;Module:WPMILHIST Infobox style&#039;)&lt;br /&gt;
local templatestyles = &#039;Module:Infobox military conflict/styles.css&#039;&lt;br /&gt;
&lt;br /&gt;
local IMC = {}&lt;br /&gt;
IMC.__index = IMC&lt;br /&gt;
&lt;br /&gt;
function IMC:renderPerCombatant(builder, headerText, prefix, suffix)&lt;br /&gt;
	prefix = prefix or &#039;&#039;&lt;br /&gt;
	suffix = suffix or &#039;&#039;&lt;br /&gt;
	local colspans = {}&lt;br /&gt;
	&lt;br /&gt;
	-- This may result in colspans[1] getting set twice, but&lt;br /&gt;
	-- this is no big deal. The second set will be correct.&lt;br /&gt;
	local lastCombatant = 1&lt;br /&gt;
	&lt;br /&gt;
	for i = 1,self.combatants do&lt;br /&gt;
		if self.args[prefix .. i .. suffix] then&lt;br /&gt;
			colspans[lastCombatant] = i - lastCombatant&lt;br /&gt;
			lastCombatant = i&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local jointText = self.args[prefix .. (self.combatants + 1) .. suffix]&lt;br /&gt;
	&lt;br /&gt;
	if headerText and (colspans[1] or jointText) then&lt;br /&gt;
		builder:tag(&#039;tr&#039;)&lt;br /&gt;
			:tag(&#039;th&#039;)&lt;br /&gt;
				:attr(&#039;colspan&#039;, self.combatants)&lt;br /&gt;
				:cssText(infoboxStyle.header_raw)&lt;br /&gt;
				:wikitext(headerText)&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- The only time colspans[1] wouldn&#039;t be set is if no&lt;br /&gt;
	-- combatant has a field with the given prefix and suffix.&lt;br /&gt;
	if colspans[1] then&lt;br /&gt;
		-- Since each found argument set the colspan for the previous&lt;br /&gt;
		-- one, the final one wasn&#039;t set above, so set it now.&lt;br /&gt;
		colspans[lastCombatant] = self.combatants - lastCombatant + 1&lt;br /&gt;
		builder = builder:tag(&#039;tr&#039;)&lt;br /&gt;
		for i = 1,self.combatants do&lt;br /&gt;
			-- At this point, colspans[i] will be set for i=1 unconditionally, and for&lt;br /&gt;
			-- any other value of i where self.args[prefix .. i .. suffix] is set.&lt;br /&gt;
			if colspans[i] then&lt;br /&gt;
				builder:tag(&#039;td&#039;)&lt;br /&gt;
					-- don&#039;t bother emitting colspan=&amp;quot;1&amp;quot;&lt;br /&gt;
					:attr(&#039;colspan&#039;, colspans[i] ~= 1 and colspans[i] or nil)&lt;br /&gt;
					:css(&#039;width&#039;, math.floor(100 / self.combatants * colspans[i] + 0.5) .. &#039;%&#039;)&lt;br /&gt;
					-- no border on the right of the rightmost column&lt;br /&gt;
					:css(&#039;border-right&#039;, i ~= lastCombatant and infoboxStyle.internal_border or nil)&lt;br /&gt;
					-- no padding on the left of the leftmost column&lt;br /&gt;
					:css(&#039;padding-left&#039;, i ~= 1 and &#039;0.25em&#039; or nil)&lt;br /&gt;
					-- don&#039;t show the border if we&#039;re directly under a header&lt;br /&gt;
					:css(&#039;border-top&#039;, not headerText and infoboxStyle.internal_border or nil)&lt;br /&gt;
					:newline()&lt;br /&gt;
					:wikitext(self.args[prefix .. i .. suffix])&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	if jointText then&lt;br /&gt;
		builder:tag(&#039;tr&#039;)&lt;br /&gt;
			:tag(&#039;td&#039;)&lt;br /&gt;
				:attr(&#039;colspan&#039;, self.combatants)&lt;br /&gt;
				:css(&#039;text-align&#039;, &#039;center&#039;)&lt;br /&gt;
				-- don&#039;t show the border if we&#039;re directly under a header&lt;br /&gt;
				:css(&#039;border-top&#039;, (not headerText or colspans[1]) and infoboxStyle.internal_border or nil)&lt;br /&gt;
				:newline()&lt;br /&gt;
				:wikitext(jointText)&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function IMC:renderHeaderTable(builder)&lt;br /&gt;
	builder = builder:tag(&#039;table&#039;)&lt;br /&gt;
		:css(&#039;width&#039;, &#039;100%&#039;)&lt;br /&gt;
		:css(&#039;margin&#039;, 0)&lt;br /&gt;
		:css(&#039;padding&#039;, 0)&lt;br /&gt;
		:css(&#039;border&#039;, 0)&lt;br /&gt;
		:css(&#039;display&#039;, &#039;inline-table&#039;)&lt;br /&gt;
&lt;br /&gt;
	if self.args.date then&lt;br /&gt;
		builder:tag(&#039;tr&#039;)&lt;br /&gt;
			:tag(&#039;th&#039;)&lt;br /&gt;
				:css(&#039;padding-right&#039;, &#039;1em&#039;)&lt;br /&gt;
				:wikitext(&#039;Date&#039;)&lt;br /&gt;
			:done()&lt;br /&gt;
			:tag(&#039;td&#039;)&lt;br /&gt;
				:wikitext(self.args.date)&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	builder = builder:tag(&#039;tr&#039;)&lt;br /&gt;
		:tag(&#039;th&#039;)&lt;br /&gt;
			:css(&#039;padding-right&#039;, &#039;1em&#039;)&lt;br /&gt;
			:wikitext(&#039;Location&#039;)&lt;br /&gt;
		:done()&lt;br /&gt;
		:tag(&#039;td&#039;)&lt;br /&gt;
			:tag(&#039;div&#039;)&lt;br /&gt;
				:addClass(&#039;location&#039;)&lt;br /&gt;
				:wikitext(self.args.place or &#039;{&amp;amp;#123;{place}&amp;amp;#125;}&#039;) -- hack so that people who don&#039;t know Lua know that this parameter is required&lt;br /&gt;
			:done()&lt;br /&gt;
	if self.args.coordinates then&lt;br /&gt;
		builder:wikitext(self.args.coordinates)&lt;br /&gt;
	end&lt;br /&gt;
	builder = builder:done():done()&lt;br /&gt;
&lt;br /&gt;
	-- only for &amp;quot;Putsch&amp;quot;&lt;br /&gt;
    if self.args.action then&lt;br /&gt;
		builder:tag(&#039;tr&#039;)&lt;br /&gt;
			:tag(&#039;th&#039;)&lt;br /&gt;
				:css(&#039;padding-right&#039;, &#039;1em&#039;)&lt;br /&gt;
				:wikitext(self.args.action and &#039;Action&#039;)&lt;br /&gt;
			:done()&lt;br /&gt;
			:tag(&#039;td&#039;)&lt;br /&gt;
				:wikitext(self.args.action)&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	if self.args.status or self.args.result then&lt;br /&gt;
		builder:tag(&#039;tr&#039;)&lt;br /&gt;
			:tag(&#039;th&#039;)&lt;br /&gt;
				:css(&#039;padding-right&#039;, &#039;1em&#039;)&lt;br /&gt;
				:wikitext(self.args.status and &#039;Status&#039; or &#039;Result&#039;)&lt;br /&gt;
			:done()&lt;br /&gt;
			:tag(&#039;td&#039;)&lt;br /&gt;
				:addClass(&#039;status&#039;)&lt;br /&gt;
				:newline()&lt;br /&gt;
				:wikitext(self.args.status or self.args.result)&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	if self.args.territory then&lt;br /&gt;
		builder:tag(&#039;tr&#039;)&lt;br /&gt;
			:tag(&#039;th&#039;)&lt;br /&gt;
				:css(&#039;padding-right&#039;, &#039;1em&#039;)&lt;br /&gt;
				:wikitext(&#039;Territorial&amp;lt;br /&amp;gt;changes&#039;)&lt;br /&gt;
			:done()&lt;br /&gt;
			:tag(&#039;td&#039;)&lt;br /&gt;
				:newline()&lt;br /&gt;
				:wikitext(self.args.territory)&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function IMC:render()&lt;br /&gt;
	local builder = mw.html.create()&lt;br /&gt;
	if self.args.campaignbox then&lt;br /&gt;
		-- this should be the same as using {{stack|clear=right|...}}&lt;br /&gt;
		builder:wikitext(self.frame:expandTemplate{ title = &#039;stack begin&#039;, args = { clear=&#039;true&#039;} })&lt;br /&gt;
	end&lt;br /&gt;
	builder = builder:tag(&#039;table&#039;)&lt;br /&gt;
		:addClass(&#039;infobox vevent&#039;)&lt;br /&gt;
		:cssText(infoboxStyle.main_box_raw)&lt;br /&gt;
		:css(&#039;width&#039;, self.args.width or nil)&lt;br /&gt;
&lt;br /&gt;
	builder:tag(&#039;tr&#039;)&lt;br /&gt;
		:tag(&#039;th&#039;)&lt;br /&gt;
			:addClass(&#039;summary&#039;)&lt;br /&gt;
			:attr(&#039;colspan&#039;, self.combatants)&lt;br /&gt;
			:cssText(infoboxStyle.header_raw)&lt;br /&gt;
			:wikitext(self.args.conflict or mw.title.getCurrentTitle().text)&lt;br /&gt;
	if self.args.partof then&lt;br /&gt;
		builder:tag(&#039;tr&#039;)&lt;br /&gt;
			:tag(&#039;td&#039;)&lt;br /&gt;
				:attr(&#039;colspan&#039;, self.combatants)&lt;br /&gt;
				:cssText(infoboxStyle.sub_header_raw)&lt;br /&gt;
				:wikitext(&#039;Part of &#039; .. self.args.partof)&lt;br /&gt;
	end&lt;br /&gt;
	if self.args.image then&lt;br /&gt;
		builder:tag(&#039;tr&#039;)&lt;br /&gt;
			:tag(&#039;td&#039;)&lt;br /&gt;
				:attr(&#039;colspan&#039;, self.combatants)&lt;br /&gt;
				:cssText(infoboxStyle.image_box_raw)&lt;br /&gt;
				:wikitext(string.format(&#039;%s%s%s&#039;,&lt;br /&gt;
					require(&#039;Module:InfoboxImage&#039;).InfoboxImage{args = {&lt;br /&gt;
						image = self.args.image,&lt;br /&gt;
						size = self.args.image_size,&lt;br /&gt;
						sizedefault = &#039;frameless&#039;,&lt;br /&gt;
						upright = 1,&lt;br /&gt;
						alt = self.args.alt&lt;br /&gt;
					}},&lt;br /&gt;
					self.args.caption and &#039;&amp;lt;br /&amp;gt;&#039; or &#039;&#039;,&lt;br /&gt;
					self.args.caption or &#039;&#039;&lt;br /&gt;
				))&lt;br /&gt;
	end&lt;br /&gt;
	self:renderHeaderTable(builder:tag(&#039;tr&#039;):tag(&#039;td&#039;):attr(&#039;colspan&#039;, self.combatants))&lt;br /&gt;
	self:renderPerCombatant(builder, self.args.combatants_header or &#039;Belligerents&#039;, &#039;combatant&#039;)&lt;br /&gt;
	-- can be un-hardcoded once gerrit:165108 is merged&lt;br /&gt;
	for _,v in ipairs{&#039;a&#039;,&#039;b&#039;,&#039;c&#039;,&#039;d&#039;} do&lt;br /&gt;
		self:renderPerCombatant(builder, nil, &#039;combatant&#039;, v)&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	self:renderPerCombatant(builder, self.args.commanders_header or &#039;Commanders and leaders&#039;, &#039;commander&#039;)&lt;br /&gt;
	for _,v in ipairs{&#039;a&#039;,&#039;b&#039;,&#039;c&#039;,&#039;d&#039;} do&lt;br /&gt;
		self:renderPerCombatant(builder, nil, &#039;commander&#039;, v)&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	self:renderPerCombatant(builder, self.args.units_header or &#039;Units involved&#039;, &#039;units&#039;)&lt;br /&gt;
	self:renderPerCombatant(builder, self.args.strengths_header or &#039;Strength&#039;, &#039;strength&#039;)&lt;br /&gt;
	self:renderPerCombatant(builder, self.args.polstrengths_header or &#039;Political support&#039;, &#039;polstrength&#039;)&lt;br /&gt;
	self:renderPerCombatant(builder, self.args.milstrengths_header or &#039;Military support&#039;, &#039;milstrength&#039;)&lt;br /&gt;
	self:renderPerCombatant(builder, self.args.casualties_header or &#039;Casualties and losses&#039;, &#039;casualties&#039;)&lt;br /&gt;
&lt;br /&gt;
	if self.args.notes then&lt;br /&gt;
		builder:tag(&#039;tr&#039;)&lt;br /&gt;
			:tag(&#039;td&#039;)&lt;br /&gt;
				:attr(&#039;colspan&#039;, self.combatants)&lt;br /&gt;
				:css(&#039;border-top&#039;, infoboxStyle.section_border)&lt;br /&gt;
				:newline()&lt;br /&gt;
				:wikitext(self.args.notes)&lt;br /&gt;
	end&lt;br /&gt;
	if self.args.map_type then&lt;br /&gt;
		builder:tag(&#039;tr&#039;)&lt;br /&gt;
			:tag(&#039;td&#039;)&lt;br /&gt;
				:attr(&#039;colspan&#039;, self.combatants)&lt;br /&gt;
				:css(&#039;border-top&#039;, infoboxStyle.internal_border)&lt;br /&gt;
				:node(require(&#039;Module:Location map&#039;).main(self.frame, {&lt;br /&gt;
					self.args.map_type,&lt;br /&gt;
					relief = self.args.map_relief,&lt;br /&gt;
					coordinates = self.args.coordinates,&lt;br /&gt;
					width = self.args.map_size or 220,&lt;br /&gt;
					float = &#039;center&#039;,&lt;br /&gt;
					border = &#039;none&#039;,&lt;br /&gt;
					mark = self.args.map_mark,&lt;br /&gt;
					marksize = self.args.map_marksize or 8,&lt;br /&gt;
					label = self.args.map_label,&lt;br /&gt;
					alt = self.args.map_alt,&lt;br /&gt;
					caption = self.args.map_caption or (&#039;Location within &#039; &lt;br /&gt;
						.. (require(&#039;Module:Location map&#039;).data(self.frame, {self.args.map_type, &#039;name&#039;})))&lt;br /&gt;
				}))&lt;br /&gt;
	end&lt;br /&gt;
	builder = builder:done()&lt;br /&gt;
	if self.args.campaignbox then&lt;br /&gt;
		builder = builder:done()&lt;br /&gt;
		builder:wikitext(self.args.campaignbox .. self.frame:expandTemplate{ title = &#039;stack end&#039;})&lt;br /&gt;
	end&lt;br /&gt;
	return builder&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function IMC.new(frame, args)&lt;br /&gt;
	if not args then&lt;br /&gt;
		args = require(&#039;Module:Arguments&#039;).getArgs(frame, {wrappers = &#039;Template:Infobox military conflict&#039;})&lt;br /&gt;
	end&lt;br /&gt;
	local obj = {&lt;br /&gt;
		frame = frame,&lt;br /&gt;
		args = args&lt;br /&gt;
	}&lt;br /&gt;
&lt;br /&gt;
	-- until gerrit:165108 is merged, there&#039;s still a cap on combatants, but as soon as it merges, we can update this little bit of code to uncap it&lt;br /&gt;
	-- also, don&#039;t try to make this more efficient, or references could be in the wrong order&lt;br /&gt;
	obj.combatants = 2&lt;br /&gt;
	for _,v in ipairs{&#039;&#039;, &#039;a&#039;, &#039;b&#039;, &#039;c&#039;, &#039;d&#039;} do&lt;br /&gt;
		for i = 1,5 do&lt;br /&gt;
			if args[&#039;combatant&#039; .. i .. v] then&lt;br /&gt;
				obj.combatants = math.max(obj.combatants, i)&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	return setmetatable(obj, IMC)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
local p = {}&lt;br /&gt;
&lt;br /&gt;
function p.main(frame)&lt;br /&gt;
	return frame:extensionTag{ name = &#039;templatestyles&#039;, args = { src = templatestyles} } .. tostring(IMC.new(frame):render())&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
return p&lt;/div&gt;</summary>
		<author><name>Vanilla</name></author>
	</entry>
	<entry>
		<id>https://wiki.pxls.space/index.php?title=Module:Infobox_military_conflict&amp;diff=6916</id>
		<title>Module:Infobox military conflict</title>
		<link rel="alternate" type="text/html" href="https://wiki.pxls.space/index.php?title=Module:Infobox_military_conflict&amp;diff=6916"/>
		<updated>2023-03-01T00:38:16Z</updated>

		<summary type="html">&lt;p&gt;Vanilla: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;require(&#039;strict&#039;) -- test&lt;br /&gt;
&lt;br /&gt;
local infoboxStyle = mw.loadData(&#039;Module:WPMILHIST Infobox style&#039;)&lt;br /&gt;
local templatestyles = &#039;Module:Infobox military conflict/styles.css&#039;&lt;br /&gt;
&lt;br /&gt;
local IMC = {}&lt;br /&gt;
IMC.__index = IMC&lt;br /&gt;
&lt;br /&gt;
function IMC:renderPerCombatant(builder, headerText, prefix, suffix)&lt;br /&gt;
	prefix = prefix or &#039;&#039;&lt;br /&gt;
	suffix = suffix or &#039;&#039;&lt;br /&gt;
	local colspans = {}&lt;br /&gt;
	&lt;br /&gt;
	-- This may result in colspans[1] getting set twice, but&lt;br /&gt;
	-- this is no big deal. The second set will be correct.&lt;br /&gt;
	local lastCombatant = 1&lt;br /&gt;
	&lt;br /&gt;
	for i = 1,self.combatants do&lt;br /&gt;
		if self.args[prefix .. i .. suffix] then&lt;br /&gt;
			colspans[lastCombatant] = i - lastCombatant&lt;br /&gt;
			lastCombatant = i&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local jointText = self.args[prefix .. (self.combatants + 1) .. suffix]&lt;br /&gt;
	&lt;br /&gt;
	if headerText and (colspans[1] or jointText) then&lt;br /&gt;
		builder:tag(&#039;tr&#039;)&lt;br /&gt;
			:tag(&#039;th&#039;)&lt;br /&gt;
				:attr(&#039;colspan&#039;, self.combatants)&lt;br /&gt;
				:cssText(infoboxStyle.header_raw)&lt;br /&gt;
				:wikitext(headerText)&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- The only time colspans[1] wouldn&#039;t be set is if no&lt;br /&gt;
	-- combatant has a field with the given prefix and suffix.&lt;br /&gt;
	if colspans[1] then&lt;br /&gt;
		-- Since each found argument set the colspan for the previous&lt;br /&gt;
		-- one, the final one wasn&#039;t set above, so set it now.&lt;br /&gt;
		colspans[lastCombatant] = self.combatants - lastCombatant + 1&lt;br /&gt;
		builder = builder:tag(&#039;tr&#039;)&lt;br /&gt;
		for i = 1,self.combatants do&lt;br /&gt;
			-- At this point, colspans[i] will be set for i=1 unconditionally, and for&lt;br /&gt;
			-- any other value of i where self.args[prefix .. i .. suffix] is set.&lt;br /&gt;
			if colspans[i] then&lt;br /&gt;
				builder:tag(&#039;td&#039;)&lt;br /&gt;
					-- don&#039;t bother emitting colspan=&amp;quot;1&amp;quot;&lt;br /&gt;
					:attr(&#039;colspan&#039;, colspans[i] ~= 1 and colspans[i] or nil)&lt;br /&gt;
					:css(&#039;width&#039;, math.floor(100 / self.combatants * colspans[i] + 0.5) .. &#039;%&#039;)&lt;br /&gt;
					-- no border on the right of the rightmost column&lt;br /&gt;
					:css(&#039;border-right&#039;, i ~= lastCombatant and infoboxStyle.internal_border or nil)&lt;br /&gt;
					-- no padding on the left of the leftmost column&lt;br /&gt;
					:css(&#039;padding-left&#039;, i ~= 1 and &#039;0.25em&#039; or nil)&lt;br /&gt;
					-- don&#039;t show the border if we&#039;re directly under a header&lt;br /&gt;
					:css(&#039;border-top&#039;, not headerText and infoboxStyle.internal_border or nil)&lt;br /&gt;
					:newline()&lt;br /&gt;
					:wikitext(self.args[prefix .. i .. suffix])&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	if jointText then&lt;br /&gt;
		builder:tag(&#039;tr&#039;)&lt;br /&gt;
			:tag(&#039;td&#039;)&lt;br /&gt;
				:attr(&#039;colspan&#039;, self.combatants)&lt;br /&gt;
				:css(&#039;text-align&#039;, &#039;center&#039;)&lt;br /&gt;
				-- don&#039;t show the border if we&#039;re directly under a header&lt;br /&gt;
				:css(&#039;border-top&#039;, (not headerText or colspans[1]) and infoboxStyle.internal_border or nil)&lt;br /&gt;
				:newline()&lt;br /&gt;
				:wikitext(jointText)&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function IMC:renderHeaderTable(builder)&lt;br /&gt;
	builder = builder:tag(&#039;table&#039;)&lt;br /&gt;
		:css(&#039;width&#039;, &#039;100%&#039;)&lt;br /&gt;
		:css(&#039;margin&#039;, 0)&lt;br /&gt;
		:css(&#039;padding&#039;, 0)&lt;br /&gt;
		:css(&#039;border&#039;, 0)&lt;br /&gt;
		:css(&#039;display&#039;, &#039;inline-table&#039;)&lt;br /&gt;
&lt;br /&gt;
	if self.args.date then&lt;br /&gt;
		builder:tag(&#039;tr&#039;)&lt;br /&gt;
			:tag(&#039;th&#039;)&lt;br /&gt;
				:css(&#039;padding-right&#039;, &#039;1em&#039;)&lt;br /&gt;
				:wikitext(&#039;Date&#039;)&lt;br /&gt;
			:done()&lt;br /&gt;
			:tag(&#039;td&#039;)&lt;br /&gt;
				:wikitext(self.args.date)&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	builder = builder:tag(&#039;tr&#039;)&lt;br /&gt;
		:tag(&#039;th&#039;)&lt;br /&gt;
			:css(&#039;padding-right&#039;, &#039;1em&#039;)&lt;br /&gt;
			:wikitext(&#039;Location&#039;)&lt;br /&gt;
		:done()&lt;br /&gt;
		:tag(&#039;td&#039;)&lt;br /&gt;
			:tag(&#039;div&#039;)&lt;br /&gt;
				:addClass(&#039;location&#039;)&lt;br /&gt;
				:wikitext(self.args.place or &#039;{&amp;amp;#123;{place}&amp;amp;#125;}&#039;) -- hack so that people who don&#039;t know Lua know that this parameter is required&lt;br /&gt;
			:done()&lt;br /&gt;
	if self.args.coordinates then&lt;br /&gt;
		builder:wikitext(self.args.coordinates)&lt;br /&gt;
	end&lt;br /&gt;
	builder = builder:done():done()&lt;br /&gt;
&lt;br /&gt;
	-- only for &amp;quot;Putsch&amp;quot;&lt;br /&gt;
    if self.args.action then&lt;br /&gt;
		builder:tag(&#039;tr&#039;)&lt;br /&gt;
			:tag(&#039;th&#039;)&lt;br /&gt;
				:css(&#039;padding-right&#039;, &#039;1em&#039;)&lt;br /&gt;
				:wikitext(self.args.action and &#039;Action&#039;)&lt;br /&gt;
			:done()&lt;br /&gt;
			:tag(&#039;td&#039;)&lt;br /&gt;
				:wikitext(self.args.action)&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	if self.args.status or self.args.result then&lt;br /&gt;
		builder:tag(&#039;tr&#039;)&lt;br /&gt;
			:tag(&#039;th&#039;)&lt;br /&gt;
				:css(&#039;padding-right&#039;, &#039;1em&#039;)&lt;br /&gt;
				:wikitext(self.args.status and &#039;Status&#039; or &#039;Result&#039;)&lt;br /&gt;
			:done()&lt;br /&gt;
			:tag(&#039;td&#039;)&lt;br /&gt;
				:addClass(&#039;status&#039;)&lt;br /&gt;
				:newline()&lt;br /&gt;
				:wikitext(self.args.status or self.args.result)&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	if self.args.territory then&lt;br /&gt;
		builder:tag(&#039;tr&#039;)&lt;br /&gt;
			:tag(&#039;th&#039;)&lt;br /&gt;
				:css(&#039;padding-right&#039;, &#039;1em&#039;)&lt;br /&gt;
				:wikitext(&#039;Territorial&amp;lt;br /&amp;gt;changes&#039;)&lt;br /&gt;
			:done()&lt;br /&gt;
			:tag(&#039;td&#039;)&lt;br /&gt;
				:newline()&lt;br /&gt;
				:wikitext(self.args.territory)&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function IMC:render()&lt;br /&gt;
	local builder = mw.html.create()&lt;br /&gt;
	if self.args.campaignbox then&lt;br /&gt;
		-- this should be the same as using {{stack|clear=right|...}}&lt;br /&gt;
		builder:wikitext(self.frame:expandTemplate{ title = &#039;stack begin&#039;, args = { clear=&#039;true&#039;} })&lt;br /&gt;
	end&lt;br /&gt;
	builder = builder:tag(&#039;table&#039;)&lt;br /&gt;
		:addClass(&#039;infobox vevent&#039;)&lt;br /&gt;
		:cssText(infoboxStyle.main_box_raw)&lt;br /&gt;
		:css(&#039;width&#039;, self.args.width or nil)&lt;br /&gt;
&lt;br /&gt;
	builder:tag(&#039;tr&#039;)&lt;br /&gt;
		:tag(&#039;th&#039;)&lt;br /&gt;
			:addClass(&#039;summary&#039;)&lt;br /&gt;
			:attr(&#039;colspan&#039;, self.combatants)&lt;br /&gt;
			:cssText(infoboxStyle.header_raw)&lt;br /&gt;
			:wikitext(self.args.conflict or mw.title.getCurrentTitle().text)&lt;br /&gt;
	if self.args.partof then&lt;br /&gt;
		builder:tag(&#039;tr&#039;)&lt;br /&gt;
			:tag(&#039;td&#039;)&lt;br /&gt;
				:attr(&#039;colspan&#039;, self.combatants)&lt;br /&gt;
				:cssText(infoboxStyle.sub_header_raw)&lt;br /&gt;
				:wikitext(&#039;Part of &#039; .. self.args.partof)&lt;br /&gt;
	end&lt;br /&gt;
	if self.args.image then&lt;br /&gt;
		builder:tag(&#039;tr&#039;)&lt;br /&gt;
			:tag(&#039;td&#039;)&lt;br /&gt;
				:attr(&#039;colspan&#039;, self.combatants)&lt;br /&gt;
				:cssText(infoboxStyle.image_box_raw)&lt;br /&gt;
				:wikitext(string.format(&#039;%s%s%s&#039;,&lt;br /&gt;
					require(&#039;Module:InfoboxImage&#039;).InfoboxImage{args = {&lt;br /&gt;
						image = self.args.image,&lt;br /&gt;
						size = self.args.image_size,&lt;br /&gt;
						sizedefault = &#039;frameless&#039;,&lt;br /&gt;
						upright = 1,&lt;br /&gt;
						alt = self.args.alt&lt;br /&gt;
					}},&lt;br /&gt;
					self.args.caption and &#039;&amp;lt;br /&amp;gt;&#039; or &#039;&#039;,&lt;br /&gt;
					self.args.caption or &#039;&#039;&lt;br /&gt;
				))&lt;br /&gt;
	end&lt;br /&gt;
	self:renderHeaderTable(builder:tag(&#039;tr&#039;):tag(&#039;td&#039;):attr(&#039;colspan&#039;, self.combatants))&lt;br /&gt;
	self:renderPerCombatant(builder, self.args.combatants_header or &#039;Belligerents&#039;, &#039;combatant&#039;)&lt;br /&gt;
	-- can be un-hardcoded once gerrit:165108 is merged&lt;br /&gt;
	for _,v in ipairs{&#039;a&#039;,&#039;b&#039;,&#039;c&#039;,&#039;d&#039;} do&lt;br /&gt;
		self:renderPerCombatant(builder, nil, &#039;combatant&#039;, v)&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	self:renderPerCombatant(builder, self.args.commanders_header or &#039;Commanders and leaders&#039;, &#039;commander&#039;)&lt;br /&gt;
	for _,v in ipairs{&#039;a&#039;,&#039;b&#039;,&#039;c&#039;,&#039;d&#039;} do&lt;br /&gt;
		self:renderPerCombatant(builder, nil, &#039;commander&#039;, v)&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	self:renderPerCombatant(builder, self.args.units_header or &#039;Units involved&#039;, &#039;units&#039;)&lt;br /&gt;
	self:renderPerCombatant(builder, self.args.strengths_header or &#039;Strength&#039;, &#039;strength&#039;)&lt;br /&gt;
	self:renderPerCombatant(builder, self.args.polstrengths_header or &#039;Political support&#039;, &#039;polstrength&#039;)&lt;br /&gt;
	self:renderPerCombatant(builder, self.args.milstrengths_header or &#039;Military support&#039;, &#039;milstrength&#039;)&lt;br /&gt;
	self:renderPerCombatant(builder, self.args.casualties_header or &#039;Casualties and losses&#039;, &#039;casualties&#039;)&lt;br /&gt;
&lt;br /&gt;
	if self.args.notes then&lt;br /&gt;
		builder:tag(&#039;tr&#039;)&lt;br /&gt;
			:tag(&#039;td&#039;)&lt;br /&gt;
				:attr(&#039;colspan&#039;, self.combatants)&lt;br /&gt;
				:css(&#039;border-top&#039;, infoboxStyle.section_border)&lt;br /&gt;
				:newline()&lt;br /&gt;
				:wikitext(self.args.notes)&lt;br /&gt;
	end&lt;br /&gt;
	if self.args.map_type then&lt;br /&gt;
		builder:tag(&#039;tr&#039;)&lt;br /&gt;
			:tag(&#039;td&#039;)&lt;br /&gt;
				:attr(&#039;colspan&#039;, self.combatants)&lt;br /&gt;
				:css(&#039;border-top&#039;, infoboxStyle.internal_border)&lt;br /&gt;
				:node(require(&#039;Module:Location map&#039;).main(self.frame, {&lt;br /&gt;
					self.args.map_type,&lt;br /&gt;
					relief = self.args.map_relief,&lt;br /&gt;
					coordinates = self.args.coordinates,&lt;br /&gt;
					width = self.args.map_size or 220,&lt;br /&gt;
					float = &#039;center&#039;,&lt;br /&gt;
					border = &#039;none&#039;,&lt;br /&gt;
					mark = self.args.map_mark,&lt;br /&gt;
					marksize = self.args.map_marksize or 8,&lt;br /&gt;
					label = self.args.map_label,&lt;br /&gt;
					alt = self.args.map_alt,&lt;br /&gt;
					caption = self.args.map_caption or (&#039;Location within &#039; &lt;br /&gt;
						.. (require(&#039;Module:Location map&#039;).data(self.frame, {self.args.map_type, &#039;name&#039;})))&lt;br /&gt;
				}))&lt;br /&gt;
	end&lt;br /&gt;
	builder = builder:done()&lt;br /&gt;
	if self.args.campaignbox then&lt;br /&gt;
		builder = builder:done()&lt;br /&gt;
		builder:wikitext(self.args.campaignbox .. self.frame:expandTemplate{ title = &#039;stack end&#039;})&lt;br /&gt;
	end&lt;br /&gt;
	return builder&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function IMC.new(frame, args)&lt;br /&gt;
	if not args then&lt;br /&gt;
		args = require(&#039;Module:Arguments&#039;).getArgs(frame, {wrappers = &#039;Template:Infobox military conflict&#039;})&lt;br /&gt;
	end&lt;br /&gt;
	local obj = {&lt;br /&gt;
		frame = frame,&lt;br /&gt;
		args = args&lt;br /&gt;
	}&lt;br /&gt;
&lt;br /&gt;
	-- until gerrit:165108 is merged, there&#039;s still a cap on combatants, but as soon as it merges, we can update this little bit of code to uncap it&lt;br /&gt;
	-- also, don&#039;t try to make this more efficient, or references could be in the wrong order&lt;br /&gt;
	obj.combatants = 2&lt;br /&gt;
	for _,v in ipairs{&#039;&#039;, &#039;a&#039;, &#039;b&#039;, &#039;c&#039;, &#039;d&#039;} do&lt;br /&gt;
		for i = 1,5 do&lt;br /&gt;
			if args[&#039;combatant&#039; .. i .. v] then&lt;br /&gt;
				obj.combatants = math.max(obj.combatants, i)&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	return setmetatable(obj, IMC)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
local p = {}&lt;br /&gt;
&lt;br /&gt;
function p.main(frame)&lt;br /&gt;
	return frame:extensionTag{ name = &#039;templatestyles&#039;, args = { src = templatestyles} } .. tostring(IMC.new(frame):render())&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
return p&lt;/div&gt;</summary>
		<author><name>Vanilla</name></author>
	</entry>
	<entry>
		<id>https://wiki.pxls.space/index.php?title=Module:Infobox_military_conflict&amp;diff=6915</id>
		<title>Module:Infobox military conflict</title>
		<link rel="alternate" type="text/html" href="https://wiki.pxls.space/index.php?title=Module:Infobox_military_conflict&amp;diff=6915"/>
		<updated>2023-03-01T00:31:02Z</updated>

		<summary type="html">&lt;p&gt;Vanilla: https://en.wikipedia.org/w/index.php?title=Module:Infobox_military_conflict&amp;amp;action=edit&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;require(&#039;strict&#039;)&lt;br /&gt;
&lt;br /&gt;
local infoboxStyle = mw.loadData(&#039;Module:WPMILHIST Infobox style&#039;)&lt;br /&gt;
local templatestyles = &#039;Module:Infobox military conflict/styles.css&#039;&lt;br /&gt;
&lt;br /&gt;
local IMC = {}&lt;br /&gt;
IMC.__index = IMC&lt;br /&gt;
&lt;br /&gt;
function IMC:renderPerCombatant(builder, headerText, prefix, suffix)&lt;br /&gt;
	prefix = prefix or &#039;&#039;&lt;br /&gt;
	suffix = suffix or &#039;&#039;&lt;br /&gt;
	local colspans = {}&lt;br /&gt;
	&lt;br /&gt;
	-- This may result in colspans[1] getting set twice, but&lt;br /&gt;
	-- this is no big deal. The second set will be correct.&lt;br /&gt;
	local lastCombatant = 1&lt;br /&gt;
	&lt;br /&gt;
	for i = 1,self.combatants do&lt;br /&gt;
		if self.args[prefix .. i .. suffix] then&lt;br /&gt;
			colspans[lastCombatant] = i - lastCombatant&lt;br /&gt;
			lastCombatant = i&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local jointText = self.args[prefix .. (self.combatants + 1) .. suffix]&lt;br /&gt;
	&lt;br /&gt;
	if headerText and (colspans[1] or jointText) then&lt;br /&gt;
		builder:tag(&#039;tr&#039;)&lt;br /&gt;
			:tag(&#039;th&#039;)&lt;br /&gt;
				:attr(&#039;colspan&#039;, self.combatants)&lt;br /&gt;
				:cssText(infoboxStyle.header_raw)&lt;br /&gt;
				:wikitext(headerText)&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- The only time colspans[1] wouldn&#039;t be set is if no&lt;br /&gt;
	-- combatant has a field with the given prefix and suffix.&lt;br /&gt;
	if colspans[1] then&lt;br /&gt;
		-- Since each found argument set the colspan for the previous&lt;br /&gt;
		-- one, the final one wasn&#039;t set above, so set it now.&lt;br /&gt;
		colspans[lastCombatant] = self.combatants - lastCombatant + 1&lt;br /&gt;
		builder = builder:tag(&#039;tr&#039;)&lt;br /&gt;
		for i = 1,self.combatants do&lt;br /&gt;
			-- At this point, colspans[i] will be set for i=1 unconditionally, and for&lt;br /&gt;
			-- any other value of i where self.args[prefix .. i .. suffix] is set.&lt;br /&gt;
			if colspans[i] then&lt;br /&gt;
				builder:tag(&#039;td&#039;)&lt;br /&gt;
					-- don&#039;t bother emitting colspan=&amp;quot;1&amp;quot;&lt;br /&gt;
					:attr(&#039;colspan&#039;, colspans[i] ~= 1 and colspans[i] or nil)&lt;br /&gt;
					:css(&#039;width&#039;, math.floor(100 / self.combatants * colspans[i] + 0.5) .. &#039;%&#039;)&lt;br /&gt;
					-- no border on the right of the rightmost column&lt;br /&gt;
					:css(&#039;border-right&#039;, i ~= lastCombatant and infoboxStyle.internal_border or nil)&lt;br /&gt;
					-- no padding on the left of the leftmost column&lt;br /&gt;
					:css(&#039;padding-left&#039;, i ~= 1 and &#039;0.25em&#039; or nil)&lt;br /&gt;
					-- don&#039;t show the border if we&#039;re directly under a header&lt;br /&gt;
					:css(&#039;border-top&#039;, not headerText and infoboxStyle.internal_border or nil)&lt;br /&gt;
					:newline()&lt;br /&gt;
					:wikitext(self.args[prefix .. i .. suffix])&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	if jointText then&lt;br /&gt;
		builder:tag(&#039;tr&#039;)&lt;br /&gt;
			:tag(&#039;td&#039;)&lt;br /&gt;
				:attr(&#039;colspan&#039;, self.combatants)&lt;br /&gt;
				:css(&#039;text-align&#039;, &#039;center&#039;)&lt;br /&gt;
				-- don&#039;t show the border if we&#039;re directly under a header&lt;br /&gt;
				:css(&#039;border-top&#039;, (not headerText or colspans[1]) and infoboxStyle.internal_border or nil)&lt;br /&gt;
				:newline()&lt;br /&gt;
				:wikitext(jointText)&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function IMC:renderHeaderTable(builder)&lt;br /&gt;
	builder = builder:tag(&#039;table&#039;)&lt;br /&gt;
		:css(&#039;width&#039;, &#039;100%&#039;)&lt;br /&gt;
		:css(&#039;margin&#039;, 0)&lt;br /&gt;
		:css(&#039;padding&#039;, 0)&lt;br /&gt;
		:css(&#039;border&#039;, 0)&lt;br /&gt;
		:css(&#039;display&#039;, &#039;inline-table&#039;)&lt;br /&gt;
&lt;br /&gt;
	if self.args.date then&lt;br /&gt;
		builder:tag(&#039;tr&#039;)&lt;br /&gt;
			:tag(&#039;th&#039;)&lt;br /&gt;
				:css(&#039;padding-right&#039;, &#039;1em&#039;)&lt;br /&gt;
				:wikitext(&#039;Date&#039;)&lt;br /&gt;
			:done()&lt;br /&gt;
			:tag(&#039;td&#039;)&lt;br /&gt;
				:wikitext(self.args.date)&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	builder = builder:tag(&#039;tr&#039;)&lt;br /&gt;
		:tag(&#039;th&#039;)&lt;br /&gt;
			:css(&#039;padding-right&#039;, &#039;1em&#039;)&lt;br /&gt;
			:wikitext(&#039;Location&#039;)&lt;br /&gt;
		:done()&lt;br /&gt;
		:tag(&#039;td&#039;)&lt;br /&gt;
			:tag(&#039;div&#039;)&lt;br /&gt;
				:addClass(&#039;location&#039;)&lt;br /&gt;
				:wikitext(self.args.place or &#039;{&amp;amp;#123;{place}&amp;amp;#125;}&#039;) -- hack so that people who don&#039;t know Lua know that this parameter is required&lt;br /&gt;
			:done()&lt;br /&gt;
	if self.args.coordinates then&lt;br /&gt;
		builder:wikitext(self.args.coordinates)&lt;br /&gt;
	end&lt;br /&gt;
	builder = builder:done():done()&lt;br /&gt;
&lt;br /&gt;
	-- only for &amp;quot;Putsch&amp;quot;&lt;br /&gt;
    if self.args.action then&lt;br /&gt;
		builder:tag(&#039;tr&#039;)&lt;br /&gt;
			:tag(&#039;th&#039;)&lt;br /&gt;
				:css(&#039;padding-right&#039;, &#039;1em&#039;)&lt;br /&gt;
				:wikitext(self.args.action and &#039;Action&#039;)&lt;br /&gt;
			:done()&lt;br /&gt;
			:tag(&#039;td&#039;)&lt;br /&gt;
				:wikitext(self.args.action)&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	if self.args.status or self.args.result then&lt;br /&gt;
		builder:tag(&#039;tr&#039;)&lt;br /&gt;
			:tag(&#039;th&#039;)&lt;br /&gt;
				:css(&#039;padding-right&#039;, &#039;1em&#039;)&lt;br /&gt;
				:wikitext(self.args.status and &#039;Status&#039; or &#039;Result&#039;)&lt;br /&gt;
			:done()&lt;br /&gt;
			:tag(&#039;td&#039;)&lt;br /&gt;
				:addClass(&#039;status&#039;)&lt;br /&gt;
				:newline()&lt;br /&gt;
				:wikitext(self.args.status or self.args.result)&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	if self.args.territory then&lt;br /&gt;
		builder:tag(&#039;tr&#039;)&lt;br /&gt;
			:tag(&#039;th&#039;)&lt;br /&gt;
				:css(&#039;padding-right&#039;, &#039;1em&#039;)&lt;br /&gt;
				:wikitext(&#039;Territorial&amp;lt;br /&amp;gt;changes&#039;)&lt;br /&gt;
			:done()&lt;br /&gt;
			:tag(&#039;td&#039;)&lt;br /&gt;
				:newline()&lt;br /&gt;
				:wikitext(self.args.territory)&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function IMC:render()&lt;br /&gt;
	local builder = mw.html.create()&lt;br /&gt;
	if self.args.campaignbox then&lt;br /&gt;
		-- this should be the same as using {{stack|clear=right|...}}&lt;br /&gt;
		builder:wikitext(self.frame:expandTemplate{ title = &#039;stack begin&#039;, args = { clear=&#039;true&#039;} })&lt;br /&gt;
	end&lt;br /&gt;
	builder = builder:tag(&#039;table&#039;)&lt;br /&gt;
		:addClass(&#039;infobox vevent&#039;)&lt;br /&gt;
		:cssText(infoboxStyle.main_box_raw)&lt;br /&gt;
		:css(&#039;width&#039;, self.args.width or nil)&lt;br /&gt;
&lt;br /&gt;
	builder:tag(&#039;tr&#039;)&lt;br /&gt;
		:tag(&#039;th&#039;)&lt;br /&gt;
			:addClass(&#039;summary&#039;)&lt;br /&gt;
			:attr(&#039;colspan&#039;, self.combatants)&lt;br /&gt;
			:cssText(infoboxStyle.header_raw)&lt;br /&gt;
			:wikitext(self.args.conflict or mw.title.getCurrentTitle().text)&lt;br /&gt;
	if self.args.partof then&lt;br /&gt;
		builder:tag(&#039;tr&#039;)&lt;br /&gt;
			:tag(&#039;td&#039;)&lt;br /&gt;
				:attr(&#039;colspan&#039;, self.combatants)&lt;br /&gt;
				:cssText(infoboxStyle.sub_header_raw)&lt;br /&gt;
				:wikitext(&#039;Part of &#039; .. self.args.partof)&lt;br /&gt;
	end&lt;br /&gt;
	if self.args.image then&lt;br /&gt;
		builder:tag(&#039;tr&#039;)&lt;br /&gt;
			:tag(&#039;td&#039;)&lt;br /&gt;
				:attr(&#039;colspan&#039;, self.combatants)&lt;br /&gt;
				:cssText(infoboxStyle.image_box_raw)&lt;br /&gt;
				:wikitext(string.format(&#039;%s%s%s&#039;,&lt;br /&gt;
					require(&#039;Module:InfoboxImage&#039;).InfoboxImage{args = {&lt;br /&gt;
						image = self.args.image,&lt;br /&gt;
						size = self.args.image_size,&lt;br /&gt;
						sizedefault = &#039;frameless&#039;,&lt;br /&gt;
						upright = 1,&lt;br /&gt;
						alt = self.args.alt&lt;br /&gt;
					}},&lt;br /&gt;
					self.args.caption and &#039;&amp;lt;br /&amp;gt;&#039; or &#039;&#039;,&lt;br /&gt;
					self.args.caption or &#039;&#039;&lt;br /&gt;
				))&lt;br /&gt;
	end&lt;br /&gt;
	self:renderHeaderTable(builder:tag(&#039;tr&#039;):tag(&#039;td&#039;):attr(&#039;colspan&#039;, self.combatants))&lt;br /&gt;
	self:renderPerCombatant(builder, self.args.combatants_header or &#039;Belligerents&#039;, &#039;combatant&#039;)&lt;br /&gt;
	-- can be un-hardcoded once gerrit:165108 is merged&lt;br /&gt;
	for _,v in ipairs{&#039;a&#039;,&#039;b&#039;,&#039;c&#039;,&#039;d&#039;} do&lt;br /&gt;
		self:renderPerCombatant(builder, nil, &#039;combatant&#039;, v)&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	self:renderPerCombatant(builder, self.args.commanders_header or &#039;Commanders and leaders&#039;, &#039;commander&#039;)&lt;br /&gt;
	for _,v in ipairs{&#039;a&#039;,&#039;b&#039;,&#039;c&#039;,&#039;d&#039;} do&lt;br /&gt;
		self:renderPerCombatant(builder, nil, &#039;commander&#039;, v)&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	self:renderPerCombatant(builder, self.args.units_header or &#039;Units involved&#039;, &#039;units&#039;)&lt;br /&gt;
	self:renderPerCombatant(builder, self.args.strengths_header or &#039;Strength&#039;, &#039;strength&#039;)&lt;br /&gt;
	self:renderPerCombatant(builder, self.args.polstrengths_header or &#039;Political support&#039;, &#039;polstrength&#039;)&lt;br /&gt;
	self:renderPerCombatant(builder, self.args.milstrengths_header or &#039;Military support&#039;, &#039;milstrength&#039;)&lt;br /&gt;
	self:renderPerCombatant(builder, self.args.casualties_header or &#039;Casualties and losses&#039;, &#039;casualties&#039;)&lt;br /&gt;
&lt;br /&gt;
	if self.args.notes then&lt;br /&gt;
		builder:tag(&#039;tr&#039;)&lt;br /&gt;
			:tag(&#039;td&#039;)&lt;br /&gt;
				:attr(&#039;colspan&#039;, self.combatants)&lt;br /&gt;
				:css(&#039;border-top&#039;, infoboxStyle.section_border)&lt;br /&gt;
				:newline()&lt;br /&gt;
				:wikitext(self.args.notes)&lt;br /&gt;
	end&lt;br /&gt;
	if self.args.map_type then&lt;br /&gt;
		builder:tag(&#039;tr&#039;)&lt;br /&gt;
			:tag(&#039;td&#039;)&lt;br /&gt;
				:attr(&#039;colspan&#039;, self.combatants)&lt;br /&gt;
				:css(&#039;border-top&#039;, infoboxStyle.internal_border)&lt;br /&gt;
				:node(require(&#039;Module:Location map&#039;).main(self.frame, {&lt;br /&gt;
					self.args.map_type,&lt;br /&gt;
					relief = self.args.map_relief,&lt;br /&gt;
					coordinates = self.args.coordinates,&lt;br /&gt;
					width = self.args.map_size or 220,&lt;br /&gt;
					float = &#039;center&#039;,&lt;br /&gt;
					border = &#039;none&#039;,&lt;br /&gt;
					mark = self.args.map_mark,&lt;br /&gt;
					marksize = self.args.map_marksize or 8,&lt;br /&gt;
					label = self.args.map_label,&lt;br /&gt;
					alt = self.args.map_alt,&lt;br /&gt;
					caption = self.args.map_caption or (&#039;Location within &#039; &lt;br /&gt;
						.. (require(&#039;Module:Location map&#039;).data(self.frame, {self.args.map_type, &#039;name&#039;})))&lt;br /&gt;
				}))&lt;br /&gt;
	end&lt;br /&gt;
	builder = builder:done()&lt;br /&gt;
	if self.args.campaignbox then&lt;br /&gt;
		builder = builder:done()&lt;br /&gt;
		builder:wikitext(self.args.campaignbox .. self.frame:expandTemplate{ title = &#039;stack end&#039;})&lt;br /&gt;
	end&lt;br /&gt;
	return builder&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function IMC.new(frame, args)&lt;br /&gt;
	if not args then&lt;br /&gt;
		args = require(&#039;Module:Arguments&#039;).getArgs(frame, {wrappers = &#039;Template:Infobox military conflict&#039;})&lt;br /&gt;
	end&lt;br /&gt;
	local obj = {&lt;br /&gt;
		frame = frame,&lt;br /&gt;
		args = args&lt;br /&gt;
	}&lt;br /&gt;
&lt;br /&gt;
	-- until gerrit:165108 is merged, there&#039;s still a cap on combatants, but as soon as it merges, we can update this little bit of code to uncap it&lt;br /&gt;
	-- also, don&#039;t try to make this more efficient, or references could be in the wrong order&lt;br /&gt;
	obj.combatants = 2&lt;br /&gt;
	for _,v in ipairs{&#039;&#039;, &#039;a&#039;, &#039;b&#039;, &#039;c&#039;, &#039;d&#039;} do&lt;br /&gt;
		for i = 1,5 do&lt;br /&gt;
			if args[&#039;combatant&#039; .. i .. v] then&lt;br /&gt;
				obj.combatants = math.max(obj.combatants, i)&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	return setmetatable(obj, IMC)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
local p = {}&lt;br /&gt;
&lt;br /&gt;
function p.main(frame)&lt;br /&gt;
	return frame:extensionTag{ name = &#039;templatestyles&#039;, args = { src = templatestyles} } .. tostring(IMC.new(frame):render())&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
return p&lt;/div&gt;</summary>
		<author><name>Vanilla</name></author>
	</entry>
</feed>