<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="ru">
	<id>https://wiki-data.rcsi.science/index.php?action=history&amp;feed=atom&amp;title=%D0%9C%D0%BE%D0%B4%D1%83%D0%BB%D1%8C%3AAligned_table</id>
	<title>Модуль:Aligned table - История изменений</title>
	<link rel="self" type="application/atom+xml" href="https://wiki-data.rcsi.science/index.php?action=history&amp;feed=atom&amp;title=%D0%9C%D0%BE%D0%B4%D1%83%D0%BB%D1%8C%3AAligned_table"/>
	<link rel="alternate" type="text/html" href="https://wiki-data.rcsi.science/index.php?title=%D0%9C%D0%BE%D0%B4%D1%83%D0%BB%D1%8C:Aligned_table&amp;action=history"/>
	<updated>2026-04-03T20:51:23Z</updated>
	<subtitle>История изменений этой страницы в вики</subtitle>
	<generator>MediaWiki 1.36.1</generator>
	<entry>
		<id>https://wiki-data.rcsi.science/index.php?title=%D0%9C%D0%BE%D0%B4%D1%83%D0%BB%D1%8C:Aligned_table&amp;diff=736&amp;oldid=prev</id>
		<title>Admin: 1 версия импортирована</title>
		<link rel="alternate" type="text/html" href="https://wiki-data.rcsi.science/index.php?title=%D0%9C%D0%BE%D0%B4%D1%83%D0%BB%D1%8C:Aligned_table&amp;diff=736&amp;oldid=prev"/>
		<updated>2021-11-15T13:18:33Z</updated>

		<summary type="html">&lt;p&gt;1 версия импортирована&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&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;ru&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Предыдущая&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Версия 13:18, 15 ноября 2021&lt;/td&gt;
				&lt;/tr&gt;
&lt;!-- diff cache key wikidb:diff::1.12:old-735:rev-736 --&gt;
&lt;/table&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki-data.rcsi.science/index.php?title=%D0%9C%D0%BE%D0%B4%D1%83%D0%BB%D1%8C:Aligned_table&amp;diff=735&amp;oldid=prev</id>
		<title>ru&gt;Plastikspork: Optional rowclass</title>
		<link rel="alternate" type="text/html" href="https://wiki-data.rcsi.science/index.php?title=%D0%9C%D0%BE%D0%B4%D1%83%D0%BB%D1%8C:Aligned_table&amp;diff=735&amp;oldid=prev"/>
		<updated>2021-01-13T21:53:43Z</updated>

		<summary type="html">&lt;p&gt;Optional rowclass&lt;/p&gt;
&lt;p&gt;&lt;b&gt;Новая страница&lt;/b&gt;&lt;/p&gt;&lt;div&gt;-- This module implements {{aligned table}}&lt;br /&gt;
local p = {}&lt;br /&gt;
&lt;br /&gt;
local function isnotempty(s)&lt;br /&gt;
	return s and s:match( '^%s*(.-)%s*$' ) ~= ''&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function p.table(frame)&lt;br /&gt;
	local args = (frame.args[3] ~= nil) and frame.args or frame:getParent().args&lt;br /&gt;
	local entries = {}&lt;br /&gt;
	local colclass = {}&lt;br /&gt;
	local colstyle = {}&lt;br /&gt;
	local cols = tonumber(args['cols']) or 2&lt;br /&gt;
&lt;br /&gt;
	-- create the root table&lt;br /&gt;
	local root = mw.html.create('table')&lt;br /&gt;
