Aller au contenu

Module:Infobox/Plan d'eau

Une page de Wikipédia, l'encyclopédie libre.
Ceci est une version archivée de cette page, en date du 31 octobre 2016 à 19:42 et modifiée en dernier par Thierry Caro (discuter | contributions). Elle peut contenir des erreurs, des inexactitudes ou des contenus vandalisés non présents dans la version actuelle.

 Documentation[voir] [modifier] [historique] [purger]

Cette page définit un module d'infobox. Pour les conseils sur l'usage de ce module, voyez Modèle:Infobox Plan d'eau.


local building = require "Module:Infobox/Fonctions/Bâtiment"
local general = require "Module:Infobox/Fonctions"
local wikidata = require "Module:Wikidata"
local wd = require "Module:Interface Wikidata".fromLua
local l = require "Module:Infobox/Fonctions/Localité"


return {
	maincolor = 'D0E0F0',
	parts = {
		
		general.title( "entete map"),
		l.mainimage(),
		{type = 'table', rows = {
			{type = 'row', label = 'Nom dans la langue originale', value = 'nom dans la langue originale', wikidata = {property = 'P1705', showlang = true} },
			{type = 'row', label = 'Nom officiel', plurallabel = 'Noms officiels', value = 'nom officiel', property = 'P1448'},
		}},
		
		{type = 'table', title = 'Localisation', rows = {
			{type = 'row', label = 'Continent', plurallabel = 'Continents', value = 'continent', property = 'P30'},
			building.country(),
			{type = 'row', label = 'Région', plurallabel = 'Régions', value = 'région', property = 'P131'},
			building.historicalregion(),
			{type = 'row', label = 'Localisation géographique', value = 'localisation géographique', property = 'P706'},
			{type = 'row', label = 'Partie de', value = 'partie de', property = 'P361'},
			{type = "row", label = "Aire protégée", plurallabel = "Aires protégées", value = "aire protégée", property = "P3018"},
			{type = 'row', label = 'Altitude', value = 'altitude', wikidata = {property = 'P2044', targetunit = 'metre', conjtype = ' ou ', rounding = '0'} },
			{type = 'row', label = 'Climat', plurallabel = 'Climats', value = 'climat', property = 'P2564'},
			building.coordinates(),
		}},
		{type = 'table', title = 'Dimensions', rows = {
			{type = 'row', label = 'Longueur', value = 'longueur', property = 'P2043'},
			{type = 'row', label = 'Largeur', value = 'largeur', property = 'P2049'},
			{type = 'row', label = 'Périmètre', value = 'périmètre', property = 'P2547'},
			{type = 'row', label = 'Superficie', value = 'superficie', wikidata = {property = 'P2046', targetunit = 'sqkm', rounding = '0'} },
			{type = 'row', label = 'Profondeur', value = 'profondeur', wikidata = {property = 'P2610', targetunit = 'm', rounding = '0'} },
			{type = 'row', label = 'Volume', value = 'volume', property = 'P2234'},
			{type = 'row', label = 'Subdivision', plurallabel = 'Subdivisions', value = 'subdivision', property = 'P150'},
			{
				type = "row",
				label = "Îles",
				value = "nombre d'îles",
				wikidata = function ( item )
					return wd.formatQualifiers{
						entity = item,
						property = 'P527',
						targetvalue = 'Q23442',
						qualifiers = 'P1114',
						addcat = true,
						linkback = true,
					}
				end,
			},
			general.bathymetricmap(),
		}},
		{type = 'table', title = 'Hydrographie', rows = {
			{type = 'row', label = 'Type', value = 'type', property = 'P31'},
			{type = 'row', label = 'Bassin versant', value = {'bassin versant', 'superficie du bassin versant'}, wikidata = {property = 'P2053', targetunit = 'sqkm', rounding = '0'} },
			{type = 'row', label = 'Pays du bassin', value = {'pays du bassin', 'pays du bassin versant', 'pays souverain sur le bassin versant'}, property = 'P205'},
			{type = 'row', label = 'Alimentation', value = 'alimentation', property = 'P200'},
			{type = 'row', label = 'Rétention', value = {'rétention', 'durée de rétention'}, property = 'P3020'},
			{type = 'row', label = 'Émissaire', plurallabel='Émissaires', value = 'émissaire', property = 'P201'},
			{type = 'row', label = 'Débit', value = 'débit', property = 'P2225'},
		}},
		
		{type = 'table', title = 'Histoire', rows = {
			{type = 'row', label = 'Origine du nom', value = 'origine du nom', property = 'P138'},
			{type = 'row', label = 'Événement clé', plurallabel = 'Événements clés', value = 'événement clé', property = 'P793'},
			building.owner(),
			{type = 'row', label = 'Équipement', plurallabel = 'Équipements', value = 'équipement', property = 'P912'},
			{type = 'row', label = 'Statut patrimonial', value = 'statut patrimonial', property = 'P1435'},
			{type = 'row', label = 'Distinction', plurallabel = 'Distinctions', value = 'distinction', property = 'P166'},
		}},
		building.geoloc({pointtype = 'lac', maptype = 'relief'}),
	}
}