openui5
openui5 copied to clipboard
'isDefaultPrevented is not a function' when trying to prevent selection from TabContainer overflow list
OpenUI5 version:
1.103
Browser/version (+device/version):
Chrome Version 103.0.5060.53
Any other tested browsers/devices(OK/FAIL):
No
URL (minimal example if possible):
https://jsfiddle.net/a8q5hdc7/
User/password (if required and possible - do not post any confidential information here):
Steps to reproduce the problem:
- Open Tab Container Overflow List
- Select an item from this list (e.g. 'key 8')
What is the expected result?
Tab is not switched, no errors in console
What happens instead?
Uncaught TypeError: E.isDefaultPrevented is not a function
at k._activateItem (TabStrip-dbg.js:760:32)
at constructor.
Any other information? (attach screenshot if possible)
Please, provide a fix for SAPUI5 as well and downport it to version 1.71.36
I'm not able to reproduce the error. Could you please check again if the steps are still valid in Incognito or Guest mode of the browser?
hi @boghyon . Just did it in Incognito, the error is there.
Are you sure you select an item from Overflow List?
I can reproduce it. It seems to be an issue in the TabStrip.js
code itself. The _activateItem
method expects a jQuery.Event
object (which has a isDefaultPrevented
method), but the code in _createSelect
calls this method with a UI5 control event object, which does not have such a method.
The code exists already for quite some time, but the issue only occurs when a listener to the TabStrip's itemSelect
event vetoes (update: I meant: calls preventDefault on) that event. Maybe that's the reason why this went unnoticed until now.
Hello @antonborisoff ,
Thank you for sharing this finding. I've created an internal incident 2280136862. The status of the issue will be updated here in GitHub.
Regards, Johannes
Hi @H4ze .
Do you have any updates regarding the issue?
Hello @antonborisoff,
The issue is fixed for the master branch and the fix will be available since sapui5 version 1.107.0.
Best Regards, Boyan Rakilovski
Fixed by https://github.com/SAP/openui5/commit/8e8893588f83aabc392e901b5a2d9bbfd5454efa
Hi @boghyon Could you, please, downport it to SAPUI 1.71.47?
Hi @antonborisoff, I just documented the commit here but am not the owner of it. @unazko: Is it possible to downport the fix?