I've noticed that when I tap on the Trigger of the tooltip on iOS, the tooltip dismisses, but immediately presents again (since I tapped on the Trigger) - to illustrate what I'm talking about:
I find Android's behavior to be much more in-line with what the average user would expect. I compared this behavior with the upstream library used for iOS which is Popovers. The author has a reference app called "Find" (getfind.app) where they're utilizing Popovers in various places. The behavior there is exactly like on Android, i.e. tapping on the Trigger only dismisses the tooltip, instead of re-presenting them.
I suspect the "culprit" of this behavior lies somewhere in this method:
override func didUpdateReactSubviews() {
let firstView = self.reactSubviews()[0] as! RCTView
contentView = firstView
for index in 1..<self.reactSubviews().count {
let subView = self.reactSubviews()[index]
self.addSubview(subView)
}
}
Can this be aligned so that the iOS behavior is the same as Android?
Hello,
I've noticed that when I tap on the Trigger of the tooltip on iOS, the tooltip dismisses, but immediately presents again (since I tapped on the Trigger) - to illustrate what I'm talking about:
https://github.com/alantoa/universal-tooltip/assets/19533289/a35b6032-a4c0-4ba8-81b5-9903b84fdada
For comparison, on Android, when I do the same on Android, the tooltip is only dismissed, instead of being presented again. See video:
https://github.com/alantoa/universal-tooltip/assets/19533289/e05febb9-878f-4959-bb09-b87cb179437f
I find Android's behavior to be much more in-line with what the average user would expect. I compared this behavior with the upstream library used for iOS which is Popovers. The author has a reference app called "Find" (getfind.app) where they're utilizing Popovers in various places. The behavior there is exactly like on Android, i.e. tapping on the Trigger only dismisses the tooltip, instead of re-presenting them.
I suspect the "culprit" of this behavior lies somewhere in this method:
Can this be aligned so that the iOS behavior is the same as Android?
For reference, this is the code from my videos