全新popiart网站 react项目重构
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

178 lines
4.0 KiB

.explorePage .explorePage__feed .explorePage__feedPanel .explorePage__feedGrid {
.explorePage__tplCard {
position: relative;
box-sizing: border-box;
width: 100%;
aspect-ratio: 258 / 455;
border-radius: 26px;
overflow: hidden;
// background: #e8e8e8;
cursor: pointer;
&:active {
cursor: pointer;
}
&:focus-visible {
outline: 2px solid #6f47f5;
outline-offset: 3px;
}
}
.explorePage__tplCardMedia {
position: absolute;
inset: 0;
z-index: 0;
pointer-events: none;
&::after {
content: "";
position: absolute;
inset: 0;
border-radius: 24px;
background: linear-gradient(180deg, rgba(0, 0, 0, 0.42) 0%, rgba(0, 0, 0, 0.06) 42%, rgba(0, 0, 0, 0.8) 100%);
pointer-events: none;
}
img {
width: 100%;
height: 100%;
display: block;
object-fit: cover;
border-radius: 24px;
}
}
.explorePage__tplCardInfo {
position: absolute;
left: 10px;
right: 10px;
bottom: 10px;
z-index: 2;
box-sizing: border-box;
height: 57px;
padding: 10px 10px 10px 5px;
border-radius: 29px;
backdrop-filter: blur(15px);
background: rgba(255, 255, 255, 0.7);
display: flex;
align-items: center;
gap: 9px;
pointer-events: none;
}
.explorePage__tplCardAvatar {
width: 37px;
height: 37px;
flex-shrink: 0;
border-radius: 50%;
overflow: hidden;
background: rgba(255, 255, 255, 0.8);
img {
width: 100%;
height: 100%;
display: block;
object-fit: contain;
transform: scale(1.18);
}
.explorePage__tplCardAvatarPlaceholder {
width: 100%;
height: 100%;
display: block;
border-radius: 50%;
background: rgba(0, 0, 0, 0.08);
}
}
.explorePage__tplCardTitle {
min-width: 0;
margin: 0;
font-size: 12px;
font-weight: 400;
line-height: 17px;
color: #2c2c2c;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
.explorePage__tplCardCta {
box-sizing: border-box;
display: flex;
position: absolute;
top: 20px;
right: 20px;
z-index: 3;
align-items: center;
justify-content: center;
gap: 4px;
min-width: 91px;
height: 31px;
padding: 0 12px;
border: 0;
border-radius: 24px;
background: #6f47f5;
font-size: 14px;
font-weight: 400;
line-height: 20px;
color: #ffffff;
cursor: pointer;
pointer-events: none;
white-space: nowrap;
box-shadow: 0 6px 18px rgba(111, 71, 245, 0.26);
opacity: 0;
transform: translateY(-4px);
transition:
opacity 180ms ease,
transform 180ms ease;
span {
font-size: 24px;
font-weight: 300;
}
&:focus-visible {
outline: 2px solid #ffffff;
outline-offset: 2px;
}
}
// .explorePage__tplCard:hover .explorePage__tplCardMedia::after,
// .explorePage__tplCard:focus-visible .explorePage__tplCardMedia::after {
// background: linear-gradient(180deg, rgba(0, 0, 0, 0.34) 0%, rgba(0, 0, 0, 0.04) 42%, rgba(0, 0, 0, 0.74) 100%);
// }
.explorePage__tplCard.explorePage__tplCard--skeleton {
cursor: default;
pointer-events: none;
.explorePage__tplCardMedia {
border-radius: 24px;
&::after {
content: none;
}
.explorePage__feedSkeletonBlock--media {
height: 100%;
}
}
.explorePage__tplCardInfo--skeleton {
pointer-events: none;
}
.explorePage__tplCardSkeletonTitle {
height: 12px;
}
}
}
.explorePage .explorePage__feed .explorePage__feedPanel .explorePage__feedGrid .explorePage__tplCard:hover .explorePage__tplCardCta,
.explorePage .explorePage__feed .explorePage__feedPanel .explorePage__feedGrid .explorePage__tplCard:focus-within .explorePage__tplCardCta {
opacity: 1;
pointer-events: auto;
transform: translateY(0);
}