browniebroke / gatsby-image-gallery

Very basic gallery grid based on gatsby-image
https://gatsby-image-gallery.netlify.app
MIT License
130 stars 24 forks source link

Lightbox styling not applied in build mode #892

Closed Tiefflieger closed 2 years ago

Tiefflieger commented 2 years ago

Hi, I have an issue with the lightbox like described in this discussion: https://github.com/gatsbyjs/gatsby/issues/30874 The lightbox styling is not applied when in build mode (left is build):

Bildschirmfoto 2022-03-23 um 21 18 37

I also tried to revert "styled-components" and "babel-plugin-styled-components" like mentioned in this solution: https://github.com/styled-components/styled-components/issues/3321#issuecomment-819915948

Moviss commented 2 years ago

Hi, I have the same problem. Styles not applied after build. Any chance for fix or tip how to solve it? I want to go to production with my website but it seems that I need to replace image-gallery.

Tiefflieger commented 2 years ago

I haven't found a solution for the css layout difference between build and development. I have it also on other components that use separate css files. Since my page is working with these minor problems I will work on it in the next weeks.

For this problem I thought about building a lightbox gallery as described in this tutorial: Gatsby Lightbox Tutorial

Tiefflieger commented 2 years ago

I had https://www.gatsbyjs.com/plugins/gatsby-plugin-purgecss/ installed, which removed my styles. It's now deactivated since I'm aware of configuring it right.