<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en-GB">
	<id>https://wiki.shroudforge.net/index.php?action=history&amp;feed=atom&amp;title=Module%3ADocumentation</id>
	<title>Module:Documentation - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.shroudforge.net/index.php?action=history&amp;feed=atom&amp;title=Module%3ADocumentation"/>
	<link rel="alternate" type="text/html" href="https://wiki.shroudforge.net/index.php?title=Module:Documentation&amp;action=history"/>
	<updated>2026-11-05T05:27:14Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.46.2</generator>
	<entry>
		<id>https://wiki.shroudforge.net/index.php?title=Module:Documentation&amp;diff=76&amp;oldid=prev</id>
		<title>Bonsaibauer: 1 revision imported: Import Star Citizen Modules</title>
		<link rel="alternate" type="text/html" href="https://wiki.shroudforge.net/index.php?title=Module:Documentation&amp;diff=76&amp;oldid=prev"/>
		<updated>2026-11-04T22:22:06Z</updated>

		<summary type="html">&lt;p&gt;1 revision imported: Import Star Citizen Modules&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw-interface=&quot;&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en-GB&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 22:22, 4 November 2026&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;4&quot; class=&quot;diff-notice&quot; lang=&quot;en-GB&quot;&gt;&lt;div class=&quot;mw-diff-empty&quot;&gt;(No difference)&lt;/div&gt;
&lt;/td&gt;&lt;/tr&gt;
&lt;!-- diff cache key mediawiki-mediawiki:diff:1.41:old-75:rev-76 --&gt;
&lt;/table&gt;</summary>
		<author><name>Bonsaibauer</name></author>
	</entry>
	<entry>
		<id>https://wiki.shroudforge.net/index.php?title=Module:Documentation&amp;diff=75&amp;oldid=prev</id>
		<title>starcitizen&gt;Alistar Bot: Sync from Git (documentation-review-fixes 237177e) (via update-page on MediaWiki MCP Server)</title>
		<link rel="alternate" type="text/html" href="https://wiki.shroudforge.net/index.php?title=Module:Documentation&amp;diff=75&amp;oldid=prev"/>
		<updated>2026-09-28T17:57:52Z</updated>

		<summary type="html">&lt;p&gt;Sync from Git (documentation-review-fixes 237177e) (via update-page on MediaWiki MCP Server)&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;require(&amp;#039;strict&amp;#039;)&lt;br /&gt;
&lt;br /&gt;
--- @module Documentation&lt;br /&gt;
--- The documentation header on module and template pages and on their /doc&lt;br /&gt;
--- subpages, followed by the Technical details panel. Template:Documentation&lt;br /&gt;
--- invokes doc() at the top of each /doc page.&lt;br /&gt;
&lt;br /&gt;
-- &amp;lt;nowiki&amp;gt;&lt;br /&gt;
local button = require(&amp;#039;Module:ButtonLua&amp;#039;)&lt;br /&gt;
local hatnote = require(&amp;#039;Module:Hatnote&amp;#039;)._hatnote&lt;br /&gt;
local icon = require(&amp;#039;Module:Icon&amp;#039;)&lt;br /&gt;
local yesno = require(&amp;#039;Module:Yesno&amp;#039;)&lt;br /&gt;
&lt;br /&gt;
local p = {}&lt;br /&gt;
&lt;br /&gt;
local NS_TEMPLATE = 10&lt;br /&gt;
local NS_MODULE = 828&lt;br /&gt;
local REPO_URL = &amp;#039;https://github.com/StarCitizenTools/wiki-tools/tree/main/pages/&amp;#039;&lt;br /&gt;
local WIKIPEDIA_URL = &amp;#039;https://en.wikipedia.org/wiki/&amp;#039;&lt;br /&gt;
local ICONS = {&lt;br /&gt;
	page = &amp;#039;CdxIconBook.svg&amp;#039;,&lt;br /&gt;
	edit = &amp;#039;CdxIconEdit.svg&amp;#039;,&lt;br /&gt;
	history = &amp;#039;CdxIconHistory.svg&amp;#039;,&lt;br /&gt;
	purge = &amp;#039;CdxIconReload.svg&amp;#039;,&lt;br /&gt;
	back = &amp;#039;CdxIconArrowPrevious.svg&amp;#039;,&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
--- @param value string|nil a {{Documentation}} flag such as `git=`&lt;br /&gt;
--- @return boolean&lt;br /&gt;
local function isOn(value)&lt;br /&gt;
	return yesno(value) == true&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
--- The visible text of a wikitext link, for the panel&amp;#039;s plain-text facts.&lt;br /&gt;
--- @param wikitext string&lt;br /&gt;
--- @return string&lt;br /&gt;
local function linkText(wikitext)&lt;br /&gt;
	return wikitext:match(&amp;#039;^%s*%[%[[^|%]]*|(.-)%]%]%s*$&amp;#039;)&lt;br /&gt;
		or wikitext:match(&amp;#039;^%s*%[%[(.-)%]%]%s*$&amp;#039;)&lt;br /&gt;
		or wikitext:match(&amp;#039;^%s*%[%S+%s+(.-)%]%s*$&amp;#039;)&lt;br /&gt;
		or wikitext&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
--- Where the page was imported from, as a wikitext link: `importedFrom=`, or&lt;br /&gt;
--- its `fromWikipedia=` shorthand for the same title on the English Wikipedia.&lt;br /&gt;
--- @param args table the {{Documentation}} arguments&lt;br /&gt;
--- @param page string the documented page&lt;br /&gt;
--- @return string|nil&lt;br /&gt;
local function importOrigin(args, page)&lt;br /&gt;
	if args.importedFrom and args.importedFrom ~= &amp;#039;&amp;#039; then&lt;br /&gt;
		return args.importedFrom&lt;br /&gt;
	end&lt;br /&gt;
	if isOn(args.fromWikipedia) then&lt;br /&gt;
		return &amp;#039;[&amp;#039; .. WIKIPEDIA_URL .. mw.uri.encode(page, &amp;#039;WIKI&amp;#039;) .. &amp;#039; Wikipedia]&amp;#039;&lt;br /&gt;
	end&lt;br /&gt;
	return nil&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
--- The Source row lines of the Technical details panel: where the page is&lt;br /&gt;
--- maintained (`git=`) and where it came from.&lt;br /&gt;
--- @param args table the {{Documentation}} arguments&lt;br /&gt;
--- @param kind string &amp;#039;module&amp;#039; or &amp;#039;template&amp;#039;&lt;br /&gt;
--- @param rootText string&lt;br /&gt;
--- @param page string the documented page&lt;br /&gt;
--- @return table[] DependenciesSource[]&lt;br /&gt;
local function sources(args, kind, rootText, page)&lt;br /&gt;
	local list = {}&lt;br /&gt;
	if isOn(args.git) then&lt;br /&gt;
		local url = REPO_URL .. kind .. &amp;#039;/&amp;#039; .. mw.uri.encode(rootText, &amp;#039;PATH&amp;#039;)&lt;br /&gt;
		list[#list + 1] = { label = &amp;#039;wiki-tools&amp;#039;, text = &amp;#039;Synced with [&amp;#039; .. url .. &amp;#039; wiki-tools] on GitHub&amp;#039; }&lt;br /&gt;
	end&lt;br /&gt;
	local origin = importOrigin(args, page)&lt;br /&gt;
	if origin then&lt;br /&gt;
		-- The label goes in the panel&amp;#039;s &amp;lt;summary&amp;gt;, which must hold no link: a bare URL would autolink.&lt;br /&gt;
		list[#list + 1] = { label = &amp;#039;from &amp;#039; .. mw.text.nowiki(linkText(origin)), text = &amp;#039;Imported from &amp;#039; .. origin }&lt;br /&gt;
	end&lt;br /&gt;
	return list&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
--- @param kind string &amp;#039;module&amp;#039; or &amp;#039;template&amp;#039;&lt;br /&gt;
--- @param onDoc boolean the render is the /doc subpage itself&lt;br /&gt;
--- @param baseText string the /doc page&amp;#039;s base page name, its sort key&lt;br /&gt;
--- @param imported boolean&lt;br /&gt;
--- @return string&lt;br /&gt;
local function categories(kind, onDoc, baseText, imported)&lt;br /&gt;
	local plural = kind == &amp;#039;module&amp;#039; and &amp;#039;Modules&amp;#039; or &amp;#039;Templates&amp;#039;&lt;br /&gt;
	if onDoc then&lt;br /&gt;
		return &amp;#039;[[Category:&amp;#039; .. plural .. &amp;#039; documentation|&amp;#039; .. baseText .. &amp;#039;]]&amp;#039;&lt;br /&gt;
	end&lt;br /&gt;
	local out = {}&lt;br /&gt;
	if kind == &amp;#039;module&amp;#039; then&lt;br /&gt;
		out[#out + 1] = &amp;#039;[[Category:Modules]]&amp;#039;&lt;br /&gt;
	end&lt;br /&gt;
	if imported then&lt;br /&gt;
		out[#out + 1] = &amp;#039;[[Category:Imported &amp;#039; .. plural:lower() .. &amp;#039;]]&amp;#039;&lt;br /&gt;
	end&lt;br /&gt;
	return table.concat(out)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
--- A quiet icon-only header button. ButtonLua names it with aria-label; the&lt;br /&gt;
--- wrapper is what the phone layout stretches.&lt;br /&gt;
--- @param props table ButtonProps: label, icon and link&lt;br /&gt;
--- @return string&lt;br /&gt;
local function action(props)&lt;br /&gt;
	props.weight = &amp;#039;quiet&amp;#039;&lt;br /&gt;
	props.iconOnly = true&lt;br /&gt;
	return tostring(mw.html.create(&amp;#039;span&amp;#039;):addClass(&amp;#039;t-documentation__action&amp;#039;):wikitext(button.render(props)))&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
--- @param title string&lt;br /&gt;
--- @param subtitle string wikitext&lt;br /&gt;
--- @param actions string[]&lt;br /&gt;
--- @return string&lt;br /&gt;
local function header(title, subtitle, actions)&lt;br /&gt;
	local root = mw.html.create(&amp;#039;div&amp;#039;):addClass(&amp;#039;t-documentation__header&amp;#039;)&lt;br /&gt;
	root:tag(&amp;#039;span&amp;#039;)&lt;br /&gt;
		:addClass(&amp;#039;t-documentation__icon&amp;#039;)&lt;br /&gt;
		:wikitext(icon.render({ icon = ICONS.page, mask = true, size = &amp;#039;1.125rem&amp;#039; }))&lt;br /&gt;
	local heading = root:tag(&amp;#039;div&amp;#039;):addClass(&amp;#039;t-documentation__heading&amp;#039;)&lt;br /&gt;
	heading&lt;br /&gt;
		:tag(&amp;#039;div&amp;#039;)&lt;br /&gt;
		:addClass(&amp;#039;t-documentation__title&amp;#039;)&lt;br /&gt;
		:attr(&amp;#039;role&amp;#039;, &amp;#039;heading&amp;#039;)&lt;br /&gt;
		:attr(&amp;#039;aria-level&amp;#039;, &amp;#039;2&amp;#039;)&lt;br /&gt;
		:wikitext(title)&lt;br /&gt;
	heading:tag(&amp;#039;div&amp;#039;):addClass(&amp;#039;t-documentation__subtitle&amp;#039;):wikitext(subtitle)&lt;br /&gt;
	root:tag(&amp;#039;div&amp;#039;):addClass(&amp;#039;t-documentation__actions&amp;#039;):wikitext(table.concat(actions))&lt;br /&gt;
	return tostring(root)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
--- A failure in Module:Dependencies, or a module it requires, must not break&lt;br /&gt;
--- every documentation page: require and render it inside a pcall.&lt;br /&gt;
--- @param options table DependenciesPanelOptions&lt;br /&gt;
--- @return string&lt;br /&gt;
local function technicalDetails(options)&lt;br /&gt;
	local ok, result = pcall(function()&lt;br /&gt;
		return require(&amp;#039;Module:Dependencies&amp;#039;).panel(options)&lt;br /&gt;
	end)&lt;br /&gt;
	if ok then&lt;br /&gt;
		return result&lt;br /&gt;
	end&lt;br /&gt;
	return &amp;#039;&amp;lt;strong class=&amp;quot;error&amp;quot;&amp;gt;&amp;#039; .. mw.text.nowiki(tostring(result)) .. &amp;#039;&amp;lt;/strong&amp;gt;&amp;#039;&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
--- `{{#invoke:Documentation|doc}}`, from Template:Documentation.&lt;br /&gt;
--- @param frame table&lt;br /&gt;
--- @return string&lt;br /&gt;
function p.doc(frame)&lt;br /&gt;
	local title = mw.title.getCurrentTitle()&lt;br /&gt;
	local args = frame:getParent().args&lt;br /&gt;
	local page = args[1]&lt;br /&gt;
	if page == nil or page == &amp;#039;&amp;#039; then&lt;br /&gt;
		page = title.fullText:gsub(&amp;#039;/[Dd]o[ck]u?$&amp;#039;, &amp;#039;&amp;#039;)&lt;br /&gt;
	end&lt;br /&gt;
	local kind = title.namespace == NS_MODULE and &amp;#039;module&amp;#039; or &amp;#039;template&amp;#039;&lt;br /&gt;
	local onDoc = title.subpageText == &amp;#039;doc&amp;#039;&lt;br /&gt;
&lt;br /&gt;
	-- Left open on purpose: {{Documentation}} sits at the top of the /doc page,&lt;br /&gt;
	-- and the wrapper holds the rest of it until the parser closes it at the end.&lt;br /&gt;
	local out = { &amp;#039;&amp;lt;div class=&amp;quot;t-documentation&amp;#039; .. (isOn(args.git) and &amp;#039; t-documentation--git&amp;#039; or &amp;#039;&amp;#039;) .. &amp;#039;&amp;quot;&amp;gt;&amp;#039; }&lt;br /&gt;
	out[#out + 1] = frame:extensionTag({ name = &amp;#039;templatestyles&amp;#039;, args = { src = &amp;#039;Module:Icon/styles.css&amp;#039; } })&lt;br /&gt;
	out[#out + 1] = frame:extensionTag({ name = &amp;#039;templatestyles&amp;#039;, args = { src = &amp;#039;Module:Documentation/styles.css&amp;#039; } })&lt;br /&gt;
&lt;br /&gt;
	if onDoc then&lt;br /&gt;
		out[#out + 1] = header(&amp;#039;Documentation subpage&amp;#039;, &amp;#039;Shown on [[&amp;#039; .. page .. &amp;#039;]]&amp;#039;, {&lt;br /&gt;
			action({ label = &amp;#039;Back to the &amp;#039; .. kind, icon = ICONS.back, link = page }),&lt;br /&gt;
		})&lt;br /&gt;
	else&lt;br /&gt;
		local doc = page .. &amp;#039;/doc&amp;#039;&lt;br /&gt;
		out[#out + 1] =&lt;br /&gt;
			header(kind == &amp;#039;module&amp;#039; and &amp;#039;Module documentation&amp;#039; or &amp;#039;Template documentation&amp;#039;, &amp;#039;From [[&amp;#039; .. doc .. &amp;#039;]]&amp;#039;, {&lt;br /&gt;
				action({ label = &amp;#039;Edit&amp;#039;, icon = ICONS.edit, link = &amp;#039;Special:EditPage/&amp;#039; .. doc }),&lt;br /&gt;
				action({ label = &amp;#039;History&amp;#039;, icon = ICONS.history, link = &amp;#039;Special:PageHistory/&amp;#039; .. doc }),&lt;br /&gt;
				action({ label = &amp;#039;Purge&amp;#039;, icon = ICONS.purge, link = &amp;#039;Special:Purge/&amp;#039; .. title.fullText }),&lt;br /&gt;
			})&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local notices = mw.html.create(&amp;#039;div&amp;#039;):addClass(&amp;#039;t-documentation__notices&amp;#039;)&lt;br /&gt;
	if not onDoc and title.namespace == NS_MODULE and title.subpageText == &amp;#039;testcases&amp;#039; then&lt;br /&gt;
		notices:wikitext(&lt;br /&gt;
			hatnote(&lt;br /&gt;
				&amp;#039;This is the test cases page for the module [[Module:&amp;#039; .. title.baseText .. &amp;#039;]].&amp;#039;,&lt;br /&gt;
				{ icon = &amp;#039;WikimediaUI-LabFlask.svg&amp;#039; }&lt;br /&gt;
			)&lt;br /&gt;
		)&lt;br /&gt;
	end&lt;br /&gt;
	notices:wikitext(technicalDetails({&lt;br /&gt;
		addCategories = (not onDoc) and args.category or nil,&lt;br /&gt;
		sources = sources(args, kind, title.rootText, page),&lt;br /&gt;
	}))&lt;br /&gt;
	out[#out + 1] = tostring(notices)&lt;br /&gt;
&lt;br /&gt;
	if title.namespace == NS_TEMPLATE or title.namespace == NS_MODULE then&lt;br /&gt;
		out[#out + 1] = categories(kind, onDoc, title.baseText, importOrigin(args, page) ~= nil)&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	if not onDoc and title.namespace == NS_MODULE then&lt;br /&gt;
		local testcases = title.text .. &amp;#039;/testcases&amp;#039;&lt;br /&gt;
		if mw.title.new(testcases, &amp;#039;Module&amp;#039;).exists then&lt;br /&gt;
			out[#out + 1] = frame:preprocess(&amp;#039;{{#invoke:&amp;#039; .. testcases .. &amp;#039;|run}}&amp;#039;)&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	return table.concat(out)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
-- Test-only exports. Not part of the public API.&lt;br /&gt;
p._internal = {&lt;br /&gt;
	categories = categories,&lt;br /&gt;
	linkText = linkText,&lt;br /&gt;
	sources = sources,&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
return p&lt;br /&gt;
-- &amp;lt;/nowiki&amp;gt;&lt;/div&gt;</summary>
		<author><name>starcitizen&gt;Alistar Bot</name></author>
	</entry>
</feed>