Jump to content

MediaWiki:Common.css: Difference between revisions

From λ LUMENWARD
No edit summary
No edit summary
Line 19: Line 19:


/* =========================================================
/* =========================================================
   Center the MediaWiki search bar (Vector 2022)
   Vector 2022 header layout
   Applies to all pages
   Logo left · Search centered · User tools right
   ========================================================= */
   ========================================================= */


/* Make header layout allow centering */
/* Turn header into a controlled 3-column grid */
.mw-header {
.mw-header {
   display: grid !important;
   display: grid !important;
   grid-template-columns: 1fr auto 1fr !important;
   grid-template-columns: auto minmax(300px, 720px) auto !important;
   align-items: center !important;
   align-items: center !important;
  column-gap: 16px !important;
}
}


/* Center the search container */
/* Logo stays on the left */
.mw-header #p-search,
.mw-header .mw-logo {
.mw-header .vector-search-box {
   justify-self: start !important;
   grid-column: 2 !important;
  margin-left: auto !important;
  margin-right: auto !important;
}
}


/* Prevent search from stretching oddly */
/* Search is centered */
.mw-header #p-search,
.mw-header .vector-search-box {
.mw-header .vector-search-box {
   max-width: 720px !important;
   justify-self: center !important;
   width: 100% !important;
   width: 100% !important;
}
}


/* Keep logo on the left */
/* User / account tools forced to the right */
.mw-header .mw-logo {
  grid-column: 1 !important;
}
 
/* Keep user tools on the right */
.mw-header .vector-user-links,
.mw-header .vector-user-links,
.mw-header .mw-header-user {
.mw-header .mw-header-user,
  grid-column: 3 !important;
.mw-header .vector-user-menu,
.mw-header .vector-user-menu-container {
   justify-self: end !important;
   justify-self: end !important;
  margin-left: auto !important;
}
}

Revision as of 19:13, 13 December 2025

/* SAFE BASELINE */

/* Text logo black */
.mw-logo,
.mw-logo a,
.mw-logo a:visited,
.mw-logo a:hover,
.mw-logo a:active {
  color: #000 !important;
}
.mw-logo a:hover { text-decoration: none !important; }

/* Remove Powered by MediaWiki safely */
#footer-poweredby,
#footer-poweredbyico,
.mw-poweredby {
  display: none !important;
}

/* =========================================================
   Vector 2022 header layout
   Logo left · Search centered · User tools right
   ========================================================= */

/* Turn header into a controlled 3-column grid */
.mw-header {
  display: grid !important;
  grid-template-columns: auto minmax(300px, 720px) auto !important;
  align-items: center !important;
  column-gap: 16px !important;
}

/* Logo stays on the left */
.mw-header .mw-logo {
  justify-self: start !important;
}

/* Search is centered */
.mw-header #p-search,
.mw-header .vector-search-box {
  justify-self: center !important;
  width: 100% !important;
}

/* User / account tools forced to the right */
.mw-header .vector-user-links,
.mw-header .mw-header-user,
.mw-header .vector-user-menu,
.mw-header .vector-user-menu-container {
  justify-self: end !important;
  margin-left: auto !important;
}