Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

EnvelopeSkeleton: add filler on hover to prevent text shifting #10583

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions src/components/EnvelopeSkeleton.vue
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,10 @@
<div v-show="forceDisplayActions || displayActionsOnHoverFocus"
class="list-item__actions"
@focusout="handleBlur">
<!-- These details aren't actually displayed, they are just there to prevent text jittering on hover -->
<div class="list-item__actions__filler">
<slot name="list-item__actions__filler">{{ details }}</slot>

Check warning on line 88 in src/components/EnvelopeSkeleton.vue

View workflow job for this annotation

GitHub Actions / NPM lint

Expected 1 line break after opening tag (`<slot>`), but no line breaks found

Check warning on line 88 in src/components/EnvelopeSkeleton.vue

View workflow job for this annotation

GitHub Actions / NPM lint

Expected 1 line break before closing tag (`</slot>`), but no line breaks found
</div>
<NcActions ref="actions"
:primary="isActive || active"
:aria-label="computedActionsAriaLabel"
Expand Down Expand Up @@ -633,6 +637,15 @@
justify-content: center;
align-self: start;
margin-top: 0;
display: flex;
flex-direction: column-reverse;
align-items: flex-end;

&__filler {
padding-right: calc(var(--default-grid-baseline) * 2);
visibility: hidden;
margin-left: calc(var(--default-grid-baseline) * 2 + 1px);
}
}

}
Expand Down
Loading