Closed sairamyaM closed 2 years ago
You need to move the Popover further up the component chain, so that it is a direct descendant of a view that fills the entire screen. Right now, I'm guessing it is right next to the input, which is why the displayArea
height is 68
, as it shows in your log output. It is trying to show, but it is bounded by the same rectangle that your input takes up, so has nowhere to show. This is the unfortunate downside of tooltip
mode. To fix, you'll need to de-couple the popover from the input (if you haven't already), move the Popover up the chain, and pass props around to know when to show the popover (e.g. onInputFocus
and onInputBlur
on the component that contains the input). If this doesn't make sense, I could help more if you share some code.
@sairamyaM Were you able to resolve your issue?
any solution fro this
I'm assuming the OP has moved on. Please read my recommendation, review the recently updated documentation on this topic, and open a new issue with specific details if you are having an issue
Describe the bug What is it that you are seeing? Please be detailed in your description so that I can help fix your issue as quickly as possible. When I use popover mode as tooltip I am unable to see the popover Device/Setup Info:
react-native
version: [react-native-cli: 2.0.1]react-native-popover-view
version: [4.0.3]Screenshots what is needed what is getting
Debug Output [2021-10-14T03:35:30.373Z] calculateRectFromRef - waiting for ref LOG [2021-10-14T03:35:30.374Z] calculateRectFromRef - waiting for ref to move LOG [2021-10-14T03:35:30.405Z] calculateRectFromRef - calculated Rect: {"x":18.18181800842285,"y":413.0909118652344,"width":356.7272644042969,"height":65.81818389892578} LOG [2021-10-14T03:35:31.526Z] setDefaultDisplayArea - newDisplayArea: {"x":0,"y":-0.00004438920450411388,"width":356.7272644042969,"height":68} LOG [2021-10-14T03:35:31.623Z] setDefaultDisplayArea - displayAreaOffset: {"x":18.18181800842285,"y":413.0909118652344} LOG [2021-10-14T03:35:31.784Z] handleChange - no requestedContentSize, exiting... LOG [2021-10-14T03:35:31.799Z] calculateRectFromRef - waiting for ref LOG [2021-10-14T03:35:31.804Z] calculateRectFromRef - waiting for ref to move LOG [2021-10-14T03:35:31.814Z] measureContent - new requestedContentSize: {"y":0,"height":160.72727966308594,"width":288.7272644042969,"x":0} (used to be null) LOG [2021-10-14T03:35:32.215Z] handleChange - waiting 100ms to accumulate all changes LOG [2021-10-14T03:35:32.262Z] calculateRectFromRef - calculated Rect: {"x":0,"y":0,"width":356.7272644042969,"height":68} LOG [2021-10-14T03:35:32.399Z] handleChange - waiting 100ms to accumulate all changes LOG [2021-10-14T03:35:32.747Z] handleChange - requestedContentSize: {"y":0,"height":160.72727966308594,"width":288.7272644042969,"x":0} LOG [2021-10-14T03:35:32.908Z] handleChange - displayArea: {"x":0,"y":-0.00004438920450411388,"width":356.7272644042969,"height":68} LOG [2021-10-14T03:35:32.929Z] handleChange - fromRect: {"x":0,"y":0,"width":356.7272644042969,"height":68} LOG [2021-10-14T03:35:32.930Z] handleChange - placement: "top" LOG [2021-10-14T03:35:33.096Z] computeGeometry - initial chosen geometry: {"popoverOrigin":{"x":34,"y":9.999955610795496},"anchorPoint":{"x":178.36363220214844,"y":0},"placement":"top","forcedContentSize":{"height":-17.999955610795496,"width":336.7272644042969},"viewLargerThanDisplayArea":{"height":true,"width":false}} LOG [2021-10-14T03:35:33.116Z] computeGeometry - final chosen geometry: {"popoverOrigin":{"x":34,"y":9.999955610795496},"anchorPoint":{"x":178.36363220214844,"y":0},"placement":"top","forcedContentSize":{"height":-17.999955610795496,"width":336.7272644042969},"viewLargerThanDisplayArea":{"height":true,"width":false}} LOG [2021-10-14T03:35:33.265Z] handleChange - delaying showing popover because viewLargerThanDisplayArea