Jump to content

MediaWiki:Mobile.css: Difference between revisions

From The Odd fellows Wiki
No edit summary
No edit summary
Line 1: Line 1:
/* =========================
/* =========================
   MOBILE WIKI OPTIMIZATION
   ACCESSIBLE MOBILE WIKI CSS
  Designed for readability
   ========================= */
   ========================= */


/* Prevent weird mobile zoom behavior */
/* Prevent iPhone text shrinking */
html {
html {
     -webkit-text-size-adjust: 100%;
     -webkit-text-size-adjust: 100%;
}
}


/* General body styling */
/* Main body text */
body,
body,
.mw-body,
.mw-body,
.vector-body {
.vector-body {
     font-size: 18px;
     font-size: 22px;
     line-height: 1.6;
     line-height: 1.8;
    font-family: sans-serif;
     max-width: 100%;
     max-width: 100%;
     overflow-x: hidden;
     overflow-x: hidden;
    padding-left: 14px;
    padding-right: 14px;
    box-sizing: border-box;
     word-wrap: break-word;
     word-wrap: break-word;
     overflow-wrap: break-word;
     overflow-wrap: break-word;
    box-sizing: border-box;
    padding-left: 10px;
    padding-right: 10px;
}
}


/* Paragraphs and lists */
/* Paragraphs */
p,
p,
li,
li,
Line 29: Line 31:
th {
th {
     font-size: 1rem;
     font-size: 1rem;
     line-height: 1.6;
     line-height: 1.8;
}
}


/* Headings */
/* Headings */
h1 {
h1 {
     font-size: 2rem;
     font-size: 2.2rem;
     line-height: 1.2;
     line-height: 1.2;
    margin-top: 0.5em;
}
}


h2 {
h2 {
     font-size: 1.6rem;
     font-size: 1.8rem;
     line-height: 1.3;
     line-height: 1.3;
    margin-top: 1em;
}
}


h3 {
h3 {
     font-size: 1.3rem;
     font-size: 1.5rem;
     line-height: 1.4;
     line-height: 1.4;
}
}


h4 {
/* Infobox */
     font-size: 1.1rem;
.infobox {
}
     float: none;
 
    width: 100%;
/* Images */
img {
     max-width: 100%;
     max-width: 100%;
     height: auto;
     margin: 1em 0;
    padding: 14px;
    border: 1px solid #aaa;
    background-color: #f9f9f9;
    box-sizing: border-box;
    font-size: 1rem;
}
}


Line 61: Line 68:
table {
table {
     width: 100%;
     width: 100%;
    max-width: 100%;
     display: block;
     display: block;
     overflow-x: auto;
     overflow-x: auto;
Line 67: Line 73:
}
}


/* Infobox styling */
/* Images */
.infobox {
img {
    float: none;
    width: 100%;
     max-width: 100%;
     max-width: 100%;
     margin: 1em 0;
     height: auto;
    padding: 10px;
    border: 1px solid #aaa;
    background-color: #f9f9f9;
    box-sizing: border-box;
    font-size: 1rem;
}
}


/* Infobox headers */
/* Links */
.infobox th {
a {
     text-align: left;
     word-break: break-word;
    font-weight: bold;
}
}


/* Sidebar cleanup */
/* Sidebar */
#mw-panel,
#mw-panel,
.vector-sidebar,
.vector-sidebar,
.vector-toc {
.vector-toc {
    width: 100%;
     font-size: 1rem;
     font-size: 1rem;
}
}


/* Navigation links */
/* Forms */
a {
input,
     word-break: break-word;
button,
select,
textarea {
     font-size: 1rem;
}
}


Line 104: Line 104:
     overflow-x: auto;
     overflow-x: auto;
     max-width: 100%;
     max-width: 100%;
     font-size: 0.95rem;
     font-size: 0.9rem;
}
 
/* Category links */
.catlinks {
    font-size: 0.95rem;
}
 
/* Search bar */
input[type="search"] {
    width: 100%;
    font-size: 1rem;
    box-sizing: border-box;
}
 
/* Buttons */
button,
input[type="submit"] {
    font-size: 1rem;
}
 
/* Prevent content overflow */
div,
span,
section {
    max-width: 100%;
    box-sizing: border-box;
}
}

Revision as of 22:57, 15 May 2026

/* =========================
   ACCESSIBLE MOBILE WIKI CSS
   Designed for readability
   ========================= */

/* Prevent iPhone text shrinking */
html {
    -webkit-text-size-adjust: 100%;
}

/* Main body text */
body,
.mw-body,
.vector-body {
    font-size: 22px;
    line-height: 1.8;
    font-family: sans-serif;
    max-width: 100%;
    overflow-x: hidden;
    padding-left: 14px;
    padding-right: 14px;
    box-sizing: border-box;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

/* Paragraphs */
p,
li,
td,
th {
    font-size: 1rem;
    line-height: 1.8;
}

/* Headings */
h1 {
    font-size: 2.2rem;
    line-height: 1.2;
    margin-top: 0.5em;
}

h2 {
    font-size: 1.8rem;
    line-height: 1.3;
    margin-top: 1em;
}

h3 {
    font-size: 1.5rem;
    line-height: 1.4;
}

/* Infobox */
.infobox {
    float: none;
    width: 100%;
    max-width: 100%;
    margin: 1em 0;
    padding: 14px;
    border: 1px solid #aaa;
    background-color: #f9f9f9;
    box-sizing: border-box;
    font-size: 1rem;
}

/* Tables */
table {
    width: 100%;
    display: block;
    overflow-x: auto;
    border-collapse: collapse;
}

/* Images */
img {
    max-width: 100%;
    height: auto;
}

/* Links */
a {
    word-break: break-word;
}

/* Sidebar */
#mw-panel,
.vector-sidebar,
.vector-toc {
    font-size: 1rem;
}

/* Forms */
input,
button,
select,
textarea {
    font-size: 1rem;
}

/* Code blocks */
pre,
code {
    overflow-x: auto;
    max-width: 100%;
    font-size: 0.9rem;
}