MediaWiki:Common.css: Difference between revisions

From Ikwipedia
No edit summary
Tag: Reverted
No edit summary
Tag: Reverted
Line 1: Line 1:
/* CSS placed here will be applied to all skins */
/* CSS placed here will be applied to all skins */
#p-logo a {
/* Enforce logo size and behavior across all pages */
.mw-wiki-logo {
     background-size: contain;
     background-size: contain;
     background-position: center;
     background-position: center center;
     background-repeat: no-repeat;
     background-repeat: no-repeat;
}
#p-logo a img {
     width: 100%;
     width: 100%;
     height: auto;
     height: auto;
     max-width: 135px; /* Set max width as per your layout */
     max-width: 135px;
     max-height: 135px; /* Set max height if needed */
     max-height: 135px;
    object-fit: contain; /* Scales the logo to fit the space */
}
}
body.special-page #p-logo a img,
 
body.login-page #p-logo a img {
/* Apply size and positioning on special pages */
     width: 100%;
body.special-page .mw-wiki-logo,
body.login-page .mw-wiki-logo {
     background-size: contain;
    background-position: center;
     max-width: 135px;
     max-width: 135px;
     max-height: 135px;
     max-height: 135px;
    object-fit: contain;
    object-position: center;
}
}

Revision as of 03:01, 4 November 2024

/* CSS placed here will be applied to all skins */
/* Enforce logo size and behavior across all pages */
.mw-wiki-logo {
    background-size: contain;
    background-position: center center;
    background-repeat: no-repeat;
    width: 100%;
    height: auto;
    max-width: 135px;
    max-height: 135px;
}

/* Apply size and positioning on special pages */
body.special-page .mw-wiki-logo,
body.login-page .mw-wiki-logo {
    background-size: contain;
    background-position: center;
    max-width: 135px;
    max-height: 135px;
}