I am trying to build a responsive grid on a website that will use each hexagon as a link so the "background" method isn't a possibility. I have also taken out the animation for the words coming down and added words onto the image itself. I have also added an opacity to the image that goes away when hovering over.
As this is for an "emergency preparedness" I need to have all of the image in the hexagon, and currently the words are being cut off by the hexagon. I am using this theme http://www.cssscript.com/responsive-hexagon-grid-pure-css/ and so far we've tried the position:absolute/relative method.
Relevant CSS:
.hex {
position: relative;
list-style-type: none;
float: left;
overflow: hidden;
visibility: hidden;
-webkit-transform: rotate(-60deg) skewY(30deg);
-ms-transform: rotate(-60deg) skewY(30deg);
transform: rotate(-60deg) skewY(30deg);
}
.hexIn {
display:block;
width: 100%;
height: 100%;
text-align: center;
color: #fff;
overflow: hidden;
-webkit-transform: skewY(-30deg) rotate(60deg);
-ms-transform: skewY(-30deg) rotate(60deg);
transform: skewY(-30deg) rotate(60deg);
-webkit-backface-visibility: hidden;
backface-visibility: hidden;
}
.hex img {
left: -100%;
right: -100%;
width: 100%;
height: 100%;
margin: 0 auto;
align-content:center;
opacity:0.7;
}
.hex img:hover {
opacity:1.0;
}
Relevant HTML:
<ul id="hexGrid">
<!-- RED ICONS -->
<li class="hex">
<a class="hexIn" href="#">
<img src="/eng/branch/isb/em/images/EM_EmergencyResponse2.svg" alt="Emergency Response" />
</a>
</li>
The images are all SVGs for responsive design.