/* 名称 */
.tableList_name {
width: 45%;
padding-left: 29px;
font-size: 27px;
color: rgba(0, 0, 0, 1);
margin-top: 50px;
}
/* 值 */
.tableList_value {
text-align: center;
width: 35%;
font-size: 30px;
font-weight: 500;
color: rgba(0, 0, 0, 1);
}
/* 范围 */
.tableList_value_unit {
color: #b3b2b2;
}
/* tooltip提示 */
[tooltip] {
position: relative;
display: inline-block;
}
/* 小箭头 */
[tooltip]::before {
content: "";
position: absolute;
border-width: 4px 6px 0 6px;
border-style: solid;
border-color: transparent;
border-top-color: black;
z-index: 99;
opacity: 0;
top: -5px;
left: 27%;
transform: translateX(-50%);
}
/* 提示框 */
[tooltip]::after {
content: attr(tooltip);
position: absolute;
background: black;
text-align: center;
color: #fff;
border-radius: 5px;
padding: 4px 8px;
/* 宽度由内容决定 */
width: max-content;
font-size: 24px;
/* 让事件传递给下面的元素 */
pointer-events: none;
z-index: 99;
opacity: 0;
left: 50%;
top: -5px;
transform: translateX(-77%) translateY(-100%);
}
[tooltip]:hover::after,
[tooltip]:hover::before {
animation-name: fade;
animation-duration: 3s;
}
@keyframes fade {
0% {
opacity: 1;
}
80% {
opacity: 1;
}
100% {
opacity: 0;
}
}