diff --git a/ivette/src/dome/renderer/frame/toolbars.tsx b/ivette/src/dome/renderer/frame/toolbars.tsx index 0604fca530079630f01683b63ac61391ddf108e8..5cde88b571d735ca163fc73cd1f20b6d2e761d13 100644 --- a/ivette/src/dome/renderer/frame/toolbars.tsx +++ b/ivette/src/dome/renderer/frame/toolbars.tsx @@ -383,8 +383,7 @@ function scrollToRef(r: null | HTMLLabelElement): void { function Suggestions(props: SuggestionsProps): JSX.Element { const { hints, onHint, index, onClose } = props; - const theHints = hints.length > 100 ? hints.slice(0, 100) : hints; - const suggestions = theHints.map((h, k) => { + const suggestions = hints.slice(0, 100).map((h, k) => { const selected = k === index || hints.length === 1; const classSelected = selected && 'dome-xToolBar-searchIndex'; const className = classes('dome-xToolBar-searchItem', classSelected);