Jump to content

Module:Message box/ambox.css: Difference between revisions

From BadWolfMC Wiki
Undo revision 6057 by Merc (talk)
Tag: Undo
No edit summary
Line 1: Line 1:
/* === ambox (merged from ombox) === */
/* {{pp|small=y}} */
/* {{pp|small=y}} */
.ambox {
.ambox {
border: 1px solid #a2a9b1;
    margin: 4px 0;
/* @noflip */
    border-collapse: collapse;
border-left: 10px solid #36c; /* Default "notice" blue */
    border: 1px solid #a2a9b1;                               /* Default “notice” gray */
background-color: #fbfbfb;
    background-color: var(--background-color-neutral-subtle, #f8f9fa);
box-sizing: border-box;
    box-sizing: border-box;
}
    color: var(--color-base, #202122);
 
/* Single border between stacked boxes. Take into account base templatestyles,
* user styles, and Template:Dated maintenance category.
* remove link selector when T200206 is fixed
*/
.ambox + link + .ambox,
.ambox + link + style + .ambox,
.ambox + link + link + .ambox,
/* TODO: raise these as "is this really that necessary???". the change was Dec 2021 */
.ambox + .mw-empty-elt + link + .ambox,
.ambox + .mw-empty-elt + link + style + .ambox,
.ambox + .mw-empty-elt + link + link + .ambox {
margin-top: -1px;
}
}


/* For the "small=left" option. */
/* For the "small=yes" option. */
/* must override .ambox + .ambox styles above */
.ambox.mbox-small {
html body.mediawiki .ambox.mbox-small-left {
    font-size: 88%;
/* @noflip */
    line-height: 1.25em;
margin: 4px 1em 4px 0;
overflow: hidden;
width: 238px;
border-collapse: collapse;
font-size: 88%;
line-height: 1.25em;
}
}


/* Speedy: red */
.ambox-speedy {
.ambox-speedy {
/* @noflip */
    /* @noflip */ border-left: 10px solid #b32424;
border-left: 10px solid #b32424;   /* Red */
    background-color: #fee7e6;
background-color: #fee7e6;         /* Pink */
}
}


/* Delete: red border only */
.ambox-delete {
.ambox-delete {
/* @noflip */
    /* @noflip */ border-left: 10px solid #b32424;
border-left: 10px solid #b32424;   /* Red */
}
}


/* Content: orange */
.ambox-content {
.ambox-content {
/* @noflip */
    /* @noflip */ border-left: 10px solid #f28500;
border-left: 10px solid #f28500;   /* Orange */
}
}


/* Style: yellow */
.ambox-style {
.ambox-style {
/* @noflip */
    /* @noflip */ border-left: 10px solid #fc3;
border-left: 10px solid #fc3;       /* Yellow */
}
}


/* Move: purple */
.ambox-move {
.ambox-move {
/* @noflip */
    /* @noflip */ border-left: 10px solid #9932cc;
border-left: 10px solid #9932cc;   /* Purple */
}
}


/* Protection: gray-gold */
.ambox-protection {
.ambox-protection {
/* @noflip */
    /* @noflip */ border-left: 10px solid #a2a9b1;
border-left: 10px solid #a2a9b1;   /* Gray-gold */
}
}


/* Inner structure */
.ambox .mbox-text {
.ambox .mbox-text {
border: none;
    border: none;
/* @noflip */
    /* @noflip */ padding: 0.25em 0.9em;
padding: 0.25em 0.5em;
    width: 100%;
width: 100%;
}
}
.ambox .mbox-image {
.ambox .mbox-image {
border: none;
    border: none;
/* @noflip */
    /* @noflip */ padding: 2px 0 2px 0.9em;
padding: 2px 0 2px 0.5em;
    text-align: center;
text-align: center;
}
}
.ambox .mbox-imageright {
.ambox .mbox-imageright {
border: none;
    border: none;
/* @noflip */
    /* @noflip */ padding: 2px 0.9em 2px 0;
padding: 2px 0.5em 2px 0;
    text-align: center;
text-align: center;
}
}
/* An empty narrow cell */
/* An empty narrow cell */
.ambox .mbox-empty-cell {
.ambox .mbox-empty-cell {
border: none;
    border: none;
padding: 0;
    padding: 0;
width: 1px;
    width: 1px;
}
}


.ambox .mbox-image-div {
/* Wide-screen centering */
width: 52px;
@media (min-width: 720px) {
    .ambox {
        margin: 4px 10%;
    }
    .ambox.mbox-small {
        /* @noflip */ clear: right;
        /* @noflip */ float: right;
        /* @noflip */ margin: 4px 0 4px 1em;
        width: 238px;
    }
}
}


@media (min-width: 720px) {
/* Hide in print on main namespace */
.ambox {
@media print {
margin: 0 10%;                 /* 10% = Will not overlap with other elements */
    body.ns-0 .ambox {
}
        display: none !important;
    }
}
}


@media print {
/* === Dark-mode tweak for speedy variant only === */
body.ns-0 .ambox {
@media screen {
display: none !important;
    html.skin-theme-clientpref-night .ambox-speedy {
}
        background-color: #310402; /* Dark red, same hue/sat as light */
    }
}
@media screen and (prefers-color-scheme: dark) {
    html.skin-theme-clientpref-os .ambox-speedy {
        background-color: #310402;
    }
}
}

Revision as of 05:39, 6 May 2025

/* === ambox (merged from ombox) === */

/* {{pp|small=y}} */
.ambox {
    margin: 4px 0;
    border-collapse: collapse;
    border: 1px solid #a2a9b1;                               /* Default “notice” gray */
    background-color: var(--background-color-neutral-subtle, #f8f9fa);
    box-sizing: border-box;
    color: var(--color-base, #202122);
}

/* For the "small=yes" option. */
.ambox.mbox-small {
    font-size: 88%;
    line-height: 1.25em;
}

/* Speedy: red */
.ambox-speedy {
    /* @noflip */ border-left: 10px solid #b32424;
    background-color: #fee7e6;
}

/* Delete: red border only */
.ambox-delete {
    /* @noflip */ border-left: 10px solid #b32424;
}

/* Content: orange */
.ambox-content {
    /* @noflip */ border-left: 10px solid #f28500;
}

/* Style: yellow */
.ambox-style {
    /* @noflip */ border-left: 10px solid #fc3;
}

/* Move: purple */
.ambox-move {
    /* @noflip */ border-left: 10px solid #9932cc;
}

/* Protection: gray-gold */
.ambox-protection {
    /* @noflip */ border-left: 10px solid #a2a9b1;
}

/* Inner structure */
.ambox .mbox-text {
    border: none;
    /* @noflip */ padding: 0.25em 0.9em;
    width: 100%;
}
.ambox .mbox-image {
    border: none;
    /* @noflip */ padding: 2px 0 2px 0.9em;
    text-align: center;
}
.ambox .mbox-imageright {
    border: none;
    /* @noflip */ padding: 2px 0.9em 2px 0;
    text-align: center;
}
/* An empty narrow cell */
.ambox .mbox-empty-cell {
    border: none;
    padding: 0;
    width: 1px;
}

/* Wide-screen centering */
@media (min-width: 720px) {
    .ambox {
        margin: 4px 10%;
    }
    .ambox.mbox-small {
        /* @noflip */ clear: right;
        /* @noflip */ float: right;
        /* @noflip */ margin: 4px 0 4px 1em;
        width: 238px;
    }
}

/* Hide in print on main namespace */
@media print {
    body.ns-0 .ambox {
        display: none !important;
    }
}

/* === Dark-mode tweak for speedy variant only === */
@media screen {
    html.skin-theme-clientpref-night .ambox-speedy {
        background-color: #310402; /* Dark red, same hue/sat as light */
    }
}
@media screen and (prefers-color-scheme: dark) {
    html.skin-theme-clientpref-os .ambox-speedy {
        background-color: #310402;
    }
}