Skip to content

Commit

Permalink
Merge pull request #28389 from getusha/fix-scroll-behind-suggestion-list
Browse files Browse the repository at this point in the history
Fix scroll behind suggestion list when scrolling on suggestion popup
  • Loading branch information
NikkiWines authored Oct 5, 2023
2 parents a95138f + f9b1683 commit 040ba7b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/styles/StyleUtils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -942,13 +942,13 @@ function getAutoCompleteSuggestionContainerStyle(itemsHeight: number): ViewStyle
'worklet';

const borderWidth = 2;
const height = itemsHeight + 2 * CONST.AUTO_COMPLETE_SUGGESTER.SUGGESTER_INNER_PADDING + borderWidth;
const height = itemsHeight + 2 * CONST.AUTO_COMPLETE_SUGGESTER.SUGGESTER_INNER_PADDING;

// The suggester is positioned absolutely within the component that includes the input and RecipientLocalTime view (for non-expanded mode only). To position it correctly,
// we need to shift it by the suggester's height plus its padding and, if applicable, the height of the RecipientLocalTime view.
return {
overflow: 'hidden',
top: -(height + CONST.AUTO_COMPLETE_SUGGESTER.SUGGESTER_PADDING),
top: -(height + CONST.AUTO_COMPLETE_SUGGESTER.SUGGESTER_PADDING + borderWidth),
height,
};
}
Expand Down

0 comments on commit 040ba7b

Please sign in to comment.