samsam Posted January 2, 2021 Share Posted January 2, 2021 Site URL: https://oceanoculus.com/news-from-the-sea I'm trying to create a background colour & shadow effect that appears when hovering over each blog entry on this blog page. I adapted some code I used to create the effect I want on a summary block (scroll down to 'recent news from the sea'). However when I apply it to the blog page, the code gives a background colour (and shadow) to each 'element' (e.g. the blog title, the text, read more link) separately rather than each blog entry as a whole. The code I'm tried for the blog is as follows: .collection-type-blog.view-list article :hover { background-color: #FAFAFA !important; box-shadow: 1px 1px 8px 2px rgba(0,0,0,.2) !important; opacity: 1; transition: ease-in-out .3s; } Is there any way I can create the background colour & shadow effect for each entry as a whole? Many thanks in advance Beyondspace 1 Link to comment
Beyondspace Posted January 2, 2021 Share Posted January 2, 2021 1 hour ago, samsam said: Site URL: https://oceanoculus.com/news-from-the-sea I'm trying to create a background colour & shadow effect that appears when hovering over each blog entry on this blog page. I adapted some code I used to create the effect I want on a summary block (scroll down to 'recent news from the sea'). However when I apply it to the blog page, the code gives a background colour (and shadow) to each 'element' (e.g. the blog title, the text, read more link) separately rather than each blog entry as a whole. The code I'm tried for the blog is as follows: .collection-type-blog.view-list article :hover { background-color: #FAFAFA !important; box-shadow: 1px 1px 8px 2px rgba(0,0,0,.2) !important; opacity: 1; transition: ease-in-out .3s; } Is there any way I can create the background colour & shadow effect for each entry as a whole? Many thanks in advance You can try this .collection-type-blog.view-list article :hover { background-color: #FAFAFA !important; box-shadow: 1px 1px 8px 2px rgba(0,0,0,.2) !important; opacity: 1; transition: ease-in-out .3s; } .collection-type-blog.view-item .blog-item > article { padding: 5px; } .collection-type-blog.view-item .blog-item:hover > article { background-color: #FAFAFA !important; box-shadow: 1px 1px 8px 2px rgba(0,0,0,.2) !important; opacity: 1; transition: ease-in-out .3s; } tuanphan 1 Greeting, it's BeyondSpace, I am Squarespace dev focus on provide solutions to enhance feature that squarespace.com can't provide.Feel free to check my current Squarespace Plugins Developement: Enable Pinch/Zoom on lightbox, Delivery Date Picker, Lightbox Studio pluginIf you find my answer fit your need, let's leave a like or upvote so others with the same issue can find their solution. Thank you Link to comment
samsam Posted January 3, 2021 Author Share Posted January 3, 2021 18 hours ago, bangank36 said: You can try this .collection-type-blog.view-list article :hover { background-color: #FAFAFA !important; box-shadow: 1px 1px 8px 2px rgba(0,0,0,.2) !important; opacity: 1; transition: ease-in-out .3s; } .collection-type-blog.view-item .blog-item > article { padding: 5px; } .collection-type-blog.view-item .blog-item:hover > article { background-color: #FAFAFA !important; box-shadow: 1px 1px 8px 2px rgba(0,0,0,.2) !important; opacity: 1; transition: ease-in-out .3s; } Ah I don't think I explained it very well (sorry). I don't want the effect on each individual blog post "page" but on the blog page that lists all the posts. If I inspect the elements on the page that lists all the blog posts, I can see that each individual post entry (title, meta-data, image, text, read more tag) has it's own article class and data item ID (see attached image). Does that make sense? Link to comment
tuanphan Posted January 6, 2021 Share Posted January 6, 2021 On 1/3/2021 at 4:14 PM, samsam said: Ah I don't think I explained it very well (sorry). I don't want the effect on each individual blog post "page" but on the blog page that lists all the posts. If I inspect the elements on the page that lists all the blog posts, I can see that each individual post entry (title, meta-data, image, text, read more tag) has it's own article class and data item ID (see attached image). Does that make sense? Do you still need help? Email me if you have need any help (free, of course.). Answer within 24 hours. Or send to forum message How to: Setup Password & Share url - Insert Custom CSS - Page Header - Upload Custom Font - Upload File - Find Block ID - Contact Customer Care Link to comment
samsam Posted January 8, 2021 Author Share Posted January 8, 2021 On 1/6/2021 at 10:33 AM, tuanphan said: Do you still need help? Yes please 🙂 Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment