Jump to content

Target a single image in a gallery section with version 7.1

Recommended Posts

Site URL: https://coverkitchen.com/

Hi, All

I am using version 7.1 and have come up with a good way to add a secondary gallery to facilitate navigation in a portfolio section, but need help to refine it. 

As you can see from the screenshots (Screenshot #2 illustrates what I would like to do) on the subpage of a portfolio section, I have added a secondary gallery section that replicates the portfolio section page. This gallery replaces the navigation arrows, with a far more practical and visual way to navigate through other projects within the same portfolio page, book covers in my case. It also saves the need to go back to the main portfolio page to see other projects. 

I have added a code that changes the opacity of this secondary gallery to 50% and also a black & white filter so that the viewer focuses on the currently viewed project at the top. The images change to 100% opacity and full color on hover. However, it would be best if the currently viewed project remains at 100% opacity and in full color. That way it would convey that this is the project you are currently viewing.

My question is: would be possible to add a code that keeps the viewing project on the secondary gallery with 100% opacity and in full color? The image viewed on the portfolio section at the top (2 columns) and on the secondary gallery (6 columns) at the bottom share the same URL as they are the same project. I am not sure whether a CSS tweak would suffice or if a more sophisticated code needs to be done? The idea is that whenever a project is actively viewed at the top, it appears also at full color/opacity at the bottom.

The password of my website is: CK2020

This is the current code:

@media screen and (min-width:768px) {
.gallery-grid-wrapper {
    img {
       filter:grayscale(100%);
      opacity: .5 !important;
    }
    img:hover {
      opacity: 1 !important;
      filter: none !important;
      transition: .8s
    }
  }
}
@media(max-width:800px) {
.portfolio-grid-basic .grid-item .grid-image :hover {
  opacity: 1;
 }

 

Many thanks in advance!

Xavier

Screen Shot 2 PM.jpg

Screen Shot 1 PM.jpg

Link to comment
  • coverkitchen changed the title to Target a single image in a gallery section with version 7.1
  • Replies 1
  • Created
  • Last Reply

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Squarespace Webinars

Free online sessions where you’ll learn the basics and refine your Squarespace skills.

Hire a Designer

Stand out online with the help of an experienced designer or developer.