File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 2626 < h1 > fastplotlib for neuroscience</ h1 >
2727 </ header >
2828
29- < div class ="quad ">
30- < img src ="/images/fpl.jpg " alt ="ephys " />
31- < img src ="/images/fpl.jpg " alt ="ophys " />
32- < img src ="/images/fpl.jpg " alt ="tracking " />
33- < img src ="/images/fpl.jpg " alt ="pathology " />
29+ < div class ="grid ">
30+ < div class ="grid-item ">
31+ < img src ="/images/fpl.jpg " alt ="ephys " />
32+ < div class ="overlay "> Description for Image 1</ div >
33+ </ div >
34+
35+ < div class ="grid-item ">
36+ < img src ="/images/fpl.jpg " alt ="ophys " />
37+ < div class ="overlay "> Description for Image 2</ div >
38+ </ div >
39+
40+ < div class ="grid-item ">
41+ < img src ="/images/fpl.jpg " alt ="tracking " />
42+ < div class ="overlay "> Description for Image 3</ div >
43+ </ div >
44+
45+ < div class ="grid-item ">
46+ < img src ="/images/fpl.jpg " alt ="pathology " />
47+ < div class ="overlay "> Description for Image 4</ div >
48+ </ div >
3449 </ div >
3550
3651 < p class ="quad-text ">
Original file line number Diff line number Diff line change 2727 < p class ="caption ">
2828 < b > Kushal Kolar</ b > < br />
2929 PhD Candidate < br />
30- NYU Williams Lab
30+ NYU Williams Lab < br />
31+ < a href ="mailto:kushal@fastplotlib.org "> kushal@fastplotlib.org</ a >
3132 </ p >
3233 </ div >
33-
3434 < div class ="image-item ">
3535 < img src ="images/caitlin.jpg " alt ="Image 2 " />
3636 < p class ="caption ">
3737 < b > Caitlin Lewis</ b > < br />
3838 PhD Student < br />
39- Duke Pearson Lab
39+ Duke Pearson Lab < br />
40+ < a href ="mailto:caitlin@fastplotlib.org "
41+ > caitlin@fastplotlib.org</ a
42+ >
4043 </ p >
4144 </ div >
4245 </ div >
Original file line number Diff line number Diff line change @@ -101,7 +101,7 @@ main .title {
101101}
102102
103103/* Quad images */
104- main .quad {
104+ main .grid {
105105 display : grid;
106106 grid-template-columns : repeat (2 , 1fr );
107107 grid-auto-rows : auto;
@@ -111,11 +111,39 @@ main .quad {
111111 margin : 0 auto;
112112}
113113
114- main .quad img {
114+ .grid-item {
115+ position : relative;
116+ overflow : hidden;
117+ }
118+
119+ .grid-item img {
115120 width : 100% ;
116- height : auto;
117- display : block;
121+ height : 100% ;
118122 object-fit : cover;
123+ display : block;
124+ }
125+
126+ /* Overlay text */
127+ .overlay {
128+ position : absolute;
129+ inset : 0 ;
130+ background : rgba (0 , 0 , 0 , 0.6 );
131+ color : black;
132+ display : flex;
133+ align-items : left;
134+ justify-content : left;
135+ text-align : left;
136+ padding : 12px ;
137+
138+ opacity : 0 ;
139+ transition : opacity 0.3s ease;
140+ font-size : 1.5rem ;
141+ font-family : "Helvetica Neue" , Arial, sans-serif;
142+ }
143+
144+ /* Show overlay on hover */
145+ .grid-item : hover .overlay {
146+ opacity : 1 ;
119147}
120148
121149/* Homepage Description */
You can’t perform that action at this time.
0 commit comments