Merge pull request #43172 from nextcloud/fix/43149/files--table-header-actions-position

fix(files): selected files actions position on scroll/with readme block
This commit is contained in:
Ferdinand Thiessen 2024-01-30 21:19:01 +01:00 committed by GitHub
commit 4239ee7d33
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
4 changed files with 19 additions and 12 deletions

View file

@ -339,14 +339,21 @@ export default defineComponent({
.files-list__table {
display: block;
&.files-list__table--with-thead-overlay {
// Hide the table header below the overlay
margin-top: calc(-1 * var(--row-height));
}
}
.files-list__thead-overlay {
position: absolute;
// Pinned on top when scrolling
position: sticky;
top: 0;
left: var(--row-height); // Save space for a row checkbox
right: 0;
z-index: 1000;
// Save space for a row checkbox
margin-left: var(--row-height);
// More than .files-list__thead
z-index: 20;
display: flex;
align-items: center;

View file

@ -1,15 +1,15 @@
<template>
<div class="files-list" data-cy-files-list>
<div v-if="!!$scopedSlots['header-overlay']" class="files-list__thead-overlay">
<slot name="header-overlay" />
</div>
<!-- Header -->
<div ref="before" class="files-list__before">
<slot name="before" />
</div>
<table class="files-list__table">
<div v-if="!!$scopedSlots['header-overlay']" class="files-list__thead-overlay">
<slot name="header-overlay" />
</div>
<table class="files-list__table" :class="{ 'files-list__table--with-thead-overlay': !!$scopedSlots['header-overlay'] }">
<!-- Accessibility table caption for screen readers -->
<caption v-if="caption" class="hidden-visually">
{{ caption }}

4
dist/files-main.js vendored

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long