FANDOM


--       The existing StyleInjection is particularly hacky and inefficient way to 
--       make CSS styled elements (Navbox, Article Footer, etc.) render in mobile.
--       This can be done much better in Lua rather than the <verbatim /> workaround.
--       Not only can it be invoked from an element, it can be added in relevant portions. 
local StyleInjection = {}
 
function StyleInjection.main()
local style = mw.html.create( 'style' )
-- Preamble and basics
style:wikitext( '/* This URL is a combined set of SCSS files, which should be compiled and placed into [[MediaWiki:StyleInjection]]. A service to do this manually is [http://sassmeister.com/ SassMeister]. */' )
style:wikitext( '/* @import url("http://americanhorrorstory.wikia.com/load.php?mode=articles&articles=local%3AMediaWiki%3AMixin.scss%7Clocal%3AMediaWiki%3ALayout.scss%7Clocal%3AMediaWiki%3ANavbox.scss%7Clocal%3AMediaWiki%3ACharPortal.scss%7Clocal%3AMediaWiki%3AHlist.css&only=styles") */' )
style:wikitext( '@charset "UTF-8";' )
style:wikitext( '.plainlist ul{line-height:inherit;list-style:none none;margin:0}' )
style:wikitext( '.plainlist ul li{margin-bottom:0}' )
style:wikitext( '.force-blk-bkg{color:white;background-color:black;text-align:center}' )
style:wikitext( '.undisplayedtext{display:none}' )
style:wikitext( '@media print{.ambox{display:none}' )
style:wikitext( '.asbox{display:none}}' )
-- Fancy and Graphic Headers
style:wikitext( '.fancyheader,h2.graphic,h2.highlight,h3.graphic,h3.highlight{overflow:auto;padding:0.3em 0.4em 0.2em 0.4em;border:none;font-weight:bold;text-align:center;-webkit-border-radius:0.5em;-moz-border-radius:0.5em;border-radius:0.5em;background:#880d08;color:white}' )
style:wikitext( 'h2.graphic,h2.highlight{font-size:150%}' )
style:wikitext( 'h3.graphic,h3.highlight{font-size:125%}' )
-- Article Footer
style:wikitext( 'div.article-footer,footer.article-footer{display:-webkit-box;display:-moz-box;display:-ms-flexbox;display:-webkit-flex;display:flex;-webkit-box-direction:normal;-moz-box-direction:normal;-webkit-box-orient:horizontal;-moz-box-orient:horizontal;-webkit-flex-direction:row;-ms-flex-direction:row;flex-direction:row;-webkit-flex-wrap:wrap;-ms-flex-wrap:wrap;flex-wrap:wrap;-webkit-box-pack:justify;-moz-box-pack:justify;-webkit-justify-content:space-around;-ms-flex-pack:distribute;justify-content:space-around;-webkit-align-content:flex-start;-ms-flex-line-pack:start;align-content:flex-start;-webkit-box-align:start;-moz-box-align:start;-webkit-align-items:flex-start;-ms-flex-align:start;align-items:flex-start}' )
style:wikitext( 'div.article-footer div.footer-item,footer.article-footer div.footer-item{display:-webkit-box;display:-moz-box;display:-ms-flexbox;display:-webkit-flex;display:flex;-webkit-box-direction:normal;-moz-box-direction:normal;-webkit-box-orient:vertical;-moz-box-orient:vertical;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;-webkit-flex-wrap:nowrap;-ms-flex-wrap:nowrap;flex-wrap:nowrap;-webkit-box-pack:start;-moz-box-pack:start;-webkit-justify-content:flex-start;-ms-flex-pack:start;justify-content:flex-start;-webkit-align-content:flex-start;-ms-flex-line-pack:start;align-content:flex-start;-webkit-box-align:start;-moz-box-align:start;-webkit-align-items:flex-start;-ms-flex-align:start;align-items:flex-start;min-width:20%}' )
-- Flex
style:wikitext( 'div.mainpage-row{display:-webkit-box;display:-moz-box;display:-ms-flexbox;display:-webkit-flex;display:flex;-webkit-box-direction:normal;-moz-box-direction:normal;-webkit-box-orient:horizontal;-moz-box-orient:horizontal;-webkit-flex-direction:row;-ms-flex-direction:row;flex-direction:row;-webkit-flex-wrap:wrap;-ms-flex-wrap:wrap;flex-wrap:wrap;-webkit-box-pack:justify;-moz-box-pack:justify;-webkit-justify-content:space-around;-ms-flex-pack:distribute;justify-content:space-around;-webkit-align-content:space-around;-ms-flex-line-pack:distribute;align-content:space-around;-webkit-box-align:center;-moz-box-align:center;-webkit-align-items:center;-ms-flex-align:center;align-items:center;text-align:center}' )
style:wikitext( '.flexcolumn{display:-webkit-box;display:-moz-box;display:-ms-flexbox;display:-webkit-flex;display:flex;-webkit-box-direction:normal;-moz-box-direction:normal;-webkit-box-orient:horizontal;-moz-box-orient:horizontal;-webkit-flex-direction:row;-ms-flex-direction:row;flex-direction:row;-webkit-flex-wrap:wrap;-ms-flex-wrap:wrap;flex-wrap:wrap;-webkit-box-pack:justify;-moz-box-pack:justify;-webkit-justify-content:space-between;-ms-flex-pack:justify;justify-content:space-between;-webkit-align-content:flex-start;-ms-flex-line-pack:start;align-content:flex-start;-webkit-box-align:start;-moz-box-align:start;-webkit-align-items:flex-start;-ms-flex-align:start;align-items:flex-start}' )
style:wikitext( '.flexcolumn div{-webkit-box-flex:1;-moz-box-flex:1;-webkit-flex:1;-ms-flex:1;flex:1}' )
-- Mobile
style:wikitext( '.wkMobile th.navbox-group{text-align:center; width:10em; padding:0.25em}' )
style:wikitext( '.wkMobile .navbox-list{line-height:1em}' )
style:wikitext( '.wkMobile th.navbox-title>span{line-height:0px;display:none}' )
style:wikitext( '.wkMobile .navbox-image img{display:none}' )
style:wikitext( '.wkMobile th.navbox-title{text-align:center}' )
style:wikitext( '.wkMobile th.wikia-infobox-section-header{text-align:center}' )
style:wikitext( '.wkMobile table.wikia-infobox th{vertical-align:top}' )
style:wikitext( '.wkMobile .mleft{text-align:left}' )
style:wikitext( '.wkMobile .mcenter{text-align:center}' )
style:wikitext( '.wkMobile .mright{text-align:right}' )
-- Navbox
style:wikitext( 'table.vertical-navbox{-webkit-border-radius:0.5em;-moz-border-radius:0.5em;border-radius:0.5em;font-size:85%;border:5px solid #880d08;white-space:nowrap;padding:0.2em;border-spacing:0.4em 0;text-align:center;line-height:1.4em}' )
style:wikitext( 'table.vertical-navbox caption{font-size:150%;border:5px;font-weight:bold;padding-bottom:0.2em;line-height:1.2em}' )
style:wikitext( 'table.vertical-navbox th{text-align:center;vertical-align:top;font-weight:bolder}' )
style:wikitext( 'table.vertical-navbox th.sectionhead{font-size:120%;text-align:center;border:1px solid #880d08}table.vertical-navbox th.bright{color:white}' )
style:wikitext( '.navbox{border:1px solid #880d08;background-color:#000000;width:100%;margin:auto;clear:both;font-size:88%;text-align:center;padding:1px;-webkit-border-radius:1em;-moz-border-radius:1em;border-radius:1em}' )
style:wikitext( '.navbox-inner,.navbox-subgroup{width:100%}' )
style:wikitext( '.navbox-group,.navbox-title,.navbox-abovebelow{padding:0.25em 1em;line-height:1.5em;text-align:center}' )
style:wikitext( 'th.navbox-group{white-space:nowrap;text-align:right}' )
style:wikitext( '.navbox,.navbox-subgroup{background:transparent}' )
style:wikitext( '.navbox-list{line-height:1.8em;border-color:#f9f9f9}' )
style:wikitext( '.navbox th,.navbox-title{background:#880d08}' )
style:wikitext( '.navbox-abovebelow,th.navbox-group,.navbox-subgroup .navbox-title{background:#880000}' )
style:wikitext( '.navbox-subgroup .navbox-group,.navbox-subgroup .navbox-abovebelow{background:#808080}' )
style:wikitext( '.navbox-even{background:#f7f7f7}' )
style:wikitext( '.navbox-odd{background:transparent}' )
style:wikitext( 'table.navbox+table.navbox{margin-top:-1px}' )
style:wikitext( '.navbox .hlist td dl,.navbox .hlist td ol,.navbox .hlist td ul,.navbox td.hlist dl,.navbox td.hlist ol,.navbox td.hlist ul{padding:0.125em 0}' )
style:wikitext( 'ol+table.navbox,ul+table.navbox{margin-top:0.5em}' )
style:wikitext( '.navbar{display:inline;font-size:88%;font-weight:normal}' )
style:wikitext( '.navbar ul{display:inline;white-space:nowrap}' )
style:wikitext( '.navbar li{word-spacing:-0.125em}' )
style:wikitext( '.navbar.mini li span{font-variant:small-caps}' )
style:wikitext( '.infobox .navbar{font-size:100%}' )
style:wikitext( '.navbox .navbar{display:block;font-size:100%}' )
style:wikitext( '.navbox-title .navbar{float:left;text-align:left;margin-right:0.5em;width:6em}' )
style:wikitext( '.collapseButton{float:right;font-weight:normal;margin-left:0.5em;text-align:right;width:auto}' )
style:wikitext( '.navbox .collapseButton{width:6em}' )
-- CharPortal
style:wikitext( 'div.charportal-grid-row{display:-webkit-box;display:-moz-box;display:-ms-flexbox;display:-webkit-flex;display:flex;-webkit-box-direction:normal;-moz-box-direction:normal;-webkit-box-orient:horizontal;-moz-box-orient:horizontal;-webkit-flex-direction:row;-ms-flex-direction:row;flex-direction:row;-webkit-flex-wrap:wrap;-ms-flex-wrap:wrap;flex-wrap:wrap;-webkit-box-pack:start;-moz-box-pack:start;-webkit-justify-content:flex-start;-ms-flex-pack:start;justify-content:flex-start;-webkit-align-content:stretch;-ms-flex-line-pack:stretch;align-content:stretch;-webkit-box-align:stretch;-moz-box-align:stretch;-webkit-align-items:stretch;-ms-flex-align:stretch;align-items:stretch}' )
style:wikitext( 'div.charportal-grid-row table.charportal{-webkit-box-flex:1;-moz-box-flex:1;-webkit-flex:1;-ms-flex:1;flex:1}' )
style:wikitext( 'table.charportal{background:#880d08; border:1px solid black; -webkit-border-radius:5px; -moz-border-radius:5px; border-radius:5px}' )
style:wikitext( 'table.charportal div.envelope{ position:relative; height:90px; width:100px}' )
style:wikitext( 'table.charportal div.envelope div.porthole{position:absolute;top:0px;left:0px;height:90px;width:100px;overflow:hidden}' )
style:wikitext( 'table.charportal div.envelope div.porthole div.contents{position:absolute;top:0px;left:0px;font-size:130px;overflow:hidden;line-height:100px;z-index:3}' )
style:wikitext( 'table.charportal div.envelope div.porthole div.theimage{position:absolute;top:0px;left:0px;z-index:2}' )
style:wikitext( 'table.charportal div.envelope div.label-fullbackground{position:absolute;top:77px;left:0px;width:100px;overflow:hidden;line-height:12px;z-index:4;text-align:right}' )
style:wikitext( 'table.charportal div.envelope div.label-fullbackground table.label-text{background:white;-webkit-border-top-left-radius:8px;-webkit-border-top-right-radius:0;-moz-border-radius-topleft:8px;-moz-border-radius-topright:0;border-top-left-radius:8px;border-top-right-radius:0}' )
-- Hlist
style:wikitext( '.skin-monobook .hlist dl,.skin-modern .hlist dl,.skin-vector .hlist dl{line-height:1.5em}' )
style:wikitext( '.hlist dl,.hlist ol,.hlist ul{margin:0;padding:0}' )
style:wikitext( '.hlist dd,.hlist dt,.hlist li{margin:0;display:inline;white-space:nowrap}' )
style:wikitext( '.hlist.hwrap dd,.hlist.hwrap dt,.hlist.hwrap li{white-space:normal}' )
style:wikitext( '.hlist dl dl,.hlist dl ol,.hlist dl ul,.hlist ol dl,.hlist ol ol,.hlist ol ul,.hlist ul dl,.hlist ul ol,.hlist ul ul{display:inline;white-space:normal}' )
style:wikitext( '.hlist dt:after{content:":"}' )
style:wikitext( '.hlist dd:after,.hlist li:after{content:" ·";font-weight:bold}' )
style:wikitext( '.hlist dd:last-child:after,.hlist dt:last-child:after,.hlist li:last-child:after{content:none}' )
style:wikitext( '.hlist dd.hlist-last-child:after,.hlist dt.hlist-last-child:after,.hlist li.hlist-last-child:after{content:none}' )
style:wikitext( '.hlist dd dd:first-child:before,.hlist dd dt:first-child:before,.hlist dd li:first-child:before,.hlist dt dd:first-child:before,.hlist dt dt:first-child:before,.hlist dt li:first-child:before,.hlist li dd:first-child:before,.hlist li dt:first-child:before,.hlist li li:first-child:before{content:"(";font-weight:normal}' )
style:wikitext( '.hlist dd dd:last-child:after,.hlist dd dt:last-child:after,.hlist dd li:last-child:after,.hlist dt dd:last-child:after,.hlist dt dt:last-child:after,.hlist dt li:last-child:after,.hlist li dd:last-child:after,.hlist li dt:last-child:after,.hlist li li:last-child:after{content:")";font-weight:normal}' )
style:wikitext( '.hlist dd dd.hlist-last-child:after,.hlist dd dt.hlist-last-child:after,.hlist dd li.hlist-last-child:after,.hlist dt dd.hlist-last-child:after,.hlist dt dt.hlist-last-child:after,.hlist dt li.hlist-last-child:after,.hlist li dd.hlist-last-child:after,.hlist li dt.hlist-last-child:after,.hlist li li.hlist-last-child:after{content:")";font-weight:normal}' )
style:wikitext( '.hlist.hnum ol{counter-reset:list-item}' )
style:wikitext( '.hlist.hnum ol>li{counter-increment:list-item}' )
style:wikitext( '.hlist.hnum ol>li:before{content:counter(list-item) " "}' )
style:wikitext( '.hlist.hnum dd ol>li:first-child:before,.hlist.hnum dt ol>li:first-child:before,.hlist.hnum li ol>li:first-child:before{content:"(" counter(list-item) " "}' )
return tostring( style )
end
return StyleInjection

Ad blocker interference detected!


Wikia is a free-to-use site that makes money from advertising. We have a modified experience for viewers using ad blockers

Wikia is not accessible if you’ve made further modifications. Remove the custom ad blocker rule(s) and the page will load as expected.