From 5b792407a1175f132f8106c72ef4030a0704d87d Mon Sep 17 00:00:00 2001 From: "Grigorii K. Shartsev" Date: Sat, 27 Jan 2024 19:05:31 +0100 Subject: [PATCH 1/2] fix(files): selected files actions position on scroll/with readme block Signed-off-by: Grigorii K. Shartsev --- apps/files/src/components/FilesListVirtual.vue | 15 +++++++++++---- apps/files/src/components/VirtualList.vue | 10 +++++----- 2 files changed, 16 insertions(+), 9 deletions(-) diff --git a/apps/files/src/components/FilesListVirtual.vue b/apps/files/src/components/FilesListVirtual.vue index 4f729be9573da..afb2dbd888abd 100644 --- a/apps/files/src/components/FilesListVirtual.vue +++ b/apps/files/src/components/FilesListVirtual.vue @@ -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; diff --git a/apps/files/src/components/VirtualList.vue b/apps/files/src/components/VirtualList.vue index 77454772f5554..d6508df103280 100644 --- a/apps/files/src/components/VirtualList.vue +++ b/apps/files/src/components/VirtualList.vue @@ -1,15 +1,15 @@