<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
		<id>https://wiki.agency/index.php?action=history&amp;feed=atom&amp;title=Module%3AIndent</id>
		<title>Module:Indent - Revision history</title>
		<link rel="self" type="application/atom+xml" href="https://wiki.agency/index.php?action=history&amp;feed=atom&amp;title=Module%3AIndent"/>
		<link rel="alternate" type="text/html" href="https://wiki.agency/index.php?title=Module:Indent&amp;action=history"/>
		<updated>2026-04-28T06:30:48Z</updated>
		<subtitle>Revision history for this page on the wiki</subtitle>
		<generator>MediaWiki 1.30.1</generator>

	<entry>
		<id>https://wiki.agency/index.php?title=Module:Indent&amp;diff=10396&amp;oldid=prev</id>
		<title>Admin: 1 revision imported</title>
		<link rel="alternate" type="text/html" href="https://wiki.agency/index.php?title=Module:Indent&amp;diff=10396&amp;oldid=prev"/>
				<updated>2018-11-08T15:45:51Z</updated>
		
		<summary type="html">&lt;p&gt;1 revision imported&lt;/p&gt;
&lt;table class=&quot;diff diff-contentalign-left&quot; data-mw=&quot;interface&quot;&gt;
				&lt;tr style=&quot;vertical-align: top;&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;1&quot; style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;1&quot; style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;Revision as of 15:45, 8 November 2018&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; style=&quot;text-align: center;&quot; lang=&quot;en&quot;&gt;&lt;div class=&quot;mw-diff-empty&quot;&gt;(No difference)&lt;/div&gt;
&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;</summary>
		<author><name>Admin</name></author>	</entry>

	<entry>
		<id>https://wiki.agency/index.php?title=Module:Indent&amp;diff=10395&amp;oldid=prev</id>
		<title>Mr. Stradivarius: Protected Module:Indent: High-risk Lua module: in line with template protection level ([Edit=Allow only autoconfirmed users] (indefinite) [Move=Allow only autoconfirmed users] (indefinite))</title>
		<link rel="alternate" type="text/html" href="https://wiki.agency/index.php?title=Module:Indent&amp;diff=10395&amp;oldid=prev"/>
				<updated>2013-06-27T10:03:59Z</updated>
		
		<summary type="html">&lt;p&gt;Protected Module:Indent: &lt;a href=&quot;https://en.wikipedia.org/wiki/Lua/Modules&quot; class=&quot;extiw&quot; title=&quot;wikipedia:Lua/Modules&quot;&gt;High-risk Lua module&lt;/a&gt;: in line with template protection level ([Edit=Allow only autoconfirmed users] (indefinite) [Move=Allow only autoconfirmed users] (indefinite))&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;
function p.indent(frame)&lt;br /&gt;
    -- Trim whitespace from the arguments and remove blank values.&lt;br /&gt;
    local args = {}&lt;br /&gt;
    if type(frame.args) == &amp;#039;table&amp;#039; then&lt;br /&gt;
        for k, v in pairs( frame.args ) do&lt;br /&gt;
            v = mw.text.trim(v)&lt;br /&gt;
            if v ~= &amp;#039;&amp;#039; then&lt;br /&gt;
                args[k] = v&lt;br /&gt;
            end&lt;br /&gt;
        end&lt;br /&gt;
    end&lt;br /&gt;
    &lt;br /&gt;
    -- Set variables.&lt;br /&gt;
    local indent = tonumber( args[1] )&lt;br /&gt;
    local br = args[2]&lt;br /&gt;
    local ret = &amp;#039;&amp;#039;&lt;br /&gt;
    &lt;br /&gt;
    -- Insert line breaks to match the functionality of the original template.&lt;br /&gt;
    -- If &amp;quot;br&amp;quot; is set, we need two line breaks; if not, we just need one.&lt;br /&gt;
    if br then&lt;br /&gt;
        ret = ret .. &amp;#039;&amp;lt;br /&amp;gt;&amp;#039; &lt;br /&gt;
    end&lt;br /&gt;
    ret = ret .. &amp;#039;&amp;lt;br /&amp;gt;&amp;#039;&lt;br /&gt;
    &lt;br /&gt;
    -- Control for bad or zero input. If found, output the line breaks only, &lt;br /&gt;
    -- as this was the previous behaviour of the template.&lt;br /&gt;
    if not indent or indent &amp;lt;= 0 or math.floor(indent) ~= indent then&lt;br /&gt;
        return ret&lt;br /&gt;
    end&lt;br /&gt;
    &lt;br /&gt;
    -- Generate the indents. The first four cases are special.&lt;br /&gt;
    if indent == 1 then&lt;br /&gt;
        return ret .. &amp;#039;&amp;amp;nbsp;&amp;#039;&lt;br /&gt;
    elseif indent == 2 then&lt;br /&gt;
        return ret .. &amp;#039;&amp;amp;nbsp;&amp;amp;nbsp;&amp;#039;&lt;br /&gt;
    elseif indent == 3 then&lt;br /&gt;
        return ret .. &amp;#039;&amp;amp;nbsp;&amp;amp;emsp;&amp;amp;nbsp;&amp;#039;&lt;br /&gt;
    elseif indent == 4 then&lt;br /&gt;
        return ret .. &amp;#039;&amp;amp;nbsp; &amp;amp;emsp; &amp;amp;nbsp;&amp;#039;&lt;br /&gt;
    end&lt;br /&gt;
    &lt;br /&gt;
    -- Set variables for generating the output after indent == 5.&lt;br /&gt;
    local r = {}&lt;br /&gt;
    r.base = &amp;#039;&amp;amp;nbsp;&amp;#039; -- Common text to all output.&lt;br /&gt;
    r.rep = &amp;#039; &amp;amp;emsp; &amp;amp;nbsp;&amp;#039; -- The text to repeat.&lt;br /&gt;
    r.mod1 = &amp;#039;&amp;amp;nbsp;&amp;#039; -- To return on modulo 1.&lt;br /&gt;
    r.mod2 = &amp;#039; &amp;amp;emsp;&amp;#039; -- To return on modulo 2.&lt;br /&gt;
    r.mod3 = &amp;#039; &amp;amp;emsp;&amp;amp;nbsp;&amp;#039; -- To return on modulo 3.&lt;br /&gt;
    &lt;br /&gt;
    -- New iteratorText values needed at 5, 9, 13, 17, etc., so repeat the&lt;br /&gt;
    -- text (indent - 1)/4 times and find the remainder.&lt;br /&gt;
    local reps = math.floor( (indent - 1) / 4 )&lt;br /&gt;
    local remainder = math.fmod( indent - 1, 4 )&lt;br /&gt;
    &lt;br /&gt;
    -- Generate the indent text.&lt;br /&gt;
    ret = ret .. r.base .. mw.ustring.rep( r.rep, reps )&lt;br /&gt;
    if remainder &amp;gt;= 1 and remainder &amp;lt;= 3 then&lt;br /&gt;
        ret = ret .. r[ &amp;#039;mod&amp;#039; .. remainder ]&lt;br /&gt;
    end&lt;br /&gt;
    &lt;br /&gt;
    return ret&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
return p&lt;/div&gt;</summary>
		<author><name>Mr. Stradivarius</name></author>	</entry>

	</feed>