Toggle menu
Toggle preferences menu
Toggle personal menu
Not logged in
Your IP address will be publicly visible if you make any edits.

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

From Wings of Fire Wiki
Fixes phab:T369874 via automated script
 
Add support for new Vector dark theme using CSS Variables
Line 1: Line 1:
/* {{pp|small=y}} */
/**
.imbox {
* {{imbox}} (image message box) styles
margin: 4px 0;
*
* @source https://www.mediawiki.org/wiki/MediaWiki:Gadget-enwp-boxes.css
* @revision 2021-07-15
*/
table.imbox {
margin: 4px 10%;
border-collapse: collapse;
border-collapse: collapse;
border: 3px solid #36c;    /* Default "notice" blue */
/* Default "notice" blue */
background-color: var(--background-color-interactive-subtle, #f8f9fa);  
border: 3px solid var(--border-color-progressive, #36c);
background-color: var(--background-color-neutral-subtle, #f8f9fa);
box-sizing: border-box;
box-sizing: border-box;
}
}
Line 10: Line 16:
/* For imboxes inside imbox-text cells. */
/* For imboxes inside imbox-text cells. */
.imbox .mbox-text .imbox {
.imbox .mbox-text .imbox {
margin: 0 -0.5em; /* 0.9 - 0.5 = 0.4em left/right. */
/* 0.9 - 0.5 = 0.4em left/right.       */
/* TODO: Still needed? */
margin: 0 -0.5em;
display: block; /* Fix for webkit to force 100% width.  */
/* Fix for webkit to force 100% width.  */
display: block;
}
}


.imbox-speedy {
/* For imboxes inside other templates.  */
border: 3px solid #b32424;    /* Red */
.mbox-inside .imbox {
background-color: #fee7e6;   /* Pink */
margin: 4px;
}
}


.imbox-delete {
/* An empty narrow cell */
border: 3px solid #b32424;    /* Red */
.imbox td.mbox-empty-cell {
}
border: none;
 
padding: 0;
.imbox-content {
width: 1px;
border: 3px solid #f28500;   /* Orange */
}
 
.imbox-style {
border: 3px solid #fc3;       /* Yellow */
}
}


.imbox-move {
/* The message body cell(s) */
border: 3px solid #9932cc;    /* Purple */
.imbox th.mbox-text,
}
.imbox td.mbox-text {
 
.imbox-protection {
border: 3px solid #a2a9b1;    /* Gray-gold */
}
 
.imbox-license {
border: 3px solid #88a;      /* Dark gray */
}
 
.imbox-featured {
border: 3px solid #cba135;    /* Brown-gold */
}
 
.imbox .mbox-text {
border: none;
border: none;
/* @noflip */
/* 0.9em left/right */
padding: 0.25em 0.9em;
padding: 0.25em 0.9em;
/* Make all mboxes the same width regardless of text length */
width: 100%;
width: 100%;
}
}


.imbox .mbox-image {
/* The left image cell */
border: none;
.imbox td.mbox-image {
/* 0.9em left, 0px right */
/* @noflip */
/* @noflip */
padding: 2px 0 2px 0.9em;
padding: 2px 0 2px 0.9em;
text-align: center;
}
}


.imbox .mbox-imageright {
/* The right image cell */
border: none;
.imbox td.mbox-imageright {
/* 0px left, 0.9em right */
/* @noflip */
/* @noflip */
padding: 2px 0.9em 2px 0;
padding: 2px 0.9em 2px 0;
text-align: center;
}
}


/* An empty narrow cell */
table.imbox-notice {
.imbox .mbox-empty-cell {
/* Blue */
border: none;
border-color: #36c;
padding: 0;
}
width: 1px;
 
table.imbox-speedy {
/* Pink */
background-color: #fee7e6;
/* temp fix for dark mode */
color: #222;
}
 
table.imbox-delete,
table.imbox-speedy {
/* Red */
border-left-color: var(--border-color-destructive, #bf3c2c);
border-bottom-color: var(--border-color-destructive, #bf3c2c);
border-right-color: var(--border-color-destructive, #bf3c2c);
border-top-color: var(--border-color-destructive, #bf3c2c);
}
}


.imbox .mbox-invalid-type {
table.imbox-content {
text-align: center;
/* Orange */
border-color: #f28500;
}
}


@media (min-width: 720px) {
table.imbox-style {
.imbox {
/* Yellow */
margin: 4px 10%;
border-color: #fc3;
}
}
}


table.imbox-move {
/* Purple */
border-color: #9932cc;
}


@media screen {
table.imbox-protection {
    html.skin-theme-clientpref-night .imbox-speedy {
/* Gray-gold */
background-color: #310402;   /* Dark red, same hue/saturation as light */
border-left-color: var(--border-color-base, #a2a9b1);
}
border-bottom-color: var(--border-color-base, #a2a9b1);
border-right-color: var(--border-color-base, #a2a9b1);
border-top-color: var(--border-color-base, #a2a9b1);
}
}


table.imbox-license {
/* Dark gray */
border-left-color: var(--border-color-notice, #72777d);
border-bottom-color: var(--border-color-notice, #72777d);
border-right-color: var(--border-color-notice, #72777d);
border-top-color: var(--border-color-notice, #72777d);
/* Light gray */
background-color: var(--background-color-neutral-subtle, #f8f9fa);
}


@media screen and ( prefers-color-scheme: dark) {
table.imbox-featured {
html.skin-theme-clientpref-os .imbox-speedy {
/* Brown-gold */
background-color: #310402; /* Dark red, same hue/saturation as light */
border-color: #cba135;
}
}
}

Revision as of 17:28, 26 November 2024

/**
 * {{imbox}} (image message box) styles
 *
 * @source https://www.mediawiki.org/wiki/MediaWiki:Gadget-enwp-boxes.css
 * @revision 2021-07-15
 */
table.imbox {
	margin: 4px 10%;
	border-collapse: collapse;
	/* Default "notice" blue */
	border: 3px solid var(--border-color-progressive, #36c);
	background-color: var(--background-color-neutral-subtle, #f8f9fa);
	box-sizing: border-box;
}

/* For imboxes inside imbox-text cells. */
.imbox .mbox-text .imbox {
	/* 0.9 - 0.5 = 0.4em left/right.        */
	margin: 0 -0.5em;
	/* Fix for webkit to force 100% width.  */
	display: block;
}

/* For imboxes inside other templates.  */
.mbox-inside .imbox {
	margin: 4px;
}

/* An empty narrow cell */
.imbox td.mbox-empty-cell {
	border: none;
	padding: 0;
	width: 1px;
}

/* The message body cell(s) */
.imbox th.mbox-text,
.imbox td.mbox-text {
	border: none;
	/* 0.9em left/right */
	padding: 0.25em 0.9em;
	/* Make all mboxes the same width regardless of text length */
	width: 100%;
}

/* The left image cell */
.imbox td.mbox-image {
	/* 0.9em left, 0px right */
	/* @noflip */
	padding: 2px 0 2px 0.9em;
}

/* The right image cell */
.imbox td.mbox-imageright {
	/* 0px left, 0.9em right */
	/* @noflip */
	padding: 2px 0.9em 2px 0;
}

table.imbox-notice {
	/* Blue */
	border-color: #36c;
}

table.imbox-speedy {
	/* Pink */
	background-color: #fee7e6;
	/* temp fix for dark mode */
	color: #222;
}

table.imbox-delete,
table.imbox-speedy {
	/* Red */
	border-left-color: var(--border-color-destructive, #bf3c2c);
	border-bottom-color: var(--border-color-destructive, #bf3c2c);
	border-right-color: var(--border-color-destructive, #bf3c2c);
	border-top-color: var(--border-color-destructive, #bf3c2c);
}

table.imbox-content {
	/* Orange */
	border-color: #f28500;
}

table.imbox-style {
	/* Yellow */
	border-color: #fc3;
}

table.imbox-move {
	/* Purple */
	border-color: #9932cc;
}

table.imbox-protection {
	/* Gray-gold */
	border-left-color: var(--border-color-base, #a2a9b1);
	border-bottom-color: var(--border-color-base, #a2a9b1);
	border-right-color: var(--border-color-base, #a2a9b1);
	border-top-color: var(--border-color-base, #a2a9b1);
}

table.imbox-license {
	/* Dark gray */
	border-left-color: var(--border-color-notice, #72777d);
	border-bottom-color: var(--border-color-notice, #72777d);
	border-right-color: var(--border-color-notice, #72777d);
	border-top-color: var(--border-color-notice, #72777d);
	/* Light gray */
	background-color: var(--background-color-neutral-subtle, #f8f9fa);
}

table.imbox-featured {
	/* Brown-gold */
	border-color: #cba135;
}
Cookies help us deliver our services. By using our services, you agree to our use of cookies.