&lt;br /&gt;
	-- add table style for fullwidth&lt;br /&gt;
	if isnotempty(args['fullwidth']) then&lt;br /&gt;
		root&lt;br /&gt;
			:css('width', '100%')&lt;br /&gt;
			:css('border-collapse', 'collapse')&lt;br /&gt;
			:css('border-spacing', '0px 0px')&lt;br /&gt;
			:css('border', 'none')&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- add table classes&lt;br /&gt;
	if isnotempty(args['class']) then&lt;br /&gt;
		root:addClass(args['class'])&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- add table style&lt;br /&gt;
	if isnotempty(args['style']) then&lt;br /&gt;
		root:cssText(args['style'])&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- build arrays with the column styles and classes&lt;br /&gt;
	if isnotempty(args['leftright']) then&lt;br /&gt;
		colstyle[1] = 'text-align:left;'&lt;br /&gt;
		colstyle[2] = 'text-align:right;'&lt;br /&gt;
	end&lt;br /&gt;
	if isnotempty(args['rightleft']) then&lt;br /&gt;
		colstyle[1] = 'text-align:right;'&lt;br /&gt;
		colstyle[2] = 'text-align:left;'&lt;br /&gt;
	end&lt;br /&gt;
	for i = 1,cols do&lt;br /&gt;
		colclass[ i ] = colclass[ i ] or ''&lt;br /&gt;
		colstyle[ i ] = colstyle[ i ] or ''&lt;br /&gt;
		if isnotempty(args['colstyle']) then&lt;br /&gt;
			colstyle[ i ] = args['colstyle'] .. ';' .. colstyle[ i ]&lt;br /&gt;
		end&lt;br /&gt;
		if isnotempty(args['colalign' .. tostring(i)]) then&lt;br /&gt;
			colstyle[ i ] = 'text-align:' .. args['colalign' .. tostring(i)] .. ';' .. colstyle[ i ]&lt;br /&gt;
		elseif isnotempty(args['col' .. tostring(i) .. 'align']) then&lt;br /&gt;
			colstyle[ i ] = 'text-align:' .. args['col' .. tostring(i) .. 'align'] .. ';' .. colstyle[ i ]&lt;br /&gt;
		elseif isnotempty(args['align' .. tostring(i)]) then&lt;br /&gt;
			colstyle[ i ] = 'text-align:' .. args['align' .. tostring(i)] .. ';' .. colstyle[ i ]&lt;br /&gt;
		end&lt;br /&gt;
		if isnotempty(args['colnowrap' .. tostring(i)]) then&lt;br /&gt;
			colstyle[ i ] = 'white-space:nowrap;' .. colstyle[ i ]&lt;br /&gt;
		elseif isnotempty(args['col' .. tostring(i) .. 'nowrap']) then&lt;br /&gt;
			colstyle[ i ] = 'white-space:nowrap;' .. colstyle[ i ]&lt;br /&gt;
		elseif isnotempty(args['nowrap' .. tostring(i)]) then&lt;br /&gt;
			colstyle[ i ] = 'white-space:nowrap;' .. colstyle[ i ]&lt;br /&gt;
		end&lt;br /&gt;
		if isnotempty(args['colwidth' .. tostring(i)]) then&lt;br /&gt;
			colstyle[ i ] = 'width:' .. args['colwidth' .. tostring(i)] .. ';' .. colstyle[ i ]&lt;br /&gt;
		elseif isnotempty(args['col' .. tostring(i) .. 'width']) then&lt;br /&gt;
			colstyle[ i ] = 'width:' .. args['col' .. tostring(i) .. 'width'] .. ';' .. colstyle[ i ]&lt;br /&gt;
		elseif isnotempty(args['colwidth']) then&lt;br /&gt;
			colstyle[ i ] = 'width:' .. args['colwidth'] .. ';' .. colstyle[ i ]&lt;br /&gt;
		end&lt;br /&gt;
		if isnotempty(args['colstyle' .. tostring(i)]) then&lt;br /&gt;
			colstyle[ i ] = colstyle[ i ] .. args['colstyle' .. tostring(i)]&lt;br /&gt;
		elseif isnotempty(args['col' .. tostring(i) .. 'style']) then&lt;br /&gt;
			colstyle[ i ] = colstyle[ i ] .. args['col' .. tostring(i) .. 'style']&lt;br /&gt;
		elseif isnotempty(args['style' .. tostring(i)]) then&lt;br /&gt;
			colstyle[ i ] = colstyle[ i ] .. args['style' .. tostring(i)]&lt;br /&gt;
		end&lt;br /&gt;
		if isnotempty(args['colclass' .. tostring(i)]) then&lt;br /&gt;
			colclass[ i ] =  args['colclass' .. tostring(i)]&lt;br /&gt;
		elseif isnotempty(args['col' .. tostring(i) .. 'class']) then&lt;br /&gt;
			colclass[ i ] =  args['col' .. tostring(i) .. 'class']&lt;br /&gt;
		elseif isnotempty(args['class' .. tostring(i)]) then&lt;br /&gt;
			colclass[ i ] =  args['class' .. tostring(i)]&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	-- compute the maximum cell index&lt;br /&gt;
	local cellcount = 0&lt;br /&gt;
	for k, v in pairs( args ) do&lt;br /&gt;
		if type( k ) == 'number' then&lt;br /&gt;
			cellcount = math.max(cellcount, k)&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	-- compute the number of rows&lt;br /&gt;
	local rows = math.ceil(cellcount / cols)&lt;br /&gt;
