diff --git a/src/components/common/profile/ProfileInfo.module.scss b/src/components/common/profile/ProfileInfo.module.scss index be3025320..6c7d74b96 100644 --- a/src/components/common/profile/ProfileInfo.module.scss +++ b/src/components/common/profile/ProfileInfo.module.scss @@ -116,20 +116,6 @@ @include mixins.with-vt-type('profileAvatar'); - &::before { - content: ''; - - position: absolute; - z-index: 1; - top: 0; - right: 0; - left: 0; - - height: 2rem; - - background: linear-gradient(180deg, rgba(0, 0, 0, 0.25) 0%, rgba(0, 0, 0, 0) 100%); - } - > :global(.Transition) { width: 100%; height: 100%; @@ -147,6 +133,21 @@ width: 100%; height: 0.125rem; padding: 0 0.375rem; + + &::before { + content: ''; + + position: absolute; + top: -0.5rem; + right: 0; + left: 0; + + height: 2rem; + + background: linear-gradient(180deg, rgba(0, 0, 0, 0.25) 0%, rgba(0, 0, 0, 0) 100%); + } + + @include mixins.with-vt-type('profileAvatar'); } .photoDash { @@ -429,62 +430,35 @@ inset: 0; } -@include mixins.on-active-vt('profileAvatar') { - &::view-transition-group(.info), - &::view-transition-group(.title), - &::view-transition-group(.status) { - z-index: 1; - } -} - @include mixins.on-active-vt('profileAvatar') { &::view-transition-old(.profileInfo), &::view-transition-new(.profileInfo) { animation-name: none; } -} -// Delay before showing buttons & overlay -@include mixins.on-active-vt('profileExpand') { - &::view-transition-new(.photoWrapper), - &::view-transition-new(.info) { - animation-delay: 0.25s; - } -} - -// Hide buttons & overlay immediately -@include mixins.on-active-vt('profileCollapse') { - &::view-transition-old(.photoWrapper), - &::view-transition-old(.info) { - animation-duration: 0.1s; + &::view-transition-group(.photoDashes) { + z-index: 1; } } @include mixins.on-active-vt('profileExpand') { &::view-transition-old(.avatar) { z-index: -1; + animation-name: none; } &::view-transition-new(.avatar) { :local { animation-name: profileExpandAvatar; - animation-duration: inherit; - animation-timing-function: inherit; - animation-fill-mode: forwards; } @keyframes profileExpandAvatar { - from { + 0% { + opacity: 0; + } + + 50%, 100% { opacity: 1; - clip-path: inset(0 0 0 0 round 50%); - } - - 25% { - clip-path: inset(0 0 0 0 round 50%); - } - - to { - clip-path: inset(0 0 0 0 round 0%); } } } @@ -493,29 +467,21 @@ @include mixins.on-active-vt('profileCollapse') { &::view-transition-new(.avatar) { z-index: -1; + animation-name: none; } &::view-transition-old(.avatar) { :local { animation-name: profileCollapseAvatar; - animation-duration: inherit; - animation-timing-function: inherit; - animation-fill-mode: forwards; } @keyframes profileCollapseAvatar { - from { - clip-path: inset(0 0 0 0 round 0%); - } - - 25% { + 0% { opacity: 1; - clip-path: inset(0 0 0 0 round 50%); } - to { + 50%, 100% { opacity: 0; - clip-path: inset(0 0 0 0 round 50%); } } } diff --git a/src/components/common/profile/ProfileInfo.tsx b/src/components/common/profile/ProfileInfo.tsx index e66c8ac55..cb56a72b8 100644 --- a/src/components/common/profile/ProfileInfo.tsx +++ b/src/components/common/profile/ProfileInfo.tsx @@ -350,7 +350,7 @@ const ProfileInfo = ({ const activeDashIndex = currentPhotoIndex >= MAX_PHOTO_DASH_COUNT ? MAX_PHOTO_DASH_COUNT - 1 : currentPhotoIndex; return ( -
+
{enumerator.map((_, i) => ( ))}