MediaWiki:Medik.css: Difference between revisions

From Makerpedia

Chetitac (talk | contribs)
No edit summary
No edit summary
 
(125 intermediate revisions by 4 users not shown)
Line 2: Line 2:


/* css from Aaron */
/* css from Aaron */
@font-face {
  font-family: georgia;
  src: url(images/fonts/georgia.ttf);
}
body {
body {
   height: 100%;
   height: 100%;
  --cc-white: #edeff7;
  --cc-blue: #003069;
}
.bg-ws {
  background-color: var(--cc-blue);
}
#p-banner {
  font-family: georgia;
  font-weight: 100;
}
#mw-navigation {
  background-color: var(--cc-blue);
}
#mw-main-container .row {
  background-color: var(--cc-white);
}
}


Line 74: Line 98:
   padding-bottom: .75em;
   padding-bottom: .75em;
}
}
/* end of css from Aaron */


/* top navigation */
#mw-navbar {
  align-items: start; /* this correctly aligns search bar and profile dropdown menu */
}


 
aside {
 
   display: none;
/* our new css */
 
#mw-navbar {
   align-items: start;
}
}


/* left sidebar navigation */
#mw-navigation {
#mw-navigation {
   background-color: var(--medik);
   background-color: var(--medik); /* this value gets set in LocalSettings.php */
   padding: 0
   padding: 0
}
}


/* extra text: "navigation" that shows up above sidebar and should be hidden */
#p-navigation-label {
#p-navigation-label {
   visibility: hidden;
   visibility: hidden;
}
}


/* text in sidebar */
#mw-navigation a:not(.disabled), #mw-navigation a:not(.disabled):hover {
#mw-navigation a:not(.disabled), #mw-navigation a:not(.disabled):hover {
   color: white;
   color: white;
Line 98: Line 126:
}
}


/* the following only for desktop mode */
@media screen and (min-width: 768px) {
@media screen and (min-width: 768px) {
  /* align logo and title in top navigation */
  #p-banner {
    display: flex;
    align-items: center;
  }
 
  /* logo in top navigation */
   #p-banner .mw-wiki-logo {
   #p-banner .mw-wiki-logo {
     width: 3.5em;
     width: 3.5em;
     height: 3.5em;
     height: 3.5em;
  }


  /* site title in top navigation */
  .mw-desktop-sitename {
    font-size: 2em;
    padding-left: .75em;
   }
   }


   #mw-navigation {
   #mw-navigation {
     max-width: 7em;
     max-width: 7em; /* default is for left navigation to be quite wide; make it narrower */
   }
   }


   #site-navigation {
   #site-navigation {
     width: 100%;
     width: 100%; /* let content of side navigation fill full width */
   }
   }


Line 117: Line 158:
   }
   }


  /* style icons that come before each page title in sidebar */
   #site-navigation li a::before {
   #site-navigation li a::before {
     text-align: center;
     text-align: center;
Line 126: Line 168:
     margin: auto;
     margin: auto;
     margin-top: 1em;
     margin-top: 1em;
     filter: invert(100%) sepia(100%) saturate(2%) hue-rotate(141deg) brightness(103%) contrast(101%);
     filter: invert(1); /* change icons from black to white */
   }
   }
}
}


#site-navigation li a:hover {
#site-navigation li a:hover {
   filter: invert(100%) sepia(100%) saturate(2%) hue-rotate(141deg) brightness(103%) contrast(101%);
   filter: invert(.25); /* change icons and text from white to slightly gray on hover */
}
}


Line 138: Line 180:
}
}


#n-HOME a::before, #n-HOME-1 a::before {
#n-HOME a::before {
   background-image: url("images/icons/home.svg");
   background-image: url("images/icons/home.svg");
}
}


#n-SPACES a::before, #n-SPACES-1 a::before {
#n-SPACES a::before {
   background-image: url("images/icons/door.svg");
   background-image: url("images/icons/door.svg");
}
}
Line 148: Line 190:
#n-TOOLS a::before {
#n-TOOLS a::before {
   background-image: url("images/icons/tools.svg");
   background-image: url("images/icons/tools.svg");
}
#n-PROJECT-TUTORIALS a::before {
  background-image: url("images/icons/gallery.svg");
}
}


