Module:Infobox gene: Difference between revisions

Content deleted Content added
Undo unintended changes per talk request
Much more elegant dark mode fix; see talk
 
(4 intermediate revisions by the same user not shown)
Line 6:
 
--define Global Color Scheme
local rowBGcolor = 'light-dark(#eee, #27292d) !important' --'var(--background-color-neutral)'
local titleBGcolor = 'light-dark(#ddd, #404244) !important'
local sideTitleBGcolor = 'light-dark(#c3fdb8, #003500) !important'
 
-- wrapped "protected call", return "value error" with error info on error
Line 244:
:css('clear', 'none')
:css('float', 'none')
:css('background-color', 'transparent')
 
else
Line 252 ⟶ 251:
-- infobox modules in addition to the class. Be sure to check them out.
:addClass('infobox')
--this template needs a stylesheet and a 'infobox-gene' class
:css('width', '26.4em')
end
Line 329:
:css('text-align', 'center')
:css('background-color', rowBGcolor)
:css('font-sizecolor', 'x-smallinherit')
:tag('table')
:css('padding', '0')
Line 340 ⟶ 341:
:css('text-align', 'center')
:css('background-color', titleBGcolor)
:css('text-aligncolor', 'centerinherit')
:wikitext(title)
:done() --end th
Line 348 ⟶ 350:
:attr('rowspan', '2')
:css('background-color', sideTitleBGcolor)
:css('font-sizecolor', 'x-smallinherit')
:css('width', '43px')
:wikitext(pdb_link)
Line 354 ⟶ 357:
:attr('colspan', '2')
:css('background-color', rowBGcolor)
:css('color', 'inherit')
:wikitext(searchTitle)
:tag('span')
Line 373 ⟶ 377:
:css('text-align', 'left')
:tag('tr')
:css('backgroundtext-coloralign', titleBGcolor'center')
:css('text-align', 'center')
:tag('th')
:css('background-color', 'transparent'titleBGcolor)
:css('color', 'inherit')
:attr('colspan', '2')
:wikitext(listTitle)
Line 384 ⟶ 389:
:attr('colspan', '2')
:css('background-color', rowBGcolor)
:css('color', 'inherit')
:tag('p')
:tag('span')
Line 493 ⟶ 499:
:css('text-align', 'center')
:css('background-color', titleBGcolor)
:css('font-sizecolor', 'x-smallinherit')
:wikitext(title)
:done() --end th
Line 500 ⟶ 507:
:attr('scope', 'row')
:css('background-color', sideTitleBGcolor)
:css('font-sizecolor', 'x-smallinherit')
:tag('span')
:attr('class', 'plainlinks')
Line 509 ⟶ 517:
:attr('colspan','3')
:css('background', rowBGcolor)
:css('color', 'inherit')
:tag('span')
:attr('class', 'plainlinks')
Line 522 ⟶ 531:
:attr('scope', 'row')
:css('background-color', sideTitleBGcolor)
:css('color', 'inherit')
:wikitext(label_ext_id)
:done() --end th
Line 527 ⟶ 537:
:attr('colspan', '3')
:css('background-color', rowBGcolor)
:css('color', 'inherit')
:tag('span')
:attr('class', 'plainlinks')
Line 540 ⟶ 551:
:attr('scope', 'row')
:css('background-color', sideTitleBGcolor)
:css('color', 'inherit')
:wikitext(label_EC)
:done() --end th
Line 545 ⟶ 557:
:attr('colspan', '3')
:css('background-color', rowBGcolor)
:tagcss('spancolor', 'inherit')
:tag('span')
:attr('class', 'plainlinks')
:wikitext(EC)
Line 577 ⟶ 590:
:css('text-align', 'center')
:css('background-color', rowBGcolor)
:css('color', 'inherit')
:tag('tr') --create title bar
:tag('th')
:attr('colspan', '3')
:css('text-align', 'center')
:css('background-color', titleBGcolor)
:css('color', 'inherit')
:wikitext(title)
:done() --end th
Line 597 ⟶ 612:
:css('text-align', 'center')
:css('background-color', rowBGcolor)
:css('color', 'inherit')
:tag('td')
:css('background-color', rowBGcolor)
:css('color', 'inherit')
:attr('scope', 'row')
:attr('colspan', '3')
Line 636 ⟶ 653:
:css('text-align', 'center')
:css('background-color', rowBGcolor)
:css('color', 'inherit')
:tag('tr') --create title bar
:tag('th')
Line 641 ⟶ 659:
:css('text-align', 'center')
:css('background-color', titleBGcolor)
:css('color', 'inherit')
:wikitext(title)
:done() --end th
Line 659 ⟶ 678:
:css('text-align', 'center')
:css('background-color', rowBGcolor)
:css('color', 'inherit')
:tag('td')
:css('background-color', rowBGcolor)
:css('color', 'inherit')
:attr('scope', 'row')
:attr('colspan', '3')
Line 793 ⟶ 814:
:css('text-align', 'center')
:css('background-color', rowBGcolor)
:css('color', 'inherit')
:tag('table')
:attr('class', 'collapsible collapsed')
Line 805 ⟶ 827:
:css('text-align', 'center')
:css('background-color', titleBGcolor)
:css('color', 'inherit')
:wikitext(titleHuman)
:done() --end th
Line 813 ⟶ 836:
:css('text-align', 'center')
:css('background-color', rowBGcolor)
:css('color', 'inherit')
:wikitext("[[File:Ideogram human chromosome "..chr..".svg|300px|"..chrText.."]]")
:done() --end td
:done() --end tr
Line 821 ⟶ 845:
:attr('width', '15%')
:css('background-color', sideTitleBGcolor)
:css('color', 'inherit')
:wikitext(label_chr)
:done() --end th
Line 827 ⟶ 852:
:attr('width', '85%')
:css('background-color', rowBGcolor)
:css('color', 'inherit')
:tag('span')
:attr('class', 'plainlinks')
Line 838 ⟶ 864:
:css('text-align', 'center')
:css('background-color', rowBGcolor)
:css('color', 'inherit')
:wikitext(wikitext_for_ideogram_image)
:done() --end td
Line 847 ⟶ 874:
:attr('width', '15%')
:css('background-color', sideTitleBGcolor)
:css('color', 'inherit')
:wikitext(label_locus)
:done() --end th
Line 853 ⟶ 881:
:attr('width', '35%')
:css('background-color', rowBGcolor)
:tagcss('spancolor', 'inherit')
:tag('span')
:attr('class', 'plainlinks')
:wikitext(cytoband)
Line 861 ⟶ 890:
:attr('scope', 'row')
:css('background-color', sideTitleBGcolor)
:css('color', 'inherit')
:wikitext(label_gstart)
:done() --end th
:tag('td')
:css('background-color', rowBGcolor)
:css('color', 'inherit')
:tag('span')
:attr('class', 'plainlinks')
Line 875 ⟶ 906:
:attr('scope', 'row')
:css('background-color', sideTitleBGcolor)
:css('color', 'inherit')
:wikitext(label_gend)
:done() --end th
:tag('td')
:css('background-color', rowBGcolor)
:css('color', 'inherit')
:tag('span')
:attr('class', 'plainlinks')
Line 993 ⟶ 1,026:
:css('text-align', 'center')
:css('background-color', rowBGcolor)
:css('color', 'inherit')
:tag('table')
:attr('class', 'collapsible collapsed')
Line 1,005 ⟶ 1,039:
:css('text-align', 'center')
:css('background-color', titleBGcolor)
:css('color', 'inherit')
:wikitext(titleMouse)
:done() --end th
Line 1,013 ⟶ 1,048:
:css('text-align', 'center')
:css('background-color', rowBGcolor)
:css('color', 'inherit')
:wikitext("[[File:Ideogram house mouse chromosome "..chr_mm..".svg|260px|"..chrText_mm.."]]")
:done() --end td
Line 1,021 ⟶ 1,057:
:attr('width', '15%')
:css('background-color', sideTitleBGcolor)
:css('color', 'inherit')
:wikitext(label_chr)
:done() --end th
Line 1,027 ⟶ 1,064:
:attr('width', '85%')
:css('background-color', rowBGcolor)
:css('color', 'inherit')
:tag('span')
:attr('class', 'plainlinks')
Line 1,038 ⟶ 1,076:
:css('text-align', 'center')
:css('background-color', rowBGcolor)
:css('color', 'inherit')
:wikitext(wikitext_for_ideogram_image_mm)
:done() --end td
Line 1,047 ⟶ 1,086:
:attr('width', '15%')
:css('background-color', sideTitleBGcolor)
:css('color', 'inherit')
:wikitext(label_locus)
:done() --end th
Line 1,053 ⟶ 1,093:
:attr('width', '35%')
:css('background-color', rowBGcolor)
:css('color', 'inherit')
:tag('span')
:attr('class', 'plainlinks')
Line 1,061 ⟶ 1,102:
:attr('scope', 'row')
:css('background-color', sideTitleBGcolor)
:css('color', 'inherit')
:wikitext(label_gstart)
:done() --end th
:tag('td')
:css('background-color', rowBGcolor)
:css('color', 'inherit')
:tag('span')
:attr('class', 'plainlinks')
Line 1,075 ⟶ 1,118:
:attr('scope', 'row')
:css('background-color', sideTitleBGcolor)
:css('color', 'inherit')
:wikitext(label_gend)
:done() --end th
:tag('td')
:css('background-color', rowBGcolor)
:css('color', 'inherit')
:tag('span')
:attr('class', 'plainlinks')
Line 1,163 ⟶ 1,208:
:css('text-align', 'center')
:css('background-color', rowBGcolor)
:css('color', 'inherit')
:tag('table')
:attr('class', 'collapsible collapsed')
Line 1,175 ⟶ 1,221:
:css('text-align', 'center')
:css('background-color', titleBGcolor)
:css('color', 'inherit')
:wikitext(title)
:done() --end th
Line 1,182 ⟶ 1,229:
:attr('scope', 'row')
:css('background-color', sideTitleBGcolor)
:css('color', 'inherit')
:wikitext(bgee_title)
:done() --end th
Line 1,275 ⟶ 1,323:
:css('text-align', 'center')
:css('background-color', rowBGcolor)
:css('color', 'inherit')
:tag('span')
:attr('class', 'plainlinks')
Line 1,288 ⟶ 1,337:
:attr('scope', 'row')
:css('background-color', sideTitleBGcolor)
:css('color', 'inherit')
:wikitext(biogps_title)
:done() --end th
Line 1,303 ⟶ 1,353:
:css('text-align', 'center')
:css('background-color', rowBGcolor)
:css('color', 'inherit')
:wikitext(expression_images)
:done() --end td
Line 1,311 ⟶ 1,362:
:css('text-align', 'center')
:css('background-color', rowBGcolor)
:css('color', 'inherit')
:tag('span')
:attr('class', 'plainlinks')
Line 1,340 ⟶ 1,392:
:css('text-align', 'center')
:css('background-color', rowBGcolor)
:css('color', 'inherit')
:tag('table')
:attr('class', 'collapsible collapsed')
Line 1,352 ⟶ 1,405:
:css('text-align', 'center')
:css('background-color', titleBGcolor)
:css('color', 'inherit')
:wikitext(title)
:done() --end th
Line 1,358 ⟶ 1,412:
:tag('td')
:css('background-color', sideTitleBGcolor)
:css('color', 'inherit')
:css('font-weight', 'bold')
:wikitext(mol_funct_title)
Line 1,363 ⟶ 1,418:
:tag('td')
:css('background-color', rowBGcolor)
:css('color', 'inherit')
:tag('div')
:attr('class', 'plainlinks')
Line 1,373 ⟶ 1,429:
:tag('td')
:css('background-color', sideTitleBGcolor)
:css('color', 'inherit')
:css('font-weight', 'bold')
:wikitext(cell_comp_title)
Line 1,378 ⟶ 1,435:
:tag('td')
:css('background-color', rowBGcolor)
:css('color', 'inherit')
:tag('div')
:attr('class', 'plainlinks')
Line 1,388 ⟶ 1,446:
:tag('td')
:css('background-color', sideTitleBGcolor)
:css('color', 'inherit')
:css('font-weight', 'bold')
:wikitext(bio_process_title)
Line 1,393 ⟶ 1,452:
:tag('td')
:css('background-color', rowBGcolor)
:css('color', 'inherit')
:tag('div')
:attr('class', 'plainlinks')
Line 1,404 ⟶ 1,464:
:tag('td')
:css('background-color', rowBGcolor)
:css('color', 'inherit')
:css('text-align', 'center')
:attr('colspan', '4')
Line 1,820 ⟶ 1,881:
:css('text-align', 'center')
:css('background-color', rowBGcolor)
:css('color', 'inherit')
:tag('table')
:attr('class', 'collapsible')
Line 1,832 ⟶ 1,894:
:css('text-align', 'center')
:css('background-color', titleBGcolor)
:css('color', 'inherit')
:wikitext(title)
:done() --end th
Line 1,839 ⟶ 1,902:
:attr('scope', 'row')
:css('background-color', sideTitleBGcolor)
:css('color', 'inherit')
:wikitext("Species") --**lclz**
:done() --end th
Line 1,852 ⟶ 1,916:
:attr('scope', 'row')
:css('background-color', sideTitleBGcolor)
:css('color', 'inherit')
:wikitext(entrezTitle)
:done() --end th
Line 1,915 ⟶ 1,980:
:attr('scope', 'row')
:css('background-color', sideTitleBGcolor)
:css('color', 'inherit')
:wikitext(ensemblTitle)
:done() --end th
Line 1,978 ⟶ 2,044:
:attr('scope', 'row')
:css('background-color', sideTitleBGcolor)
:css('color', 'inherit')
:wikitext(uniprotTitle)
:done() --end th
Line 2,041 ⟶ 2,108:
:attr('scope', 'row')
:css('background-color', sideTitleBGcolor)
:css('color', 'inherit')
:wikitext(refseq_mRNATitle)
:done() --end th
Line 2,104 ⟶ 2,172:
:attr('scope', 'row')
:css('background-color', sideTitleBGcolor)
:css('color', 'inherit')
:wikitext(refseq_protTitle)
:done() --end th
Line 2,167 ⟶ 2,236:
:attr('scope', 'row')
:css('background-color', sideTitleBGcolor)
:css('color', 'inherit')
:wikitext(locTitle)
:done() --end th
Line 2,186 ⟶ 2,256:
:attr('scope', 'row')
:css('background-color', sideTitleBGcolor)
:css('color', 'inherit')
:wikitext(pubmedTitle)
:done() --end th
Line 2,214 ⟶ 2,285:
:css('text-align', 'center')
:css('background-color', rowBGcolor)
:css('color', 'inherit')
:tag('table')
:css('padding', '0')
Line 2,222 ⟶ 2,294:
:tag('tr') --create title header
:css('background-color', titleBGcolor)
:css('color', 'inherit')
:css('text-align', 'center')
:tag('th')
Line 2,254 ⟶ 2,327:
:attr('colspan', '4')
:css('text-align', 'center')
:css('font-size','x-small')
:css('background-color', rowBGcolor)
:css('color', 'inherit')
:wikitext(text)
:done() --end td
Line 2,262 ⟶ 2,335:
:attr('colspan', '4')
:css('text-align', 'center')
:css('font-size','x-small')
:css('background-color', rowBGcolor)
:css('color', 'inherit')
:tag('table')
:css('padding', '0')
Line 2,274 ⟶ 2,347:
:attr('colspan', link_no_hs)
:css('background-color', rowBGcolor)
:css('color', 'inherit')
:css('text-align', 'center')
:css('font-size','x-small')
:wikitext(hs_link)
:done() --end td
Line 2,281 ⟶ 2,354:
:attr('colspan', link_no_mm)
:css('background-color', rowBGcolor)
:css('color', 'inherit')
:css('text-align', 'center')
:css('font-size','x-small')
:wikitext(mm_link)
:done() --end td
Line 2,298 ⟶ 2,371:
:attr('rowspan', '2')
:css('background-color', sideTitleBGcolor)
:css('color', 'inherit')
:css('width', '43px')
:wikitext(label)