Skip to content

Commit

Permalink
Merge pull request Expensify#54344 from bernhardoj/fix/53976-wrong-to…
Browse files Browse the repository at this point in the history
…oltip-position

Fix composer educational tooltip wrong position on mWeb Safari
  • Loading branch information
marcochavezf authored Dec 31, 2024
2 parents d89be5f + 181fe65 commit 7cc8f99
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ import useLocalize from '@hooks/useLocalize';
import useNetwork from '@hooks/useNetwork';
import useResponsiveLayout from '@hooks/useResponsiveLayout';
import useThemeStyles from '@hooks/useThemeStyles';
import useViewportOffsetTop from '@hooks/useViewportOffsetTop';
import canFocusInputOnScreenFocus from '@libs/canFocusInputOnScreenFocus';
import * as DeviceCapabilities from '@libs/DeviceCapabilities';
import DomUtils from '@libs/DomUtils';
Expand Down Expand Up @@ -130,6 +131,7 @@ function ReportActionCompose({
const {translate} = useLocalize();
// eslint-disable-next-line rulesdir/prefer-shouldUseNarrowLayout-instead-of-isSmallScreenWidth
const {isSmallScreenWidth, isMediumScreenWidth, shouldUseNarrowLayout} = useResponsiveLayout();
const offsetTop = useViewportOffsetTop();
const {isOffline} = useNetwork();
const actionButtonRef = useRef<View | HTMLDivElement | null>(null);
const currentUserPersonalDetails = useCurrentUserPersonalDetails();
Expand Down Expand Up @@ -459,7 +461,7 @@ function ReportActionCompose({
}}
wrapperStyle={styles.reportActionComposeTooltipWrapper}
shiftHorizontal={variables.composerTooltipShiftHorizontal}
shiftVertical={variables.composerTooltipShiftVertical}
shiftVertical={variables.composerTooltipShiftVertical + offsetTop}
>
<View
ref={containerRef}
Expand Down

0 comments on commit 7cc8f99

Please sign in to comment.