MediaWiki:Common.css: Difference between revisions

No edit summary
No edit summary
 
(7 intermediate revisions by the same user not shown)
Line 144: Line 144:


/* ── INFOBOX — suppress phantom leading paragraphs ── */
/* ── INFOBOX — suppress phantom leading paragraphs ── */
/* MediaWiki generates <p><br></p> nodes from template newlines */
/* Use descendant selector (space, not >) so Minerva's
#mw-content-text > .mw-parser-output > p:empty,
  .mf-section-0 wrapper doesn't break the match        */
#mw-content-text > .mw-parser-output > p:has(> br:only-child) {
.mw-parser-output p:empty,
.mw-parser-output p:has(> br:only-child) {
     display: none;
     display: none;
     margin: 0;
     margin: 0;
Line 152: Line 153:
}
}


/* hide leading breaks generated by template newlines */
.mw-parser-output br:first-child {
#mw-content-text > .mw-parser-output > br:first-child,
    display: none;
#mw-content-text > .mw-parser-output > p:first-child > br:only-child {
}
 
.mw-parser-output > br:first-child {
     display: none;
     display: none;
}
}
Line 257: Line 260:
.bs-stat-blue .bs-stat-number { color: var(--bs-blue-800); }
.bs-stat-blue .bs-stat-number { color: var(--bs-blue-800); }
.bs-stat-blue .bs-stat-label  { color: var(--bs-blue-400); }
.bs-stat-blue .bs-stat-label  { color: var(--bs-blue-400); }
.bs-stat-pink {
    background: var(--bs-pink-50);
    border-color: var(--bs-pink-200);
}
.bs-stat-pink .bs-stat-number { color: var(--bs-pink-800); }
.bs-stat-pink .bs-stat-label  { color: var(--bs-pink-200); }


/* ══════════════════════════════════════════════════════
/* ══════════════════════════════════════════════════════
Line 494: Line 504:
     color: var(--bs-gray-400);
     color: var(--bs-gray-400);
     text-align: center;
     text-align: center;
}
/* ══════════════════════════════════════════════════════
  LICENSE BOX
══════════════════════════════════════════════════════ */
.license-box {
    padding: 6px 10px;
    border: 1px solid var(--bs-gray-200);
    background: var(--bs-gray-50);
    color: var(--bs-text-primary);
    font-size: 0.9em;
    margin: 0.5em 0;
    border-radius: 4px;
}
.license-box-title {
    font-weight: 500;
    margin-bottom: 0.3em;
}
}


Line 591: Line 619:
         color-scheme: dark;
         color-scheme: dark;
     }
     }
/* ── Stat ribbon — pink tile ────────────────────── */
.bs-stat-pink .bs-stat-label { color: var(--bs-pink-800); }


     /* ── Article content area ───────────────────────── */
     /* ── Article content area ───────────────────────── */
Line 654: Line 684:
         border-left-color: var(--bs-purple-200);
         border-left-color: var(--bs-purple-200);
         color: var(--bs-text-muted);
         color: var(--bs-text-muted);
    }
/* ── Image / thumb frames ───────────────────────── */
    .thumb,
    div.thumb,
    .thumbinner,
    div.thumbinner,
    figure.mw-halign-right,
    figure.mw-halign-left,
    figure.mw-halign-none,
    figure.mw-halign-center,
        .mw-parser-output figure {
        border-color: #3a3a38 !important;
        /* no background — transparent PNGs show through correctly */
}
    .thumbcaption,
    figcaption {
        color: var(--bs-text-muted) !important;
        background: transparent !important;
    }
    /* ── Edit page — textarea and toolbar ───────────── */
    #wpTextbox1,
    .mw-editfont-default,
    textarea.mw-editfont-default {
        background-color: #1e1e1c;
        color: var(--bs-text-primary);
        border-color: #3a3a38;
    }
    #toolbar,
    #wpSummary,
    input#wpSummary {
        background-color: #252523;
        color: var(--bs-text-primary);
        border-color: #3a3a38;
    }
    /* ── License box ────────────────────────────────── */
    /* Variables auto-remap via :root dark block above;
      explicit override ensures border/bg aren't
      overridden by any #content table rule above.    */
    .license-box {
        background: var(--bs-gray-50) !important;
        border-color: var(--bs-gray-200) !important;
        color: var(--bs-text-primary) !important;
     }
     }


Line 704: Line 779:
         border-bottom: 1px solid #333331;
         border-bottom: 1px solid #333331;
     }
     }
    /* ── Image frames & captions ────────────────────── */
    /* Dark mode for image frames is deferred — caption text darkened via base styles instead */


     /* ── Watchlist star ─────────────────────────────── */
     /* ── Watchlist star ─────────────────────────────── */
Line 723: Line 795:
         background-color: transparent !important;
         background-color: transparent !important;
     }
     }


     #mw-panel,
     #mw-panel,