Jump to content

User:ChaseT/vector-2022.css: Difference between revisions

From Wikipedia, the free encyclopedia
Content deleted Content added
ChaseT (talk | contribs)
No edit summary
Tag: Reverted
ChaseT (talk | contribs)
No edit summary
Tag: Reverted
Line 1: Line 1:
/* Main container adjustments */
/* Base styles for large screens: the width is fixed to the equivalent of 65 characters */
.mw-body {
display: flex; /* Enable flexbox */
justify-content: center; /* Center the content */
}

/* Content area styles for a maximum width */
#content {
#content {
max-width: 780px; /* Adjust this to match the width for 65 characters in your font */
max-width: 780px; /* Set the max-width to the width for 65 characters */
margin: 0 auto; /* This centers the content */
box-sizing: border-box; /* Include padding and border in the element's width */
}

/* Left sidebar adjustments */
#mw-panel {
order: -1; /* Place the sidebar before the content in the flex flow */
flex-shrink: 0; /* Prevent the sidebar from shrinking */
padding-right: 10px; /* Optional padding to create space between the sidebar and content */
}
}


/* Styles for screens smaller than the content max-width */
/* Media query for smaller screens */
@media screen and (max-width: 780px) {
@media screen and (max-width: 780px) {
#content {
#content {
width: auto; /* Allows content to shrink on smaller screens */
width: 100%; /* Allow content to take full width on smaller screens */
margin: 0 auto; /* Keeps content centered */
padding: 0 10px; /* Add padding to keep content from touching the edges */
}
}
}
}

Revision as of 20:34, 8 December 2023

/* Main container adjustments */
.mw-body {
  display: flex; /* Enable flexbox */
  justify-content: center; /* Center the content */
}

/* Content area styles for a maximum width */
#content {
  max-width: 780px; /* Set the max-width to the width for 65 characters */
  box-sizing: border-box; /* Include padding and border in the element's width */
}

/* Left sidebar adjustments */
#mw-panel {
  order: -1; /* Place the sidebar before the content in the flex flow */
  flex-shrink: 0; /* Prevent the sidebar from shrinking */
  padding-right: 10px; /* Optional padding to create space between the sidebar and content */
}

/* Media query for smaller screens */
@media screen and (max-width: 780px) {
  #content {
    width: 100%; /* Allow content to take full width on smaller screens */
    padding: 0 10px; /* Add padding to keep content from touching the edges */
  }
}