&lt;br /&gt;
	-- build the table content&lt;br /&gt;
	if isnotempty(args['title']) then&lt;br /&gt;
		local caption = root:tag('caption')&lt;br /&gt;
		caption:cssText(args['titlestyle'])&lt;br /&gt;
		caption:wikitext(args['title'])&lt;br /&gt;
	end&lt;br /&gt;
	if isnotempty(args['above']) then&lt;br /&gt;
		local row = root:tag('tr')&lt;br /&gt;
		local cell = row:tag('th')&lt;br /&gt;
		cell:attr('colspan', cols)&lt;br /&gt;
		cell:cssText(args['abovestyle'])&lt;br /&gt;
		cell:wikitext(args['above'])&lt;br /&gt;
	end&lt;br /&gt;
	for j=1,rows do&lt;br /&gt;
		-- start a new row&lt;br /&gt;
		local row = root:tag('tr')&lt;br /&gt;
		if isnotempty(args['rowstyle']) then&lt;br /&gt;
			row:cssText(args['rowstyle'])&lt;br /&gt;
		else&lt;br /&gt;
			row:css('vertical-align', 'top')&lt;br /&gt;
		end&lt;br /&gt;
		if isnotempty(args['rowclass']) then&lt;br /&gt;
			row:addClass(args['rowclass'])&lt;br /&gt;
		end&lt;br /&gt;
		-- loop over the cells in the row&lt;br /&gt;
		for i=1,cols do&lt;br /&gt;
			local cell&lt;br /&gt;
			if isnotempty(args['row' .. tostring(j) .. 'header']) then&lt;br /&gt;
				cell = row:tag('th'):attr('scope','col')&lt;br /&gt;
			elseif isnotempty(args['col' .. tostring(i) .. 'header']) then&lt;br /&gt;
				cell = row:tag('th'):attr('scope','row')&lt;br /&gt;
			else&lt;br /&gt;
				cell = row:tag('td')&lt;br /&gt;
			end&lt;br /&gt;
			if args['class' .. tostring(j) .. '.' .. tostring(i)] then&lt;br /&gt;
				cell:addClass(args['class' .. tostring(j) .. '.' .. tostring(i)])&lt;br /&gt;
			else&lt;br /&gt;
				if args['rowclass' .. tostring(j)] then&lt;br /&gt;
					cell:addClass(args['rowclass' .. tostring(j)])&lt;br /&gt;
				elseif args['row' .. tostring(j) .. 'class'] then&lt;br /&gt;
					cell:addClass(args['row' .. tostring(j) .. 'class'])&lt;br /&gt;
				elseif args['rowevenclass'] and math.fmod(j,2) == 0 then&lt;br /&gt;
					cell:addClass(args['rowevenclass'])&lt;br /&gt;
				elseif args['rowoddclass'] and math.fmod(j,2) == 1 then	&lt;br /&gt;
					cell:addClass(args['rowoddclass'])&lt;br /&gt;
				end&lt;br /&gt;
				if colclass[i] ~= '' then&lt;br /&gt;
					cell:addClass(colclass[i])&lt;br /&gt;
				end&lt;br /&gt;
			end&lt;br /&gt;
			if args['style' .. tostring(j) .. '.' .. tostring(i)] then&lt;br /&gt;
				cell:cssText(args['style' .. tostring(j) .. '.' .. tostring(i)])&lt;br /&gt;
			else&lt;br /&gt;
				if args['rowstyle' .. tostring(j)] then&lt;br /&gt;
					cell:cssText(args['rowstyle' .. tostring(j)])&lt;br /&gt;
				elseif args['rowevenstyle'] and math.fmod(j,2) == 0 then&lt;br /&gt;
					cell:cssText(args['rowevenstyle'])&lt;br /&gt;
				elseif args['rowoddstyle'] and math.fmod(j,2) == 1 then	&lt;br /&gt;
					cell:cssText(args['rowoddstyle'])&lt;br /&gt;
				elseif args['row' .. tostring(j) .. 'style'] then&lt;br /&gt;
					cell:cssText(args['row' .. tostring(j) .. 'style'])&lt;br /&gt;
				end&lt;br /&gt;
				if isnotempty(colstyle[i]) then&lt;br /&gt;
					cell:cssText(colstyle[i])&lt;br /&gt;
				end&lt;br /&gt;
			end&lt;br /&gt;
			cell:wikitext(mw.ustring.gsub(args[cols*(j - 1) + i] or '', '^(.-)%s*$', '%1') or '')&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	-- return the root table&lt;br /&gt;
	return tostring(root)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
return p&lt;/div&gt;</summary>
		<author><name>ru&gt;Plastikspork</name></author>
	</entry>
</feed>