<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en-GB">
	<id>https://stockhub.co/index.php?action=history&amp;feed=atom&amp;title=Module%3ASandbox%2FAbjiklam%2Fsandbox</id>
	<title>Module:Sandbox/Abjiklam/sandbox - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://stockhub.co/index.php?action=history&amp;feed=atom&amp;title=Module%3ASandbox%2FAbjiklam%2Fsandbox"/>
	<link rel="alternate" type="text/html" href="https://stockhub.co/index.php?title=Module:Sandbox/Abjiklam/sandbox&amp;action=history"/>
	<updated>2026-04-17T18:47:23Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.43.5</generator>
	<entry>
		<id>https://stockhub.co/index.php?title=Module:Sandbox/Abjiklam/sandbox&amp;diff=145024&amp;oldid=prev</id>
		<title>imported&gt;Χ at 13:50, 10 July 2018</title>
		<link rel="alternate" type="text/html" href="https://stockhub.co/index.php?title=Module:Sandbox/Abjiklam/sandbox&amp;diff=145024&amp;oldid=prev"/>
		<updated>2018-07-10T13:50:18Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;local p = {}&lt;br /&gt;
&lt;br /&gt;
local infobox = require(&amp;#039;Module:Infobox&amp;#039;).infobox&lt;br /&gt;
local infobox_image = require(&amp;#039;Module:InfoboxImage&amp;#039;).InfoboxImage&lt;br /&gt;
local br = require(&amp;#039;Module:Separated entries&amp;#039;).br&lt;br /&gt;
&lt;br /&gt;
-- Add a book or category in the order it should appear in the infobox.&lt;br /&gt;
-- The first element of each section is the section name.&lt;br /&gt;
local books = {&lt;br /&gt;
	asoiaf = {&lt;br /&gt;
		&amp;quot;A Song of Ice and Fire&amp;quot;,&lt;br /&gt;
		agot = &amp;quot;A Game of Thrones&amp;quot;,&lt;br /&gt;
		acok = &amp;quot;A Clash of Kings&amp;quot;,&lt;br /&gt;
		asos = &amp;quot;A Storm of Swords&amp;quot;,&lt;br /&gt;
		affc = &amp;quot;A Feast for Crows&amp;quot;,&lt;br /&gt;
		adwd = &amp;quot;A Dance with Dragon&amp;quot;,&lt;br /&gt;
		twow = &amp;quot;The Winds of Winter&amp;quot;,&lt;br /&gt;
		ados = &amp;quot;A Dream of Spring&amp;quot;,&lt;br /&gt;
	},&lt;br /&gt;
	todae = {&lt;br /&gt;
		&amp;quot;Tales of Dunk and Egg&amp;quot;,&lt;br /&gt;
		thk = &amp;quot;The Hedge Knight&amp;quot;,&lt;br /&gt;
		tss = &amp;quot;The Sworn Sword&amp;quot;,&lt;br /&gt;
		tmk = &amp;quot;The Mystery Knight&amp;quot;,&lt;br /&gt;
	},&lt;br /&gt;
	other = {&lt;br /&gt;
		&amp;quot;Other Books&amp;quot;,&lt;br /&gt;
		twoiaf = &amp;quot;The World of Ice and Fire&amp;quot;,&lt;br /&gt;
		fab    = &amp;quot;Fire and Blood&amp;quot;,&lt;br /&gt;
		tpatq  = &amp;quot;The Princess and the Queen&amp;quot;,&lt;br /&gt;
		trp    = &amp;quot;The Rogue Prince&amp;quot;,&lt;br /&gt;
		tsotd  = &amp;quot;The Sons of the Dragon&amp;quot;,&lt;br /&gt;
	},&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
local function generate_arms(arms)&lt;br /&gt;
	--This function generates small coat of arms icons&lt;br /&gt;
	return infobox_image({&lt;br /&gt;
		args = {&lt;br /&gt;
			image  = arms,&lt;br /&gt;
			size   = &amp;#039;50x70px&amp;#039;,&lt;br /&gt;
			border = &amp;#039;no&amp;#039;,&lt;br /&gt;
			suppressplaceholder = &amp;#039;yes&amp;#039;,&lt;br /&gt;
		}&lt;br /&gt;
	})&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function p.main(frame)&lt;br /&gt;
	-- The main function cleans up and formats all the arguments before&lt;br /&gt;
	-- passing them to the Infobox module.&lt;br /&gt;
	&lt;br /&gt;
	local original_arguments = frame.args -- arguments passed to this module&lt;br /&gt;
	local infobox_arguments = {} -- arguments given to the Infobox module&lt;br /&gt;
	&lt;br /&gt;
	------&lt;br /&gt;
    -- above (arms+name)&lt;br /&gt;
    ------&lt;br /&gt;
    local above&lt;br /&gt;
    &lt;br /&gt;
    -- name&lt;br /&gt;
    local honorific_prefix = &amp;quot;&amp;quot;&lt;br /&gt;
    local honorific_suffix = &amp;quot;&amp;quot;&lt;br /&gt;
    if original_arguments.honorific_prefix and original_arguments.honorific_prefix ~= &amp;quot;&amp;quot; then&lt;br /&gt;
    	honorific_prefix = mw.html.create(&amp;#039;span&amp;#039;)&lt;br /&gt;
    	honorific_prefix:css(&amp;#039;font-size&amp;#039;, &amp;#039;80%&amp;#039;)&lt;br /&gt;
	    				:css(&amp;#039;font-weight&amp;#039;, &amp;#039;normal&amp;#039;)&lt;br /&gt;
	    				:wikitext(original_arguments.honorific_prefix)&lt;br /&gt;
	end&lt;br /&gt;
    if original_arguments.honorific_suffix and original_arguments.honorific_suffix ~= &amp;quot;&amp;quot; then&lt;br /&gt;
    	honorific_suffix = mw.html.create(&amp;#039;span&amp;#039;)&lt;br /&gt;
    	honorific_suffix:css(&amp;#039;font-size&amp;#039;, &amp;#039;80%&amp;#039;)&lt;br /&gt;
	    				:css(&amp;#039;font-weight&amp;#039;, &amp;#039;normal&amp;#039;)&lt;br /&gt;
	    				:wikitext(original_arguments.honorific_suffix)&lt;br /&gt;
	end&lt;br /&gt;
    local name = br({&lt;br /&gt;
		tostring(honorific_prefix),&lt;br /&gt;
		original_arguments.name,&lt;br /&gt;
		tostring(honorific_suffix),&lt;br /&gt;
	})&lt;br /&gt;
&lt;br /&gt;
    -- arms&lt;br /&gt;
    -- more than 2 arms&lt;br /&gt;
    if original_arguments[&amp;#039;arms3&amp;#039;] then&lt;br /&gt;
    	above = mw.html.create(&amp;#039;div&amp;#039;)&lt;br /&gt;
    	local coats_of_arms = above:tag(&amp;#039;div&amp;#039;)&lt;br /&gt;
    	coats_of_arms:css(&amp;#039;text-align&amp;#039;, &amp;#039;justify&amp;#039;)&lt;br /&gt;
    				 :css(&amp;#039;text-justify&amp;#039;, &amp;#039;distribute-all-lines&amp;#039;)&lt;br /&gt;
    				 :css(&amp;#039;margin-bottom&amp;#039;, &amp;#039;-1em&amp;#039;)&lt;br /&gt;
    	for i=1,5 do&lt;br /&gt;
    		local arms&lt;br /&gt;
    		if i ~= 1 then&lt;br /&gt;
    			arms = original_arguments[&amp;#039;arms&amp;#039; .. tostring(i)]&lt;br /&gt;
    		elseif original_arguments[&amp;#039;arms1&amp;#039;] then&lt;br /&gt;
    			arms = original_arguments[&amp;#039;arms&amp;#039; .. tostring(1)]&lt;br /&gt;
			else&lt;br /&gt;
    			arms = original_arguments[&amp;#039;arms&amp;#039;]&lt;br /&gt;
    		end&lt;br /&gt;
    		if arms then&lt;br /&gt;
    			coats_of_arms:wikitext(generate_arms(arms))&lt;br /&gt;
    			coats_of_arms:wikitext(&amp;quot; &amp;quot;)&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
		coats_of_arms:tag(&amp;#039;span&amp;#039;)&lt;br /&gt;
					 :css(&amp;#039;display&amp;#039;, &amp;#039;inline-block&amp;#039;)&lt;br /&gt;
					 :css(&amp;#039;width&amp;#039;, &amp;#039;100%&amp;#039;)&lt;br /&gt;
					 :css(&amp;#039;height&amp;#039;, &amp;#039;0&amp;#039;)&lt;br /&gt;
		above:wikitext(name)&lt;br /&gt;
	-- 1 or 2 arms&lt;br /&gt;
	elseif original_arguments[&amp;#039;arms&amp;#039;] or original_arguments[&amp;#039;arms1&amp;#039;] then&lt;br /&gt;
		above = mw.html.create(&amp;#039;table&amp;#039;)&lt;br /&gt;
		above:css(&amp;#039;width&amp;#039;, &amp;#039;100%&amp;#039;)&lt;br /&gt;
		above_row = above:tag(&amp;#039;tr&amp;#039;)&lt;br /&gt;
		local arms1, arms2&lt;br /&gt;
		if original_arguments[&amp;#039;arms1&amp;#039;] then&lt;br /&gt;
			arms1 = original_arguments[&amp;#039;arms1&amp;#039;]&lt;br /&gt;
		else&lt;br /&gt;
			arms1 = original_arguments[&amp;#039;arms&amp;#039;]&lt;br /&gt;
		end&lt;br /&gt;
		if original_arguments[&amp;#039;arms2&amp;#039;] then&lt;br /&gt;
			arms2 = original_arguments[&amp;#039;arms2&amp;#039;]&lt;br /&gt;
		else&lt;br /&gt;
			arms2 = arms1&lt;br /&gt;
		end&lt;br /&gt;
		above_row:tag(&amp;#039;td&amp;#039;)&lt;br /&gt;
				 :css(&amp;#039;vertical-align&amp;#039;, &amp;#039;top&amp;#039;)&lt;br /&gt;
				 :css(&amp;#039;text-align&amp;#039;, &amp;#039;left&amp;#039;)&lt;br /&gt;
				 :css(&amp;#039;width&amp;#039;, &amp;#039;50px&amp;#039;)&lt;br /&gt;
				 :wikitext(generate_arms(arms1))&lt;br /&gt;
		above_row:tag(&amp;#039;td&amp;#039;)&lt;br /&gt;
				 :css(&amp;#039;vertical-align&amp;#039;, &amp;#039;middle&amp;#039;)&lt;br /&gt;
				 :css(&amp;#039;text-align&amp;#039;, &amp;#039;center&amp;#039;)&lt;br /&gt;
				 :css(&amp;#039;padding-bottom&amp;#039;, &amp;#039;5px&amp;#039;)&lt;br /&gt;
				 :wikitext(name)&lt;br /&gt;
		above_row:tag(&amp;#039;td&amp;#039;)&lt;br /&gt;
				 :css(&amp;#039;vertical-align&amp;#039;, &amp;#039;top&amp;#039;)&lt;br /&gt;
				 :css(&amp;#039;text-align&amp;#039;, &amp;#039;right&amp;#039;)&lt;br /&gt;
				 :css(&amp;#039;width&amp;#039;, &amp;#039;50px&amp;#039;)&lt;br /&gt;
				 :wikitext(generate_arms(arms2))&lt;br /&gt;
	-- no arms&lt;br /&gt;
	else&lt;br /&gt;
		above = name&lt;br /&gt;
	end&lt;br /&gt;
    infobox_arguments.above = tostring(above)&lt;br /&gt;
    &lt;br /&gt;
    ------&lt;br /&gt;
    -- image, caption and copyright&lt;br /&gt;
    ------&lt;br /&gt;
    infobox_arguments.image = infobox_image({&lt;br /&gt;
		args = {&lt;br /&gt;
			image   = original_arguments.image,&lt;br /&gt;
			size    = original_arguments.image_size,&lt;br /&gt;
			maxsize = &amp;#039;300px&amp;#039;,&lt;br /&gt;
			sizedefault = &amp;#039;frameless&amp;#039;,&lt;br /&gt;
			alt     = original_arguments.alt,&lt;br /&gt;
			border  = &amp;#039;yes&amp;#039;,&lt;br /&gt;
			suppressplaceholder = &amp;#039;yes&amp;#039;,&lt;br /&gt;
		}&lt;br /&gt;
    })&lt;br /&gt;
    &lt;br /&gt;
    infobox_arguments.headerstyle = &amp;quot;background-color:#f8e9d0;border:none;&amp;quot;&lt;br /&gt;
    return infobox(infobox_arguments)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
return p&lt;/div&gt;</summary>
		<author><name>imported&gt;Χ</name></author>
	</entry>
</feed>