User:Sur/vector.css: Difference between revisions
< User:Sur
Tag: Undo |
m more height match testing |
||
Line 1: | Line 1: | ||
.stat-infobox { | .stat-infobox { | ||
width: 175px; | width: 175px; | ||
height: 150px; | min-height: 150px; /* Set minimum height instead of fixed height */ | ||
background-color: #f0f0f0; | background-color: #f0f0f0; | ||
border-radius: 10px; | border-radius: 10px; | ||
text-align: center; | text-align: center; | ||
position: relative; | position: relative; | ||
display: flex; | display: flex; | ||
flex-direction: column; | flex-direction: column; | ||
Line 13: | Line 11: | ||
align-items: center; | align-items: center; | ||
transition: width 0.3s ease; | transition: width 0.3s ease; | ||
margin-bottom: 10px | margin-bottom: 10px; | ||
} | } | ||
.stat-infobox-hover { | .stat-infobox-hover { | ||
display: block; | display: block; | ||
position: absolute | position: relative; /* Adjusted from absolute to relative to follow normal flow */ | ||
width: 100%; /* Ensures the table inside fills the width of the infobox */ | |||
background-color: #fff; | background-color: #fff; | ||
border: 1px solid #ccc; | border: 1px solid #ccc; | ||
Line 56: | Line 24: | ||
border-radius: 15px; | border-radius: 15px; | ||
opacity: 1; | opacity: 1; | ||
} | } | ||
Line 63: | Line 29: | ||
width: 100%; | width: 100%; | ||
border-collapse: separate; | border-collapse: separate; | ||
margin-top: 10px | margin-top: 10px; | ||
overflow: hidden; /* Ensure the table doesn't overflow */ | |||
overflow: hidden; | |||
} | } |
Revision as of 18:25, 22 September 2024
.stat-infobox {
width: 175px;
min-height: 150px; /* Set minimum height instead of fixed height */
background-color: #f0f0f0;
border-radius: 10px;
text-align: center;
position: relative;
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
transition: width 0.3s ease;
margin-bottom: 10px;
}
.stat-infobox-hover {
display: block;
position: relative; /* Adjusted from absolute to relative to follow normal flow */
width: 100%; /* Ensures the table inside fills the width of the infobox */
background-color: #fff;
border: 1px solid #ccc;
box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
padding: 10px;
border-radius: 15px;
opacity: 1;
}
.stat-infobox-table {
width: 100%;
border-collapse: separate;
margin-top: 10px;
overflow: hidden; /* Ensure the table doesn't overflow */
}