MediaWiki:Mobile.css: Difference between revisions

From PoliticalSG
No edit summary
No edit summary
 
(2 intermediate revisions by the same user not shown)
Line 1: Line 1:
/* All CSS here will be loaded for users of the mobile site */
/* All CSS here will be loaded for users of the mobile site */
/* Make Infobox Full Width on Mobile */
/* Make Infobox Full Width on Mobile */
@media screen and (max-width: 600px) {
.infobox-container {
    .infobox-container {
    float: none !important;
        width: 100%; /* Full width */
    width: 100% !important;
        max-width: 100%;
    max-width: 100% !important;
        float: none; /* No float on mobile */
    overflow: visible !important;
        margin: 0 auto;
    margin: 15px 0 !important;
        clear: both;
    clear: both !important;
     }
    display: block !important;
}
.infobox-table,
.infobox-container table.wikitable {
    width: 100% !important;
     font-size: 14px;
    display: table !important;
}
.infobox-image img {
    max-width: 100%;
    height: auto;
}


     .infobox-table {
/* Override inline styles on the infobox div (written by template) */
        font-size: 14px;
div[style*="width:30%"],
     }
div[style*="width: 30%"],
div[style*="float:right"],
div[style*="float: right"] {
    float: none !important;
     width: 100% !important;
    max-width: 100% !important;
    overflow: visible !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
    margin-top: 15px !important;
    margin-bottom: 15px !important;
    clear: both !important;
    display: block !important;
}
div[style*="width:30%"] table.wikitable,
div[style*="width: 30%"] table.wikitable,
div[style*="float:right"] table.wikitable,
div[style*="float: right"] table.wikitable {
    width: 100% !important;
     display: table !important;
}


     .infobox-image img {
.infobox-person {
        max-width: 100%;
    float: none !important;
        height: auto;
     width: 100% !important;
     }
    max-width: 100% !important;
    margin: 0 0 1em 0 !important;
    clear: both !important;
    display: block !important;
    box-sizing: border-box !important;
}
.infobox-person table {
    width: 100% !important;
}
 
.infobox-political-party {
    float: none !important;
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100% !important;
    margin: 0 0 1em 0 !important;
    clear: both !important;
     display: block !important;
    box-sizing: border-box !important;
}
.infobox-political-party table {
    width: 100% !important;
}
}

Latest revision as of 12:48, 24 May 2026

/* All CSS here will be loaded for users of the mobile site */
/* Make Infobox Full Width on Mobile */
.infobox-container {
    float: none !important;
    width: 100% !important;
    max-width: 100% !important;
    overflow: visible !important;
    margin: 15px 0 !important;
    clear: both !important;
    display: block !important;
}
.infobox-table,
.infobox-container table.wikitable {
    width: 100% !important;
    font-size: 14px;
    display: table !important;
}
.infobox-image img {
    max-width: 100%;
    height: auto;
}

/* Override inline styles on the infobox div (written by template) */
div[style*="width:30%"],
div[style*="width: 30%"],
div[style*="float:right"],
div[style*="float: right"] {
    float: none !important;
    width: 100% !important;
    max-width: 100% !important;
    overflow: visible !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
    margin-top: 15px !important;
    margin-bottom: 15px !important;
    clear: both !important;
    display: block !important;
}
div[style*="width:30%"] table.wikitable,
div[style*="width: 30%"] table.wikitable,
div[style*="float:right"] table.wikitable,
div[style*="float: right"] table.wikitable {
    width: 100% !important;
    display: table !important;
}

.infobox-person {
    float: none !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 0 1em 0 !important;
    clear: both !important;
    display: block !important;
    box-sizing: border-box !important;
}
.infobox-person table {
    width: 100% !important;
}

.infobox-political-party {
    float: none !important;
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100% !important;
    margin: 0 0 1em 0 !important;
    clear: both !important;
    display: block !important;
    box-sizing: border-box !important;
}
.infobox-political-party table {
    width: 100% !important;
}