- This topic is empty.
November 28, 2018 at 2:34 am #279616mafiamariaParticipant
I have an issue with hover. I want my page to show an image, and when you hover over, it changes to a color and text on top. So far, so good. The problem is that I can’t seem to get the hover to fit the same container as the images. When the browser window gets smaller, the image also gets smaller. But the image it should show on hover, doesn’t seem to follow the same rules. It works when the browser window is big, but looks strange when it gets smaller. You can see on the webpage I have tried several things: http://folk.ntnu.no/manordt/wu1/Heimeside/arbeid.html
I have also tried using text in css, but it won’t scale along with the original photo. The problem then is that I have a max-width of the container, because I don’t want it to be bigger than a certain size. I tried using “font-size: 4vw”, but then it doesn’t stop scaling, and gets to big. Appreciate all the help I can get!November 28, 2018 at 3:35 am #279618BeverleyhParticipant
To attract helpful responses, try mocking up the issue in a reduced CodePen demo – code is easier for us to troubleshoot there (we’re not restricted to the developer toolbar), and doesn’t come with the weight of all the extra code and distractions of a full website. Note that we only need the minimal amount of CSS and HTML to illustrate the problem. We don’t need your whole codebase.November 28, 2018 at 3:49 am #279619razavinpcoParticipantNovember 28, 2018 at 4:49 am #279620mafiamariaParticipant
Thank you for your response!
I posted only the part of the code I have a problem with over to a codepen now. Used random images. I made three images in a row to show some of the different things I have tried out.November 28, 2018 at 5:23 am #279621
- The forum ‘CSS’ is closed to new topics and replies.