Line 154: Line 200:
}
}


#n-PROJECTS a::before, #n-GALLERY a::before {
/* Homepage */
   background-image: url("images/icons/gallery.svg");
 
.homeInfoBox {
  background-color: #eee;
  padding: 10px 20px;
  width: 16vw;
  min-width: 350px;
  height: 5vw;
  min-height: 130px;
  border-radius: 1em;
   box-shadow: 5px 5px 5px rgba(0,0,0,0.125) inset, -5px -5px 5px 0px rgba(255,255,255,0.5) inset;
}
}






/* cece added this */
/* filter buttons on both Tools and Project Tutorials pages */
.carousel-container {
button.filter-btn {
  position: relative;
    border-radius: .5em;
  display: block;
    margin: .2em;
  width: 35%;
    background-color: white;
  height: 350px; 
    height: 2.2em;
  margin: 0 auto;
}
  overflow: hidden; 


.carousel-item {
button.filter-btn:hover, button.filter-btn.selected-filter {
  width: 100%;
    background-color: var(--medik);
  box-sizing: border-box;
    color: white;
}
}


.carousel-item img {
/* set icons of filter buttons on both Tools and Project Tutorials pages to white when hovered or selected */
  width: 100%;
button.filter-btn:hover img, button.filter-btn.selected-filter img {
  height: auto;
    filter: brightness(0) invert(1);
  object-fit: cover;
  transition: transform 0.3s ease-in-out, box-shadow 0.3s ease-in-out;
}
}


.carousel-count {
#category-filter {
  text-align: center;
   margin-bottom: 2em; /* add space after filter buttons and before results on Tools and Project Tutorials pages */
   margin-top: 10px;
}
}


.carousel-prev, .carousel-next {
/* currently affects skill badges on both Spaces page and Individual Project pages */
  position: absolute;
img.skill-badge-img, .skill-badge-img img {
  top: 50%;
   width: 55px;
  transform: translateY(-50%);
  background-color: #003366;
  color: white;
  border: none;
  padding: 10px 15px;
  font-size: 20px;
  cursor: pointer;
  border-radius: 50%;
   width: 50px;
  height: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 20;
}
}


.carousel-next {
.skill-badge-img:hover, .skill-badge-img:hover img {
   right: 5px;
   width: 50px;
}
}


.carousel-prev {
@media (max-width: 768px) {
  left: 5px;
    .pc-map { display: none !important; }
}
}


.carousel-prev:hover, .carousel-next:hover {
@media (min-width: 769px) {
  background-color: #002244;
    .mobile-map { display: none !important; }
}
}

Latest revision as of 03:24, 9 April 2025

/* All CSS here will be loaded for users of the Medik skin */

/* css from Aaron */
@font-face {
  font-family: georgia;
  src: url(images/fonts/georgia.ttf);
}

body {
  height: 100%;
  --cc-white: #edeff7;
  --cc-blue: #003069;
}

.bg-ws {
  background-color: var(--cc-blue);
}

#p-banner {
  font-family: georgia;
  font-weight: 100;
}

#mw-navigation {
  background-color: var(--cc-blue);
}

#mw-main-container .row {
  background-color: var(--cc-white);
}

h2, h1, h3 {
    font-family: Arial, Helvetica, sans-serif;
}

/*[show*='vid'] img, [show*='none'] img {
  display: none;
}

[show*='img'] .videoBox, [show*='none'] .videoBox {
  display: none;
}*/

/* the following affects project tutorial pages: */

.sxs img {
  image-orientation: from-image;
  float: left;
  margin-right: 2em;
  width: min(calc(95vmin - 6em), 40vmax);
  height: auto;
}

.sxs {
  counter-reset: section;
}

.sxs h3::before {
  counter-increment: section;
  content: "Step " counter(section) ": ";
}

.sxs div {
  overflow: auto;
  margin-bottom: 1em;
  padding: 2em;
  padding-top: 0;
  border: 1px #ccc solid;
  box-shadow: 2px 2px 3px rgba(0,0,0,.25);
}

.sxs div h3{
  margin-top: .5em;
  border-bottom: .5px solid #ccc;
}

.sxs div:nth-child(odd) img {
  float: right;
  margin-left: 2em;
  margin-right: 0;
}

.sxs div:nth-child(odd) {
  border-radius: .5em;
}

.sxs div:nth-child(even) {
  background-color: #eee;
  border-radius: .5em;
}

.overview {
  background-color: rgba(0,70,200,.2);
  border-radius: 1em; 
  padding-left: 1em; 
  padding-right: 1em; 
  padding-top: .01em;
  padding-bottom: .75em;
}
/* end of css from Aaron */

/* top navigation */
#mw-navbar {
  align-items: start; /* this correctly aligns search bar and profile dropdown menu */
}

aside {
  display: none;
}

/* left sidebar navigation */
#mw-navigation {
  background-color: var(--medik); /* this value gets set in LocalSettings.php */
  padding: 0
}

/* extra text: "navigation" that shows up above sidebar and should be hidden */
#p-navigation-label {
  visibility: hidden;
}

/* text in sidebar */
#mw-navigation a:not(.disabled), #mw-navigation a:not(.disabled):hover {
  color: white;
  text-align: center;
}

/* the following only for desktop mode */
@media screen and (min-width: 768px) {
  /* align logo and title in top navigation */
  #p-banner {
    display: flex;
    align-items: center;
  }
  
  /* logo in top navigation */
  #p-banner .mw-wiki-logo {
    width: 3.5em;
    height: 3.5em;
  }

  /* site title in top navigation */
  .mw-desktop-sitename {
    font-size: 2em;
    padding-left: .75em;
  }

  #mw-navigation {
    max-width: 7em; /* default is for left navigation to be quite wide; make it narrower */
  }

  #site-navigation {
    width: 100%; /* let content of side navigation fill full width */
  }

  #mw-navigation a {
    padding: 0;
  }

  /* style icons that come before each page title in sidebar */
  #site-navigation li a::before {
    text-align: center;
    display: block;
    content: '';
    background-size: 2em;
    height: 2em;
    width: 2em;
    margin: auto;
    margin-top: 1em;
    filter: invert(1); /* change icons from black to white */
  }
}

#site-navigation li a:hover {
  filter: invert(.25); /* change icons and text from white to slightly gray on hover */
}

#site-navigation li {
  text-align: center;
}

#n-HOME a::before {
  background-image: url("images/icons/home.svg");
}

#n-SPACES a::before {
  background-image: url("images/icons/door.svg");
}

#n-TOOLS a::before {
  background-image: url("images/icons/tools.svg");
}

#n-PROJECT-TUTORIALS a::before {
  background-image: url("images/icons/gallery.svg");
}

#n-SUBMIT-PROJECT a::before {
  background-image: url("images/icons/howTo.svg");
}

/* Homepage */

.homeInfoBox {
  background-color: #eee; 
  padding: 10px 20px; 
  width: 16vw; 
  min-width: 350px;
  height: 5vw;
  min-height: 130px; 
  border-radius: 1em;
  box-shadow: 5px 5px 5px rgba(0,0,0,0.125) inset, -5px -5px 5px 0px rgba(255,255,255,0.5) inset;
}



/* filter buttons on both Tools and Project Tutorials pages */
button.filter-btn {
    border-radius: .5em;
    margin: .2em;
    background-color: white;
    height: 2.2em;
}

button.filter-btn:hover, button.filter-btn.selected-filter {
    background-color: var(--medik);
    color: white;
}

/* set icons of filter buttons on both Tools and Project Tutorials pages to white when hovered or selected */
button.filter-btn:hover img, button.filter-btn.selected-filter img {
    filter: brightness(0) invert(1);
}

#category-filter {
  margin-bottom: 2em; /* add space after filter buttons and before results on Tools and Project Tutorials pages */
}

/* currently affects skill badges on both Spaces page and Individual Project pages */
img.skill-badge-img, .skill-badge-img img {
  width: 55px;
}

.skill-badge-img:hover, .skill-badge-img:hover img {
  width: 50px;
}

@media (max-width: 768px) {
    .pc-map { display: none !important; }
}

@media (min-width: 769px) {
    .mobile-map { display: none !important; }
}