(deasbaireachd⧼tpt-languages-separator⧽deasaich⧼tpt-languages-separator⧽eachdraidh⧼tpt-languages-separator⧽ceanglaichean⧼tpt-languages-separator⧽doc⧼tpt-languages-separator⧽bogsa-gainmhich⧼tpt-languages-separator⧽cùisean deuchainn)


Tuairisgeul - Description

This template is used to display wikilinks to all currently supported taxon identifier databases, automatically loaded from Mòideal:Taxonbar/conf's p.databases table.

Ùsaid - Usage

{{Taxonbar databases}}


Paramadairean - Parameters

|state= usage is identical to that of {{Navbox}}, and defaults to collapsed due to navbox size.

Faic cuideachd - Also see


local p = {}

function p.list(frame)
	local nav  = require( 'Mòideal:Navbox' )
	local conf = require( 'Mòideal:Taxonbar/conf' ).databases
	local exclude = {
		['Wikidata'] = 'not citable',
		['Wikispecies'] = 'not citable',
		['emonocotfamily'] = 'redundant [[eMonocot]] link',
		['WSC genus'] = 'redundant [[World Spider Catalog]] link',
		['WSC family'] = 'redundant [[World Spider Catalog]] link',
	}
	local args = frame:getParent().args
	
	local elements = {}
	for _, c in pairs( conf ) do
		if exclude[c[1]] == nil then
			local c3 = tonumber(c[3])
			if (c3 and c3 > 0) or (c3 == nil) then
				table.insert( elements, c[2] )
			end
		end
	end
	
	return nav._navbox( {
			name        = 'Taxonbar databases',
			title       = '[[:en:w:Help:Taxon identifiers|Taxonbar databases]]',
			bodyclass   = 'hlist',
			state       = args.state or 'collapsed',
			list1       = table.concat( elements, ' • ' )
			} )
end

return p