 local pu800 local args local origargs local root local empty_row_categories local category_in_empty_row_pattern ' su800* u8d8b1 u8d8af u8d987 su800* * ' local has_rows false local lists plainlist_t patterns ' plainlist ' ' splainlist ' ' plainlist su800' ' splainlist su800' found false styles 'plainlist stylesu82ecssu800 hlist_t patterns ' hlist ' ' shlist ' ' hlist su800' ' shlist su800' found false styles 'hlist stylesu82ecssu800 local function has_list_class args_to_check foru800 _u800 list inu800 pairs lists dou800 ifu800 notu800 listu82efound then foru800 _u800 argu800 inu800 pairs args_to_check dou800 foru800 _u800 pattern inu800 ipairs listu82epatterns dou800 ifu800 mwu800u82eustringu82efind argu800 oru800   pattern then listu82efound true break endu800 endu800 ifu800 listu82efound then break endu800 endu800 endu800 endu800 endu800 local function fixchildboxes sval ttu800 local function notempty su800 return su800 andu800 su800 match ' su800' endu800 ifu800 notempty sval then local marker ' ' local su800 sval start moving templatestyles andu800 categories inside ofu800 table rows local slast   while slast su800 dou800 slast su800 su800 mwu800u82eustringu82egsub su800 ' ttu800 rru800 su800* su800* su800* u8d8b1 u8d8af u8d987 su800* * ' ' 2u800 1u800' su800 mwu800u82eustringu82egsub su800 ' ttu800 rru800 su800* su800* 127u800 127u800 *uniq templatestyles xu800 qinu 127u800 * 127u800 ' ' 2u800 1u800' endu800 endu800 moving templatestyles andu800 categories inside ofu800 table rows su800 mwu800u82eustringu82egsub su800 ' su800* ttu800 rru800 ' marker .. ' 1u800' su800 mwu800u82eustringu82egsub su800 ' ttu800 rru800 su800* ' ' 1u800' .. marker ifu800 mwu800u82eustringu82ematch su800 marker then su800 mwu800u82eustringu82egsub su800 marker .. ' su800*' .. marker   su800 mwu800u82eustringu82egsub su800 ' ru800 nu800 ru800 nu800 * ru800 nu800 su800*' .. marker ' 1u800' su800 mwu800u82eustringu82egsub su800 marker .. ' su800* ru800 nu800 ' ' 1u800' su800 mwu800u82eustringu82egsub su800 ' ccu800 aau800 ppu800 ttu800 iiu800 oou800 nnu800 su800* su800* ' .. marker ' 1u800' su800 mwu800u82eustringu82egsub su800 ' su800* ttu800 aau800 bbu800 llu800 eeu800 * su800* ' .. marker ' 1u800' su800 mwu800u82eustringu82egsub su800 ' ru800 nu800 * ru800 nu800 su800* ' .. marker ' 1u800' su800 mwu800u82eustringu82egsub su800 ' ru800 nu800 ru800 nu800 * ru800 nu800 su800* ' .. marker ' 1u800' su800 mwu800u82eustringu82egsub su800 marker .. ' su800* ttu800 aau800 bbu800 llu800 eeu800 su800* ' ' 1u800' su800 mwu800u82eustringu82egsub su800 marker .. ' su800* nu800 ' ' 1u800' endu800 ifu800 su800 match marker then local subcells mwu800u82etextu82esplit su800 marker su800   foru800 ku800 1u800 #subcells dou800 ifu800 ku800 1u800 then su800 su800 .. subcells ku800 .. ' ' .. ttu800 .. ' ' elseif ku800 #subcells then local rowstyle ' style "display none"' ifu800 notempty subcells ku800 then rowstyle   endu800 su800 su800 .. ' ' .. ttu800 .. ' colspan 2u800 nu800' .. subcells ku800 elseif notempty subcells ku800 then ifu800 ku800 2u800 0u800 then su800 su800 .. subcells ku800 else su800 su800 .. ' ' .. ttu800 .. ' colspan 2u800 nu800' .. subcells ku800 .. ' ' .. ttu800 .. ' ' endu800 endu800 endu800 endu800 theu800 next twou800 lines addu800 au800 newline atu800 theu800 endu800 ofu800 lists foru800 theu800 phpu800 parser special diff 849054481 remove when phab t191516 isu800 fixed oru800 obeu800 su800 mwu800u82eustringu82egsub su800 ' ru800 nu800 *#; ru800 nu800 * ' ' 1u800 nu800' su800 mwu800u82eustringu82egsub su800 ' *#; ru800 nu800 * ' ' 1u800 nu800' su800 mwu800u82eustringu82egsub su800 ' *#; ' ' nu800 1u800' su800 mwu800u82eustringu82egsub su800 ' ' ' nu800 1u800' return su800 else return sval endu800 endu800 cleans empty tables local function cleaninfobox root tostring root ifu800 has_rows false then root mwu800u82eustringu82egsub root ' * su800* '   endu800 endu800 returns theu800 union ofu800 theu800 values ofu800 twou800 tables asu800 au800 sequence. local function union t1u800 t2u800 local vals foru800 ku800 vu800 inu800 pairs t1u800 dou800 vals vu800 true endu800 foru800 ku800 vu800 inu800 pairs t2u800 dou800 vals vu800 true endu800 local retu800 foru800 ku800 vu800 inu800 pairs vals dou800 tableu82einsert retu800 ku800 endu800 return retu800 endu800 returns au800 table containing theu800 numbers ofu800 theu800 arguments that exist foru800 theu800 specified prefix. foru800 example ifu800 theu800 prefix wasu800 'data' andu800 'data1' 'data2' andu800 'data5' exist itu800 would return 1u800 2u800 5u800 . local function getargnums prefix local nums foru800 ku800 vu800 inu800 pairs args dou800 local numu800 mwu800u82eustringu82ematch tostring ku800 ' ' .. prefix .. ' 1u800 9u800 du800* ' ifu800 numu800 then tableu82einsert nums tonumber numu800 endu800 endu800 tableu82esort nums return nums endu800 adds au800 rowu800 tou800 theu800 infobox with either au800 header cell oru800 au800 label data cell combination. local function addrow rowargs ifu800 rowargsu82eheader andu800 rowargsu82eheader '_blank_' then has_rows true root tagu800 'tru800' addclass rowargsu82erowclass csstext rowargsu82erowstyle tagu800 'thu800' attr 'colspan' '2u800' addclass 'infobox header' addclass rowargsu82eclass addclass argsu82eheaderclass deprecated next; target .infobox .infobox header csstext argsu82eheaderstyle csstext rowargsu82erowcellstyle wikitext fixchildboxes rowargsu82eheader 'thu800' ifu800 rowargsu82edata then root wikitext ' u8d8b1u8d8afu8d987 u8d8b5u8d981u8d8adu8d987u8e2808cu8d987u8d8a7u8db8cu8db8c u8daa9u8d987 u8d8a7u8d8b2 u8d8a7u8d984u8daafu8d988u8d987u8d8a7u8db8c u8d8acu8d8b9u8d8a8u8d987 u8d8a7u8d8b7u8d984u8d8a7u8d8b9u8d8a7u8d8aa u8d8a8u8d8a7 u8d8b3u8d984u8d988u8d984u8e2808cu8d987u8d8a7u8db8c u8d8afu8d8a7u8d8afu8d987 u8d986u8d8a7u8d8afu8db8cu8d8afu8d987 u8daafu8d8b1u8d981u8d8aau8d987u8e2808cu8d8b4u8d8afu8d987 u8d8a7u8d8b3u8d8aau8d981u8d8a7u8d8afu8d987 u8d985u8db8cu8e2808cu8daa9u8d986u8d986u8d8af ' endu800 elseif rowargsu82edata andu800 rowargsu82edata gsub category_in_empty_row_pattern   match ' su800' then has_rows true local rowu800 root tagu800 'tru800' rowu800 addclass rowargsu82erowclass rowu800 csstext rowargsu82erowstyle ifu800 rowargsu82elabel then rowu800 tagu800 'thu800' attr 'scope' 'rowu800' addclass 'infobox label' deprecated next; target .infobox .infobox label csstext argsu82elabelstyle csstext rowargsu82erowcellstyle wikitext rowargsu82elabel done endu800 local datacell rowu800 tagu800 'tdu800' datacell attr 'colspan' notu800 rowargsu82elabel andu800 '2u800' oru800 nilu800 addclass notu800 rowargsu82elabel andu800 'infobox full data' oru800 'infobox data' addclass rowargsu82eclass deprecated next; target .infobox .infobox full data csstext rowargsu82edatastyle csstext rowargsu82erowcellstyle wikitext fixchildboxes rowargsu82edata 'tdu800' else tableu82einsert empty_row_categories rowargsu82edata oru800   endu800 endu800 local function rendertitle ifu800 notu800 argsu82etitle then return endu800 has_rows true root tagu800 'caption' addclass 'infobox title' addclass argsu82etitleclass deprecated next; target .infobox .infobox title csstext argsu82etitlestyle wikitext argsu82etitle endu800 local function renderaboverow ifu800 notu800 argsu82eabove then return endu800 has_rows true root tagu800 'tru800' tagu800 'thu800' attr 'colspan' '2u800' addclass 'infobox above' addclass argsu82eaboveclass deprecated next; target .infobox .infobox above csstext argsu82eabovestyle wikitext fixchildboxes argsu82eabove 'thu800' endu800 local function renderbelowrow ifu800 notu800 argsu82ebelow then return endu800 has_rows true root tagu800 'tru800' tagu800 'tdu800' attr 'colspan' '2u800' addclass 'infobox below' addclass argsu82ebelowclass deprecated next; target .infobox .infobox below csstext argsu82ebelowstyle wikitext fixchildboxes argsu82ebelow 'tdu800' endu800 local function addsubheaderrow subheaderargs ifu800 subheaderargsu82edata andu800 subheaderargsu82edata gsub category_in_empty_row_pattern   match ' su800' then has_rows true local rowu800 root tagu800 'tru800' rowu800 addclass subheaderargsu82erowclass local datacell rowu800 tagu800 'tdu800' datacell attr 'colspan' '2u800' addclass 'infobox subheader' addclass subheaderargsu82eclass csstext subheaderargsu82edatastyle csstext subheaderargsu82erowcellstyle wikitext fixchildboxes subheaderargsu82edata 'tdu800' else tableu82einsert empty_row_categories subheaderargsu82edata oru800   endu800 endu800 local function rendersubheaders ifu800 argsu82esubheader then argsu82esubheader1 argsu82esubheader endu800 ifu800 argsu82esubheaderrowclass then argsu82esubheaderrowclass1 argsu82esubheaderrowclass endu800 local subheadernums getargnums 'subheader' foru800 ku800 numu800 inu800 ipairs subheadernums dou800 addsubheaderrow data args 'subheader' .. tostring numu800 deprecated next; target .infobox .infobox subheader datastyle argsu82esubheaderstyle rowcellstyle args 'subheaderstyle' .. tostring numu800 class argsu82esubheaderclass rowclass args 'subheaderrowclass .. tostring numu800 endu800 endu800 local function addimagerow imageargs ifu800 imageargsu82edata andu800 imageargsu82edata gsub category_in_empty_row_pattern   match ' su800' then has_rows true has_list_class imageargsu82erowclass imageargsu82eclass local rowu800 root tagu800 'tru800' rowu800 addclass imageargsu82erowclass local datacell rowu800 tagu800 'tdu800' datacell attr 'colspan' '2u800' addclass 'infobox image' addclass imageargsu82eclass csstext imageargsu82edatastyle wikitext fixchildboxes imageargsu82edata 'tdu800' else tableu82einsert empty_row_categories imageargsu82edata oru800   endu800 endu800 local function renderimages ifu800 argsu82eimage then argsu82eimage1 argsu82eimage endu800 ifu800 argsu82ecaption then argsu82ecaption1 argsu82ecaption endu800 local imagenums getargnums 'image' foru800 ku800 numu800 inu800 ipairs imagenums dou800 local caption args 'caption' .. tostring numu800 local data mwu800u82ehtmlu82ecreate wikitext args 'image' .. tostring numu800 ifu800 caption then data tagu800 'divu800' addclass 'infobox caption' deprecated next; target .infobox .infobox caption csstext argsu82ecaptionstyle wikitext caption endu800 addimagerow data tostring data deprecated next; target .infobox .infobox image datastyle argsu82eimagestyle class argsu82eimageclass rowclass args 'imagerowclass .. tostring numu800 endu800 endu800 when autoheaders areu800 turned onu800 preprocesses theu800 rows local function preprocessrows ifu800 notu800 argsu82eautoheaders then return endu800 local rownums union getargnums 'header' getargnums 'data' tableu82esort rownums local lastheader foru800 ku800 numu800 inu800 ipairs rownums dou800 ifu800 args 'header' .. tostring numu800 then ifu800 lastheader then args 'header' .. tostring lastheader nilu800 endu800 lastheader numu800 elseif args 'data' .. tostring numu800 andu800 args 'data' .. tostring numu800 gsub category_in_empty_row_pattern   match ' su800' then local data args 'data' .. tostring numu800 ifu800 data gsub category_in_empty_row_pattern   match ' su800' then lastheader nilu800 endu800 endu800 endu800 ifu800 lastheader then args 'header' .. tostring lastheader nilu800 endu800 endu800 gets theu800 union ofu800 theu800 header andu800 data argument numbers andu800 renders them allu800 inu800 order local function renderrows local rownums union getargnums 'header' getargnums 'data' tableu82esort rownums foru800 ku800 numu800 inu800 ipairs rownums dou800 addrow header args 'header' .. tostring numu800 label args 'label' .. tostring numu800 data args 'data' .. tostring numu800 datastyle argsu82edatastyle class args 'class .. tostring numu800 rowclass args 'rowclass .. tostring numu800 deprecated next; target .infobox rowclass rowstyle args 'rowstyle' .. tostring numu800 rowcellstyle args 'rowcellstyle' .. tostring numu800 endu800 endu800 local function rendernavbar ifu800 notu800 argsu82ename then return endu800 has_rows true root tagu800 'tru800' tagu800 'tdu800' attr 'colspan' '2u800' addclass 'infobox navbar' wikitext require 'module navbar' ._navbar argsu82ename mini 1u800 endu800 local function renderitalictitle local italictitle args 'italic title' andu800 mwu800u82eustringu82elower args 'italic title' ifu800 italictitle   oru800 italictitle 'force' oru800 italictitle 'yesu800 then root wikitext mwu800u82egetcurrentframe expandtemplate title 'italic title' endu800 endu800 categories inu800 otherwise empty rows areu800 collected inu800 empty_row_categories. this function adds them tou800 theu800 module output. itu800 isu800 notu800 affected byu800 argsu82edecat because this module should notu800 prevent module external categories from rendering. local function renderemptyrowcategories foru800 _u800 su800 inu800 ipairs empty_row_categories dou800 root wikitext su800 endu800 endu800 render tracking categories. argsu82edecat turns offu800 tracking categories. local function rendertrackingcategories ifu800 argsu82edecat 'yesu800 then return endu800 ifu800 argsu82echild 'yesu800 then ifu800 argsu82etitle then root wikitext ' u8d8b1u8d8afu8d987 u8d8b5u8d981u8d8adu8d987u8e2808cu8d987u8d8a7u8db8cu8db8c u8daa9u8d987 u8d8a7u8d8b2 u8d8a7u8d984u8daafu8d988u8d987u8d8a7u8db8c u8d8acu8d8b9u8d8a8u8d987 u8d8a7u8d8b7u8d984u8d8a7u8d8b9u8d8a7u8d8aa u8d8acu8d8a7u8d8b3u8d8a7u8d8b2u8db8cu8e2808cu8d8b4u8d8afu8d987 u8d8a8u8d8a7 u8d9beu8d8a7u8d8b1u8d8a7u8d985u8d8aau8d8b1 u8d8b9u8d986u8d988u8d8a7u8d986 u8d8a7u8d8b3u8d8aau8d981u8d8a7u8d8afu8d987 u8d985u8db8cu8e2808cu8daa9u8d986u8d986u8d8af ' endu800 elseif # getargnums 'data' 0u800 andu800 mwu800u82etitleu82egetcurrenttitle .namespace 0u800 then root wikitext ' u8d8b1u8d8afu8d987 u8d985u8d982u8d8a7u8d984u8d987u8e2808cu8d987u8d8a7u8db8cu8db8c u8daa9u8d987 u8d8a7u8d8b2 u8d8a7u8d984u8daafu8d988u8d987u8d8a7u8db8c u8d8acu8d8b9u8d8a8u8d987 u8d8a7u8d8b7u8d984u8d8a7u8d8b9u8d8a7u8d8aa u8d8a8u8d8afu8d988u8d986 u8d8b1u8d8afu8db8cu8d981u8e2808cu8d987u8d8a7u8db8c u8d8afu8d8a7u8d8afu8d987 u8d8a7u8d8b3u8d8aau8d981u8d8a7u8d8afu8d987 u8d985u8db8cu8e2808cu8daa9u8d986u8d986u8d8af ' endu800 endu800 loads theu800 templatestyles foru800 theu800 infobox. todo finish loading base templatestyles here rather than inu800 mediawiki commonu82ecssu800. there areu800 4u800 5000 pages with 'rawu800' infobox tables. seeu800 mediawiki_talk commonu82ecssu800 to_do#infobox andu800 oru800 come help . when weu800 dou800 this weu800 should clean upu800 theu800 inline cssu800 below toou800. will have tou800 dou800 some bizarre conversion category like with sidebar. local function loadtemplatestyles local frame mwu800u82egetcurrentframe seeu800 function description local base_templatestyles frame extensiontag name 'templatestyles args srcu800 'module infobox stylesu82ecssu800 local templatestyles   ifu800 args 'templatestyles then templatestyles frame extensiontag name 'templatestyles args srcu800 args 'templatestyles endu800 local child_templatestyles   ifu800 args 'child templatestyles then child_templatestyles frame extensiontag name 'templatestyles args srcu800 args 'child templatestyles endu800 local grandchild_templatestyles   ifu800 args 'grandchild templatestyles then grandchild_templatestyles frame extensiontag name 'templatestyles args srcu800 args 'grandchild templatestyles endu800 return tableu82econcat base_templatestyles seeu800 function description templatestyles child_templatestyles grandchild_templatestyles endu800 common functions between theu800 child andu800 nonu800 child cases local function structure_infobox_common rendersubheaders renderimages preprocessrows renderrows renderbelowrow rendernavbar renderitalictitle renderemptyrowcategories rendertrackingcategories cleaninfobox endu800 specify theu800 overall layout ofu800 theu800 infobox with special settings ifu800 theu800 infobox isu800 used asu800 au800 'child' inside another infobox. local function _infobox ifu800 argsu82echild 'yesu800 then root mwu800u82ehtmlu82ecreate 'table' root addclass argsu82esubbox 'yesu800 andu800 'infobox subbox' oru800 'infobox' addclass argsu82ebodyclass deprecated next; target .infobox csstext argsu82ebodystyle rendertitle renderaboverow else root mwu800u82ehtmlu82ecreate root wikitext argsu82etitle endu800 structure_infobox_common return loadtemplatestyles .. root endu800 ifu800 theu800 argument exists andu800 isnu800'tu800 blank addu800 itu800 tou800 theu800 argument table. blank arguments areu800 treated asu800 nilu800 tou800 match theu800 behaviour ofu800 parserfunctions. local function preprocesssinglearg argname ifu800 origargs argname andu800 origargs argname   then args argname origargs argname endu800 endu800 assign theu800 parameters with theu800 given prefixes tou800 theu800 args table inu800 order inu800 batches ofu800 theu800 step size specified. this isu800 tou800 prevent references etcu800. from appearing inu800 theu800 wrong order. theu800 prefixtable should beu800 anu800 array containing tables each ofu800 which hasu800 twou800 possible fields au800 "prefix" string andu800 au800 "depend" table. theu800 function always parses parameters containing theu800 "prefix" string butu800 only parses parameters inu800 theu800 "depend" table ifu800 theu800 prefix parameter isu800 present andu800 nonu800 blank. local function preprocessargs prefixtable step ifu800 type prefixtable 'table' then error "u8d985u8d982u8d8afu8d8a7u8d8b1 u8d8bau8db8cu8d8b1 u8d8acu8d8afu8d988u8d984u8db8c u8d8a8u8d8b1u8d8a7u8db8c u8d8acu8d8afu8d988u8d984 u8d9beu8db8cu8d8b4u8d988u8d986u8d8af u8d8b4u8d986u8d8a7u8d8b3u8d8a7u8db8cu8db8c u8d8b4u8d8af" 2u800 endu800 ifu800 type step 'number' then error "u8d985u8d982u8d8afu8d8a7u8d8b1 u8d986u8d8a7u8d985u8d8b9u8d8aau8d8a8u8d8b1 u8d8a8u8d8b1u8d8a7u8db8c u8d985u8d8b1u8d8adu8d984u8d987 u8d8b4u8d986u8d8a7u8d8b3u8d8a7u8db8cu8db8c u8d8b4u8d8af" 2u800 endu800 getu800 arguments without au800 number suffix andu800 check foru800 badu800 input. foru800 iu800 vu800 inu800 ipairs prefixtable dou800 ifu800 type vu800 'table' oru800 type vu800u82eprefix "string" oru800 vu800u82edepend andu800 type vu800u82edepend 'table' then error 'u8d988u8d8b1u8d988u8d8afu8db8c u8d986u8d8a7u8d985u8d8b9u8d8aau8d8a8u8d8b1 u8d8a8u8d8b1u8d8a7u8db8c u8d8acu8d8afu8d988u8d984 u8d9beu8db8cu8d8b4u8d988u8d986u8d8af preprocessargs u8d8b4u8d986u8d8a7u8d8b3u8d8a7u8db8cu8db8c u8d8b4u8d8af' 2u800 endu800 preprocesssinglearg vu800u82eprefix only parse theu800 depend parameter ifu800 theu800 prefix parameter isu800 present andu800 notu800 blank. ifu800 args vu800u82eprefix andu800 vu800u82edepend then foru800 ju800 dependvalue inu800 ipairs vu800u82edepend dou800 ifu800 type dependvalue 'string' then error 'u8d985u8d982u8d8afu8d8a7u8d8b1 u8d986u8d8a7u8d985u8d8b9u8d8aau8d8a8u8d8b1 u8d8a8u8d8b1u8d8a7u8db8c u8d9beu8d8a7u8d8b1u8d8a7u8d985u8d8aau8d8b1 u8c2abdependu8c2bb u8d8afu8d8b1 u8d8aau8d8a7u8d8a8u8d8b9 preprocessargs u8d8b4u8d986u8d8a7u8d8b3u8d8a7u8db8cu8db8c u8d8b4u8d8af' endu800 preprocesssinglearg dependvalue endu800 endu800 endu800 getu800 arguments with number suffixes. local au800 1u800 counter variable. local moreargumentsexist true while moreargumentsexist true dou800 moreargumentsexist false foru800 iu800 au800 au800 step 1u800 dou800 foru800 ju800 vu800 inu800 ipairs prefixtable dou800 local prefixargname vu800u82eprefix .. tostring iu800 ifu800 origargs prefixargname then dou800 another loop ifu800 anyu800 arguments areu800 found even blank ones. moreargumentsexist true preprocesssinglearg prefixargname endu800 process theu800 depend table ifu800 theu800 prefix argument isu800 present andu800 notu800 blank oru800 weu800 areu800 processing "prefix1" andu800 "prefix" isu800 present andu800 notu800 blank andu800 ifu800 theu800 depend table isu800 present. ifu800 vu800u82edepend andu800 args prefixargname oru800 iu800 1u800 andu800 args vu800u82eprefix then foru800 ju800 dependvalue inu800 ipairs vu800u82edepend dou800 local dependargname dependvalue .. tostring iu800 preprocesssinglearg dependargname endu800 endu800 endu800 endu800 au800 au800 step endu800 endu800 parse theu800 data parameters inu800 theu800 same order that theu800 oldu800 infobox didu800 sou800 that references etcu800. will display inu800 theu800 expected places. parameters that depend onu800 another parameter areu800 only processed ifu800 that parameter isu800 present tou800 avoid phantom references appearing inu800 article reference lists. local function parsedataparameters preprocesssinglearg 'autoheaders preprocesssinglearg 'child' preprocesssinglearg 'bodyclass preprocesssinglearg 'subbox' preprocesssinglearg 'bodystyle' preprocesssinglearg 'title' preprocesssinglearg 'titleclass preprocesssinglearg 'titlestyle' preprocesssinglearg 'above' preprocesssinglearg 'aboveclass preprocesssinglearg 'abovestyle' preprocessargs prefix 'subheader' depend 'subheaderstyle' 'subheaderrowclass 10u800 preprocesssinglearg 'subheaderstyle' preprocesssinglearg 'subheaderclass preprocessargs prefix 'image' depend 'caption' 'imagerowclass 10u800 preprocesssinglearg 'captionstyle' preprocesssinglearg 'imagestyle' preprocesssinglearg 'imageclass preprocessargs prefix 'header' prefix 'data' depend 'label' prefix 'rowclass prefix 'rowstyle' prefix 'rowcellstyle' prefix 'class 50u800 preprocesssinglearg 'headerclass preprocesssinglearg 'headerstyle' preprocesssinglearg 'labelstyle' preprocesssinglearg 'datastyle' preprocesssinglearg 'below' preprocesssinglearg 'belowclass preprocesssinglearg 'belowstyle' preprocesssinglearg 'name' different behaviour foru800 italics ifu800 blank oru800 absent args 'italic title' origargs 'italic title' preprocesssinglearg 'decat' preprocesssinglearg 'templatestyles preprocesssinglearg 'child templatestyles preprocesssinglearg 'grandchild templatestyles endu800 ifu800 called viau800 #invoke useu800 theu800 args passed into theu800 invoking template. otherwise foru800 testing purposes assume args areu800 being passed directly inu800. function pu800u82einfobox frame ifu800 frame mwu800u82egetcurrentframe then origargs frame getparent .args else origargs frame endu800 parsedataparameters return _infobox endu800 foru800 calling viau800 #invoke within au800 template function pu800u82einfoboxtemplate frame origargs foru800 ku800 vu800 inu800 pairs frameu82eargs dou800 origargs ku800 mwu800u82etextu82etrim vu800 endu800 parsedataparameters return _infobox endu800 return pu800 