Jump to content

Module:Infobox ship/data: Difference between revisions

From Wikipedia, the free encyclopedia
Content deleted Content added
create;
(No difference)

Revision as of 22:48, 18 May 2022

--[[--------------------------< S T Y L E S >------------------------------------------------------------------

TODO: move these into templatestyles css

]]

local styles_t = {																-- these are variations on the styles from Module:WPMILHIST Infobox style
	mainbox = 'width:25.5em;border-spacing:2px;',
	history = 'background-color:#C3D6EF;text-align:center;vertical-align:middle;font-size:110%;';	-- infobox career history header
	country = 'height:30px;background-color:#B0C4DE;text-align:left;padding-left:2px;vertical-align:middle;font-size:110%;';	-- infobox career flag & country header
	general = 'height:30px;background-color:#C3D6EF;vertical-align:middle;font-size:110%;';			-- infobox characteristics & class overview headers
	}


--[[--------------------------< I N F O B O X   P A R A M E T E R S >------------------------------------------

These tables hold the names and define the rendering order of the label/data pairs in the associated infoboxen.
Each table is a sequence of sub-sequences where each subsequence holds
	[1] the parameter name
	[2] the rendered label for that parameter's value

]]

local infobox_career_params_t = {												-- table of parameters that are rendered in the same way
	{'ship_name', 'Name'},
	{'ship_namesake', 'Namesake'},
	{'ship_owner', 'Owner'},
	{'ship_operator', 'Operator'},
	{'ship_registry', 'Port of registry'},
	{'ship_route', 'Route'},
	{'ship_ordered', 'Ordered'},
	{'ship_awarded', 'Awarded'},
	{'ship_builder', 'Builder'},
	{'ship_original cost', 'Cost'},
	{'ship_yard_number', 'Yard number'},
	{'ship_way_number', 'Way number'},
	{'ship_laid_down', 'Laid down'},
	{'ship_launched', 'Launched'},
	{'ship_sponsor', 'Sponsored by'},
	{'ship_christened', 'Christened'},
	{'ship_completed', 'Completed'},
	{'ship_acquired', 'Acquired'},
	{'ship_commissioned', 'Commissioned'},
	{'ship_recommissioned', 'Recommissioned'},
	{'ship_decommissioned', 'Decommissioned'},
	{'ship_maiden_voyage', 'Maiden voyage'},
	{'ship_in_service', 'In service'},
	{'ship_out_of_service', 'Out of service'},
	{'ship_renamed', 'Renamed'},
	{'ship_reclassified', 'Reclassified'},
	{'ship_refit', 'Refit'},
	{'ship_struck', 'Stricken'},
	{'ship_stricken', 'Stricken'},
	{'ship_reinstated', 'Reinstated'},
	{'ship_homeport', 'Homeport'},
	{'ship_identification', 'Identification'},
	{'ship_motto', 'Motto'},
	{'ship_nickname', 'Nickname(s)'},
	{'ship_honours', 'Honours and<br />awards'},								-- make these two the same index?
	{'ship_honors', 'Honors and<br />awards'},
	{'ship_captured', 'Captured'},
	{'ship_fate', 'Fate'},
	{'ship_status', 'Status'},
	{'ship_career_notes', 'Notes'},												-- renamed from ship_notes because duplicated name
	{'ship_badge', 'Badge'},
	}

local infobox_characteristics_params_t = {										-- table of parameters that are rendered in the same way
	{'ship_class', 'Class and type'},
	{'ship_type', 'Type'},
	{'ship_tonnage', 'Tonnage'},
	{'ship_displacement', 'Displacement'},
	{'ship_tons burthen', 'Tons burthen'},
	{'ship_length', 'Length'},
	{'ship_beam', 'Beam'},
	{'ship_height', 'Height'},
	{'ship_draught', 'Draught'},
	{'ship_draft', 'Draft'},
	{'ship_depth', 'Depth'},
	{'ship_hold_depth', 'Depth of hold'},
	{'ship_decks', 'Decks'},
	{'ship_deck_clearance', 'Deck clearance'},
	{'ship_ramps', 'Ramps'},
	{'ship_ice_class', 'Ice class'},
	{'ship_power', 'Installed power'},
	{'ship_propulsion', 'Propulsion'},
	{'ship_sail_plan', 'Sail plan'},
	{'ship_speed', 'Speed'},
	{'ship_range', 'Range'},
	{'ship_endurance', 'Endurance'},
	{'ship_test_depth', 'Test depth'},
	{'ship_boats', 'Boats & landing <br /> craft carried'},
	{'ship_capacity', 'Capacity'},
	{'ship_troops', 'Troops'},
	{'ship_complement', 'Complement'},
	{'ship_crew', 'Crew'},
	{'ship_time_to_activate', 'Time to activate'},
	{'ship_sensors', 'Sensors and <br /> processing systems'},
	{'ship_EW', 'Electronic warfare <br /> & decoys'},
	{'ship_armament', 'Armament'},
	{'ship_armour', 'Armour'},
	{'ship_armor', 'Armor'},
	{'ship_aircraft', 'Aircraft carried'},
	{'ship_aircraft_facilities', 'Aviation facilities'},
	{'ship_characteristics_notes', 'Notes'},									-- renamed from ship_notes because duplicated name
	}

local infobox_class_overview_params_t = {										-- table of parameters that are rendered in the same way
	{'name', 'Name'},
	{'builders', 'Builders'},
	{'operators', 'Operators'},
	{'class_before', 'Preceded by'},
	{'class_after', 'Succeeded&nbsp;by'},
	{'subclasses', 'Subclasses'},
	{'cost', 'Cost'},
	{'built_range', 'Built'},
	{'in_service_range', 'In service'},
	{'in_commission_range', 'In commission'},
	{'total_ships_planned', 'Planned'},
	{'total_ships_on_order', 'On order'},
	{'total_ships_building', 'Building'},
	{'total_ships_completed', 'Completed'},
	{'total_ships_cancelled', 'Cancelled'},
	{'total_ships_active', 'Active'},
	{'total_ships_laid up', 'Laid up'},
	{'total_ships_lost', 'Lost'},
	{'total_ships_retired', 'Retired'},
	{'total_ships_scrapped', 'Scrapped'},
	{'total_ships_preserved', 'Preserved'},
	}

local infobox_ship_service_record_params_t = {									-- table of parameters that are rendered in the same way
	{'partof', 'Part of'},
	{'codes', 'Identification codes'},
	{'commanders', 'Commanders'},
	{'operations', 'Operations'},
	{'victories', 'Victories'},
	{'awards', 'Awards'},
	}


--[[--------------------------< E X P O R T S >----------------------------------------------------------------
]]

return
	{
	styles_t = styles_t,
	infobox_career_params_t = infobox_career_params_t,
	infobox_characteristics_params_t = infobox_characteristics_params_t,
	infobox_class_overview_params_t = infobox_class_overview_params_t,
	infobox_ship_service_record_params_t = infobox_ship_service_record_params_t
	}