fix(explore): always keep the notes list as high as two entries

This prevents problems with the dropdown menu creating a scroll bar

Signed-off-by: Philip Molares <philip.molares@udo.edu>
This commit is contained in:
Philip Molares
2026-04-29 20:14:36 +02:00
committed by Erik Michelson
parent c81dd893e7
commit d60a67ee33
2 changed files with 11 additions and 0 deletions
@@ -0,0 +1,9 @@
/*
* SPDX-FileCopyrightText: 2026 The HedgeDoc developers (see AUTHORS file)
*
* SPDX-License-Identifier: AGPL-3.0-only
*/
.infinite-scroll {
min-height: 10rem;
}
@@ -14,6 +14,7 @@ import InfiniteScroll from 'react-infinite-scroll-component'
import { useUiNotifications } from '../../../notifications/ui-notification-boundary'
import { useApplicationState } from '../../../../hooks/common/use-application-state'
import equal from 'fast-deep-equal'
import styles from './note-entry.module.css'
export interface NotesListProps {
mode: Mode
@@ -92,6 +93,7 @@ export const NotesList: React.FC<NotesListProps> = ({ mode, sort, searchFilter,
return (
<InfiniteScroll
className={styles['infinite-scroll']}
dataLength={entries.length}
next={fetchNextPage}
hasMore={moreDataAvailable}